예제 #1
0
class GlobalOptions(TestSetup):
    """ Global Options """
    # mode, either Train or Valid.
    mode: Union[TrainOptions, ValidOptions] = subparsers({
        "train": TrainOptions,
        "valid": ValidOptions,
    })
    global_arg: str = "something"
예제 #2
0
 class Config:
     experiment: Experiment = subparsers({
         "mnist": Mnist,
         "mnist_continual": MnistContinual,
     })
예제 #3
0
 class Parent(TestSetup):
     family: Union[Child, Pet] = subparsers(None, required=False)
     foo: bool = False
     income: float = 35_000.