Hello,I'm confuse about eval part.First,when i use "python ./tools/eval.py mars ./logs/distilled_public/mars/selfdistill/distill_mars_resnet50 --trinet_chk_name chk_di_1",it can show the result as the table(top1,map...)
But when I want to eval resnet34 and change it to"python ./tools/eval.py mars ./logs/distilled_public/mars/selfdistill/distill_mars_resnet34 --trinet_chk_name chk_di_1" ,
it'll show size mismatch wrong.Can any one help me with the problem?Thanks a lot!
Here is the wrong message:
Traceback (most recent call last):
File "/home/kingsman/.local/share/JetBrains/Toolbox/apps/PyCharm-C/ch-0/203.7148.72/plugins/python-ce/helpers/pydev/pydevd.py", line 1477, in _exec
pydev_imports.execfile(file, globals, locals) # execute the script
File "/home/kingsman/.local/share/JetBrains/Toolbox/apps/PyCharm-C/ch-0/203.7148.72/plugins/python-ce/helpers/pydev/_pydev_imps/_pydev_execfile.py", line 18, in execfile
exec(compile(contents+"\n", file, 'exec'), glob, loc)
File "/home/kingsman/VKD-master/tools/eval.py", line 219, in
main()
File "/home/kingsman/VKD-master/tools/eval.py", line 210, in main
net.load_state_dict(state_dict)
File "/home/kingsman/anaconda3/envs/yolact/lib/python3.7/site-packages/torch/nn/modules/module.py", line 1052, in load_state_dict
self.class.name, "\n\t".join(error_msgs)))
RuntimeError: Error(s) in loading state_dict for TriNet:
Missing key(s) in state_dict: "backbone.features_layers.1.0.0.conv3.weight", "backbone.features_layers.1.0.0.bn3.weight", "backbone.features_layers.1.0.0.bn3.bias", "backbone.features_layers.1.0.0.bn3.running_mean", "backbone.features_layers.1.0.0.bn3.running_var", "backbone.features_layers.1.0.0.downsample.0.weight", "backbone.features_layers.1.0.0.downsample.1.weight", "backbone.features_layers.1.0.0.downsample.1.bias", "backbone.features_layers.1.0.0.downsample.1.running_mean", "backbone.features_layers.1.0.0.downsample.1.running_var", "backbone.features_layers.1.0.1.conv3.weight", "backbone.features_layers.1.0.1.bn3.weight", "backbone.features_layers.1.0.1.bn3.bias", "backbone.features_layers.1.0.1.bn3.running_mean", "backbone.features_layers.1.0.1.bn3.running_var", "backbone.features_layers.1.0.2.conv3.weight", "backbone.features_layers.1.0.2.bn3.weight", "backbone.features_layers.1.0.2.bn3.bias", "backbone.features_layers.1.0.2.bn3.running_mean", "backbone.features_layers.1.0.2.bn3.running_var", "backbone.features_layers.2.0.0.conv3.weight", "backbone.features_layers.2.0.0.bn3.weight", "backbone.features_layers.2.0.0.bn3.bias", "backbone.features_layers.2.0.0.bn3.running_mean", "backbone.features_layers.2.0.0.bn3.running_var", "backbone.features_layers.2.0.1.conv3.weight", "backbone.features_layers.2.0.1.bn3.weight", "backbone.features_layers.2.0.1.bn3.bias", "backbone.features_layers.2.0.1.bn3.running_mean", "backbone.features_layers.2.0.1.bn3.running_var", "backbone.features_layers.2.0.2.conv3.weight", "backbone.features_layers.2.0.2.bn3.weight", "backbone.features_layers.2.0.2.bn3.bias", "backbone.features_layers.2.0.2.bn3.running_mean", "backbone.features_layers.2.0.2.bn3.running_var", "backbone.features_layers.2.0.3.conv3.weight", "backbone.features_layers.2.0.3.bn3.weight", "backbone.features_layers.2.0.3.bn3.bias", "backbone.features_layers.2.0.3.bn3.running_mean", "backbone.features_layers.2.0.3.bn3.running_var", "backbone.features_layers.3.0.0.conv3.weight", "backbone.features_layers.3.0.0.bn3.weight", "backbone.features_layers.3.0.0.bn3.bias", "backbone.features_layers.3.0.0.bn3.running_mean", "backbone.features_layers.3.0.0.bn3.running_var", "backbone.features_layers.3.0.1.conv3.weight", "backbone.features_layers.3.0.1.bn3.weight", "backbone.features_layers.3.0.1.bn3.bias", "backbone.features_layers.3.0.1.bn3.running_mean", "backbone.features_layers.3.0.1.bn3.running_var", "backbone.features_layers.3.0.2.conv3.weight", "backbone.features_layers.3.0.2.bn3.weight", "backbone.features_layers.3.0.2.bn3.bias", "backbone.features_layers.3.0.2.bn3.running_mean", "backbone.features_layers.3.0.2.bn3.running_var", "backbone.features_layers.3.0.3.conv3.weight", "backbone.features_layers.3.0.3.bn3.weight", "backbone.features_layers.3.0.3.bn3.bias", "backbone.features_layers.3.0.3.bn3.running_mean", "backbone.features_layers.3.0.3.bn3.running_var", "backbone.features_layers.3.0.4.conv3.weight", "backbone.features_layers.3.0.4.bn3.weight", "backbone.features_layers.3.0.4.bn3.bias", "backbone.features_layers.3.0.4.bn3.running_mean", "backbone.features_layers.3.0.4.bn3.running_var", "backbone.features_layers.3.0.5.conv3.weight", "backbone.features_layers.3.0.5.bn3.weight", "backbone.features_layers.3.0.5.bn3.bias", "backbone.features_layers.3.0.5.bn3.running_mean", "backbone.features_layers.3.0.5.bn3.running_var", "backbone.features_layers.4.0.0.conv3.weight", "backbone.features_layers.4.0.0.bn3.weight", "backbone.features_layers.4.0.0.bn3.bias", "backbone.features_layers.4.0.0.bn3.running_mean", "backbone.features_layers.4.0.0.bn3.running_var", "backbone.features_layers.4.0.1.conv3.weight", "backbone.features_layers.4.0.1.bn3.weight", "backbone.features_layers.4.0.1.bn3.bias", "backbone.features_layers.4.0.1.bn3.running_mean", "backbone.features_layers.4.0.1.bn3.running_var", "backbone.features_layers.4.0.2.conv3.weight", "backbone.features_layers.4.0.2.bn3.weight", "backbone.features_layers.4.0.2.bn3.bias", "backbone.features_layers.4.0.2.bn3.running_mean", "backbone.features_layers.4.0.2.bn3.running_var".
size mismatch for backbone.features_layers.1.0.0.conv1.weight: copying a param with shape torch.Size([64, 64, 3, 3]) from checkpoint, the shape in current model is torch.Size([64, 64, 1, 1]).
size mismatch for backbone.features_layers.1.0.1.conv1.weight: copying a param with shape torch.Size([64, 64, 3, 3]) from checkpoint, the shape in current model is torch.Size([64, 256, 1, 1]).
size mismatch for backbone.features_layers.1.0.2.conv1.weight: copying a param with shape torch.Size([64, 64, 3, 3]) from checkpoint, the shape in current model is torch.Size([64, 256, 1, 1]).
size mismatch for backbone.features_layers.2.0.0.conv1.weight: copying a param with shape torch.Size([128, 64, 3, 3]) from checkpoint, the shape in current model is torch.Size([128, 256, 1, 1]).
size mismatch for backbone.features_layers.2.0.0.downsample.0.weight: copying a param with shape torch.Size([128, 64, 1, 1]) from checkpoint, the shape in current model is torch.Size([512, 256, 1, 1]).
size mismatch for backbone.features_layers.2.0.0.downsample.1.weight: copying a param with shape torch.Size([128]) from checkpoint, the shape in current model is torch.Size([512]).
size mismatch for backbone.features_layers.2.0.0.downsample.1.bias: copying a param with shape torch.Size([128]) from checkpoint, the shape in current model is torch.Size([512]).
size mismatch for backbone.features_layers.2.0.0.downsample.1.running_mean: copying a param with shape torch.Size([128]) from checkpoint, the shape in current model is torch.Size([512]).
size mismatch for backbone.features_layers.2.0.0.downsample.1.running_var: copying a param with shape torch.Size([128]) from checkpoint, the shape in current model is torch.Size([512]).
size mismatch for backbone.features_layers.2.0.1.conv1.weight: copying a param with shape torch.Size([128, 128, 3, 3]) from checkpoint, the shape in current model is torch.Size([128, 512, 1, 1]).
size mismatch for backbone.features_layers.2.0.2.conv1.weight: copying a param with shape torch.Size([128, 128, 3, 3]) from checkpoint, the shape in current model is torch.Size([128, 512, 1, 1]).
size mismatch for backbone.features_layers.2.0.3.conv1.weight: copying a param with shape torch.Size([128, 128, 3, 3]) from checkpoint, the shape in current model is torch.Size([128, 512, 1, 1]).
size mismatch for backbone.features_layers.3.0.0.conv1.weight: copying a param with shape torch.Size([256, 128, 3, 3]) from checkpoint, the shape in current model is torch.Size([256, 512, 1, 1]).
size mismatch for backbone.features_layers.3.0.0.downsample.0.weight: copying a param with shape torch.Size([256, 128, 1, 1]) from checkpoint, the shape in current model is torch.Size([1024, 512, 1, 1]).
size mismatch for backbone.features_layers.3.0.0.downsample.1.weight: copying a param with shape torch.Size([256]) from checkpoint, the shape in current model is torch.Size([1024]).
size mismatch for backbone.features_layers.3.0.0.downsample.1.bias: copying a param with shape torch.Size([256]) from checkpoint, the shape in current model is torch.Size([1024]).
size mismatch for backbone.features_layers.3.0.0.downsample.1.running_mean: copying a param with shape torch.Size([256]) from checkpoint, the shape in current model is torch.Size([1024]).
size mismatch for backbone.features_layers.3.0.0.downsample.1.running_var: copying a param with shape torch.Size([256]) from checkpoint, the shape in current model is torch.Size([1024]).
size mismatch for backbone.features_layers.3.0.1.conv1.weight: copying a param with shape torch.Size([256, 256, 3, 3]) from checkpoint, the shape in current model is torch.Size([256, 1024, 1, 1]).
size mismatch for backbone.features_layers.3.0.2.conv1.weight: copying a param with shape torch.Size([256, 256, 3, 3]) from checkpoint, the shape in current model is torch.Size([256, 1024, 1, 1]).
size mismatch for backbone.features_layers.3.0.3.conv1.weight: copying a param with shape torch.Size([256, 256, 3, 3]) from checkpoint, the shape in current model is torch.Size([256, 1024, 1, 1]).
size mismatch for backbone.features_layers.3.0.4.conv1.weight: copying a param with shape torch.Size([256, 256, 3, 3]) from checkpoint, the shape in current model is torch.Size([256, 1024, 1, 1]).
size mismatch for backbone.features_layers.3.0.5.conv1.weight: copying a param with shape torch.Size([256, 256, 3, 3]) from checkpoint, the shape in current model is torch.Size([256, 1024, 1, 1]).
size mismatch for backbone.features_layers.4.0.0.conv1.weight: copying a param with shape torch.Size([512, 256, 3, 3]) from checkpoint, the shape in current model is torch.Size([512, 1024, 1, 1]).
size mismatch for backbone.features_layers.4.0.0.downsample.0.weight: copying a param with shape torch.Size([512, 256, 1, 1]) from checkpoint, the shape in current model is torch.Size([2048, 1024, 1, 1]).
size mismatch for backbone.features_layers.4.0.0.downsample.1.weight: copying a param with shape torch.Size([512]) from checkpoint, the shape in current model is torch.Size([2048]).
size mismatch for backbone.features_layers.4.0.0.downsample.1.bias: copying a param with shape torch.Size([512]) from checkpoint, the shape in current model is torch.Size([2048]).
size mismatch for backbone.features_layers.4.0.0.downsample.1.running_mean: copying a param with shape torch.Size([512]) from checkpoint, the shape in current model is torch.Size([2048]).
size mismatch for backbone.features_layers.4.0.0.downsample.1.running_var: copying a param with shape torch.Size([512]) from checkpoint, the shape in current model is torch.Size([2048]).
size mismatch for backbone.features_layers.4.0.1.conv1.weight: copying a param with shape torch.Size([512, 512, 3, 3]) from checkpoint, the shape in current model is torch.Size([512, 2048, 1, 1]).
size mismatch for backbone.features_layers.4.0.2.conv1.weight: copying a param with shape torch.Size([512, 512, 3, 3]) from checkpoint, the shape in current model is torch.Size([512, 2048, 1, 1]).
size mismatch for classifier.bottleneck.weight: copying a param with shape torch.Size([512]) from checkpoint, the shape in current model is torch.Size([2048]).
size mismatch for classifier.bottleneck.bias: copying a param with shape torch.Size([512]) from checkpoint, the shape in current model is torch.Size([2048]).
size mismatch for classifier.bottleneck.running_mean: copying a param with shape torch.Size([512]) from checkpoint, the shape in current model is torch.Size([2048]).
size mismatch for classifier.bottleneck.running_var: copying a param with shape torch.Size([512]) from checkpoint, the shape in current model is torch.Size([2048]).
size mismatch for classifier.classifier.weight: copying a param with shape torch.Size([625, 512]) from checkpoint, the shape in current model is torch.Size([625, 2048]).
python-BaseException
terminate called without an active exception
Process finished with exit code 134 (interrupted by signal 6: SIGABRT)