This commit is contained in:
mrq 2025-02-23 21:20:36 -06:00
parent cbf6b84e27
commit f593ee98fc
2 changed files with 2 additions and 2 deletions

View File

@ -60,7 +60,7 @@ def load_engines(training=True, **model_kwargs):
# to handle the issue of training with deepspeed, but inferencing with local # to handle the issue of training with deepspeed, but inferencing with local
if checkpoint_path.exists() and backend == "local": if checkpoint_path.exists() and backend == "local":
tag = open(checkpoint_path).read() tag = open(checkpoint_path).read().strip()
checkpoint_path = pick_path( checkpoint_path.parent / tag / f"state.{cfg.weights_format}", *[ f'.{format}' for format in cfg.supported_weights_formats] ) checkpoint_path = pick_path( checkpoint_path.parent / tag / f"state.{cfg.weights_format}", *[ f'.{format}' for format in cfg.supported_weights_formats] )
# if loaded using --model= # if loaded using --model=

View File

@ -258,7 +258,7 @@ class Engine():
self.optimizer.step() self.optimizer.step()
self.optimizer.zero_grad() self.optimizer.zero_grad()
self._get_grad_norm() # self._get_grad_norm()
# doesn't actually work # doesn't actually work
def _get_grad_norm(self): def _get_grad_norm(self):