Skip to content

Latest commit

 

History

History

model

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

Creating a new model

Here are the steps to create a new model.

  1. Create your CustomModel and CustomModelConfig following the example in models/custommodel.py. These will be the model code and an associated dataclass to validate loaded configs.
  2. Create a custommodel.yaml with the configuration parameters you defined in your script. Make sure it has a name entry equal to custommodel to let hydra know which python dataclass it is associated to. You can see conf/model/layers/custommodel.yaml for an example.
  3. Place your model script in benchmarl/models and your config in benchmarl/conf/model/layers (or any other place you want to override from)
  4. Add {"custommodel": CustomModelConfig} to the benchmarl.models.model_config_registry
  5. Load it with
python benchmarl/run.py model=layers/custommodel algorithm=... task=...