(self)
| 380 | assert success |
| 381 | |
| 382 | def load_checkpoint(self): |
| 383 | ckpt_path = get_resume_checkpoint(self.checkpoint_conf.save_dir) |
| 384 | if ckpt_path is None: |
| 385 | self._init_model_state() |
| 386 | else: |
| 387 | if self.checkpoint_conf.initialize_after_preemption: |
| 388 | self._call_model_initializer() |
| 389 | self._load_resuming_checkpoint(ckpt_path) |
| 390 | |
| 391 | def _init_model_state(self): |
| 392 | # Checking that parameters that won't be saved are indeed frozen |
no test coverage detected