ultralytics 8.3.205 Reset checkpoint arguments after training (#22286)

Signed-off-by: Mohammed Yasin <32206511+Y-T-G@users.noreply.github.com>
Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>
Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>
This commit is contained in:
Mohammed Yasin 2025-10-05 21:07:14 +08:00 committed by GitHub
parent a7302e76b0
commit bbaba08df5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 2 additions and 2 deletions

View File

@ -1,6 +1,6 @@
# Ultralytics 🚀 AGPL-3.0 License - https://ultralytics.com/license
__version__ = "8.3.204"
__version__ = "8.3.205"
import importlib
import os

View File

@ -802,7 +802,7 @@ class Model(torch.nn.Module):
if RANK in {-1, 0}:
ckpt = self.trainer.best if self.trainer.best.exists() else self.trainer.last
self.model, self.ckpt = load_checkpoint(ckpt)
self.overrides = self.model.args
self.overrides = self._reset_ckpt_args(self.model.args)
self.metrics = getattr(self.trainer.validator, "metrics", None) # TODO: no metrics returned by DDP
return self.metrics