config.py 2.03 KB
config = {
        "debug"                            : False,
        "seed"                             : 0,
        "wandb.use"                        : False,
        "wandb.run_id"                     : None,
        "project"                          : "brain-age",
        "result_folder"                    : "result",
        "mode"                             : ["test", "train"],

        "data.name"                        : "brain_age",
        "data.root_path"                   : "**data root path",
        "data.train_csv"                   : "**data train csv",
        "data.test_csv"                    : "**data test csv",
        "data.valid_csv"                   : "**data valid csv",
        "data.train_num_sample"            : -1,
        "data.frame_keep_style"            : "random",
        "data.frame_keep_fraction"         : 1,
        "data.frame_dim"                   : 1,
        "data.impute"                      : "drop",

        "model.name"                       : "regression",

        "model.arch.file"                  : "src/arch/brain_age_3d.py",
        "model.arch.lstm_feat_dim"         : 2,
        "model.arch.lstm_latent_dim"       : 128,
        "model.arch.attn_dim"              : 32,
        "model.arch.attn_num_heads"        : 1,
        "model.arch.attn_drop"             : False,
        "model.arch.agg_fn"                : "attention",

        "train.batch_size"                 : 8,
        "train.patience"                   : 100,
        "train.max_epoch"                  : 100,
        "train.optimizer"                  : "adam",
        "train.lr"                         : 1e-4,
        "train.weight_decay"               : 1e-4,
        "train.save_strategy"              : ["best", "last"],
        "train.log_every"                  : 100,
        "train.stopping_criteria"          : "loss",
        "train.stopping_criteria_direction": "lower",
        "train.gradient_norm_clip"         : -1,

        "test.batch_size"                  : 8,
        "test.eval_model"                  : "best",
}