[WIP] Model interface (#68)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Laughing-q <1185102784@qq.com>
This commit is contained in:
parent
e6737f1207
commit
7ae45c6cc4
6 changed files with 62 additions and 59 deletions
|
|
@ -26,7 +26,7 @@ class SegmentationTrainer(BaseTrainer):
|
|||
batch["img"] = batch["img"].to(self.device, non_blocking=True).float() / 255
|
||||
return batch
|
||||
|
||||
def load_model(self, model_cfg, weights):
|
||||
def load_model(self, model_cfg=None, weights=None):
|
||||
model = SegmentationModel(model_cfg or weights["model"].yaml,
|
||||
ch=3,
|
||||
nc=self.data["nc"],
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue