I download the pretrained model, but when I run submission_kitti.py ,it print wrong disparity
JeongJaecheol opened this issue · 4 comments
@JeongJaecheol @FlyingGaifield It would be great if you can share the following, to help me debug this issue:
- models/config.py
- pre-trained model you used
- torch and torchvision versions
Thanks !!
-
models/config.py
I changed only 'mode' config to 'evaluation' -
pre-trained model you used
I used both best model weights(DeepPruner-best-sceneflow.tar, DeepPruner-best-kitti.tar) -
torch and torchvision versions
I tested in (python 2.7.12, torch 0.4.1, torchvision 0.2.0) and (python 3.7.0, torch 1.1.0, torchvision 0.3.0)
After loading weights I am getting this error.
finetune_kitti.py: loading model...
Traceback (most recent call last):
File "finetune_kitti.py", line 101, in
model.load_state_dict(state_dict['state_dict'], strict=True)
File "/usr/local/lib/python2.7/dist-packages/torch/nn/modules/module.py", line 719, in load_state_dict
self.class.name, "\n\t".join(error_msgs)))
RuntimeError: Error(s) in loading state_dict for DataParallel:
Missing key(s) in state_dict: "module.feature_extraction.branch1.1.0.weight", "module.feature_extraction.branch1.1.1.running_var", "module.feature_extraction.branch1.1.1.bias", "module.feature_extraction.branch1.1.1.weight", "module.feature_extraction.branch1.1.1.running_mean".
Unexpected key(s) in state_dict: "module.refinement_net1.conv1.0.0.weight", "module.refinement_net1.conv1.0.1.weight", "module.refinement_net1.conv1.0.1.bias", "module.refinement_net1.conv1.0.1.running_mean", "module.refinement_net1.conv1.0.1.running_var", "module.refinement_net1.conv1.0.1.num_batches_tracked", "module.refinement_net1.conv1.1.0.weight", "module.refinement_net1.conv1.1.1.weight", "module.refinement_net1.conv1.1.1.bias", "module.refinement_net1.conv1.1.1.running_mean", "module.refinement_net1.conv1.1.1.running_var", "module.refinement_net1.conv1.1.1.num_batches_tracked", "module.refinement_net1.conv1.2.0.weight", "module.refinement_net1.conv1.2.1.weight", "module.refinement_net1.conv1.2.1.bias", "module.refinement_net1.conv1.2.1.running_mean", "module.refinement_net1.conv1.2.1.running_var", "module.refinement_net1.conv1.2.1.num_batches_tracked", "module.refinement_net1.conv1.3.0.weight", "module.refinement_net1.conv1.3.1.weight", "module.refinement_net1.conv1.3.1.bias", "module.refinement_net1.conv1.3.1.running_mean", "module.refinement_net1.conv1.3.1.running_var", "module.refinement_net1.conv1.3.1.num_batches_tracked", "module.refinement_net1.conv1.4.0.weight", "module.refinement_net1.conv1.4.1.weight", "module.refinement_net1.conv1.4.1.bias", "module.refinement_net1.conv1.4.1.running_mean", "module.refinement_net1.conv1.4.1.running_var", "module.refinement_net1.conv1.4.1.num_batches_tracked", "module.refinement_net1.conv1.5.0.weight", "module.refinement_net1.conv1.5.1.weight", "module.refinement_net1.conv1.5.1.bias", "module.refinement_net1.conv1.5.1.running_mean", "module.refinement_net1.conv1.5.1.running_var", "module.refinement_net1.conv1.5.1.num_batches_tracked", "module.refinement_net1.classif1.weight".
size mismatch for module.refinement_net.conv1.0.0.weight: copying a param of torch.Size([32, 42, 3, 3]) from checkpoint, where the shape is torch.Size([32, 74, 3, 3]) in current model.
size mismatch for module.feature_extraction.lastconv.0.0.weight: copying a param of torch.Size([128, 320, 3, 3]) from checkpoint, where the shape is torch.Size([128, 352, 3, 3]) in current model.