train¶
- cneuromax.fitting.deeplearning.train.train(trainer, datamodule, litmodule, logger, config)[source]¶
Trains a Deep Neural Network.
Note that this function will be executed by
num_nodes * gpus_per_node
processes/tasks. Those variables are set in the Hydra launcher configuration.Trains (or resumes training) the model, saves a checkpoint and returns the final validation loss.
- Parameters:
logger (
partial
[WandbLogger
])
- Return type:
- Returns:
The final validation loss.