Experiment Index Config (CL Main)
To run a custom continual learning main experiment (CL Main), you need to create a YAML file in the experiment/
folder – the experiment index config. Below are an example and the required fields for the experiment index config.
Example
configs/experiment/example_clmain_train.yaml
# @package _global_
# make sure to include the above commented global setting!
cl_paradigm: TIL
train_tasks: 10
eval_after_tasks: 10
global_seed: 1
defaults:
- /cl_dataset: permuted_mnist.yaml
- /backbone: clmlp.yaml
- /cl_algorithm: finetuning.yaml
- /optimizer: sgd.yaml
- /lr_scheduler: reduce_lr_on_plateau.yaml
- /trainer: cpu.yaml
- /metrics: cl_default.yaml
- /lightning_loggers: default.yaml
- /callbacks: cl_default.yaml
- /hydra: default.yaml
- /misc: default.yaml
output_dir: outputs/example_clmain_train/${misc.timestamp}
# overrides
trainer:
max_epochs: 2
Required Config Fields
Field | Description | Allowed Values |
---|---|---|
cl_paradigm |
The continual learning paradigm |
|
train_tasks |
The list of task IDs1 to train |
|
eval_after_tasks |
If task ID |
|
global_seed |
The global seed for the entire experiment |
|
/cl_dataset |
The continual learning dataset on which the experiment is conducted |
|
/cl_algorithm |
The continual learning algorithm to be experimented with |
|
/backbone |
The backbone network on which the continual learning algorithm is based |
|
/optimizer |
The optimizer for each task |
|
/lr_scheduler |
The learning rate scheduler for each task |
|
/trainer |
The PyTorch Lightning Trainer object that contains all configurations for the training and testing process |
|
/metrics |
The metrics to be monitored, logged, or visualized |
|
/lightning_loggers |
The Lightning Loggers used to log metrics and results. Please refer to the Output Results (CL Main) section |
|
/callbacks |
The callbacks applied to this experiment (other than metric callbacks). Callbacks are additional actions integrated at different points during the experiment |
|
output_dir |
The folder name for storing the experiment results. Please refer to the Output Results (CL Main) section |
|
/hydra |
Configuration for Hydra itself |
|
/misc |
Miscellaneous configurations that are less related to the experiment |
|
Note
The continual learning main experiment run by clarena train clmain
is managed by a CLMainTrain
class. To learn how these fields work, please refer to its source code.
Footnotes
The task IDs
are integers ranging from 1 to the number of tasks in the CL dataset. Each corresponds to a task-specific dataset within the CL dataset.↩︎