Saves full training configuration Otherwise wandb won't log full configuration but only flattened module and data hyperparameters
| 41 | |
| 42 | |
| 43 | class CustomSaveConfigCallback(SaveConfigCallback): |
| 44 | """Saves full training configuration |
| 45 | Otherwise wandb won't log full configuration but only flattened module and data hyperparameters |
| 46 | """ |
| 47 | |
| 48 | def save_config( |
| 49 | self, trainer: Trainer, pl_module: LightningModule, stage: str |
| 50 | ) -> None: |
| 51 | for logger in trainer.loggers: |
| 52 | if issubclass(type(logger), WandbLogger): |
| 53 | logger.experiment.config.update(self.config.as_dict()) |
| 54 | return super().save_config(trainer, pl_module, stage) |
| 55 | |
| 56 | |
| 57 | class PlotsCallback(Callback): |
nothing calls this directly
no outgoing calls
no test coverage detected