We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 23e4dfc commit 2c8b594Copy full SHA for 2c8b594
torchtitan/train.py
@@ -575,17 +575,17 @@ def train(self):
575
logger.warning("Ran out of data; last step was canceled.")
576
break
577
578
+ self.checkpointer.save(
579
+ self.step, last_step=(self.step == job_config.training.steps)
580
+ )
581
+
582
# Run validation if validator is available
583
if (
584
self.job_config.validation.enabled
585
and self.validator.should_validate(self.step)
586
):
587
self.validator.validate(self.model_parts, self.step)
588
- self.checkpointer.save(
- self.step, last_step=(self.step == job_config.training.steps)
- )
-
589
# signal the profiler that the next profiling step has started
590
if torch_profiler:
591
torch_profiler.step()
0 commit comments