AlibabaResearch / AlibabaResearch/efficientteacher
RuntimeError: Error(s) in loading state_dict for Model
- Ngôn ngữ chính
- Python
- Star
- 813
- Fork
- 126
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Mô tả
你好,我想用yolov5 v6.1的yolov5s.pt作为预训练模型,通过convert_pt_to_efficient.py转换yolov5s.pt得到e-yolov5s.pt,转换的配置文件用的是configs/sup/public/yolov5s_coco.yaml,转换过程没有报错,于是我用这个e-yolov5s.pt直接采用半监督的方式训练20个类别的模型,但是我在加载e-yolov5s.pt的时候报如下的错误:RuntimeError: Error(s) in loading state_dict for Model:
size mismatch for head.m.0.weight: copying a param with shape torch.Size([255, 128, 1, 1]) from checkpoint, the shape in current model is torch.Size([75, 128, 1, 1]).
size mismatch for head.m.0.bias: copying a param with shape torch.Size([255]) from checkpoint, the shape in current model is torch.Size([75]).
size mismatch for head.m.1.weight: copying a param with shape torch.Size([255, 256, 1, 1]) from checkpoint, the shape in current model is torch.Size([75, 256, 1, 1]).
size mismatch for head.m.1.bias: copying a param with shape torch.Size([255]) from checkpoint, the shape in current model is torch.Size([75]).
size mismatch for head.m.2.weight: copying a param with shape torch.Size([255, 512, 1, 1]) from checkpoint, the shape in current model is torch.Size([75, 512, 1, 1]).
size mismatch for head.m.2.bias: copying a param with shape torch.Size([255]) from checkpoint, the shape in current model is torch.Size([75]).
Traceback (most recent call last):
这是不是意味着,半监督的预训练模型不能直接用官方80个类别的进行训练呢
Hướng dẫn đóng góp
Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này
Đánh giá
Issue này chưa được đánh giá.