(self)
| 1217 | |
| 1218 | @property |
| 1219 | def run(self): |
| 1220 | if self._is_write(): |
| 1221 | if self._run is None: |
| 1222 | if self.wandb.run is not None: |
| 1223 | warnings.warn( |
| 1224 | "There is a wandb run already in progress and newly created instances" |
| 1225 | " of `WandbCallback` will reuse this run. If this is not desired" |
| 1226 | " , call `wandb.finish()` before instantiating `WandbCallback`." |
| 1227 | ) |
| 1228 | self._run = self.wandb.run |
| 1229 | else: |
| 1230 | self._run = self.wandb.init(**self.wandb_args) |
| 1231 | |
| 1232 | return self._run |
| 1233 | |
| 1234 | def on_train_begin(self, logs: _CallbackLogs | None = None) -> None: |
| 1235 | self.epochs = self.params['epochs'] |
no test coverage detected