Fix load and resume and update autodownload endpoint (#136)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>
This commit is contained in:
parent
6d5123297e
commit
82c849c163
5 changed files with 16 additions and 34 deletions
|
|
@ -367,7 +367,7 @@ class BaseTrainer:
|
|||
if not pretrained:
|
||||
model = check_file(model)
|
||||
ckpt = self.load_ckpt(model) if pretrained else None
|
||||
self.model = self.load_model(model_cfg=None if pretrained else model, weights=ckpt) # model
|
||||
self.model = self.load_model(model_cfg=None if pretrained else model, weights=ckpt["model"]) # model
|
||||
return ckpt
|
||||
|
||||
def load_ckpt(self, ckpt):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue