Open mthodoris opened 1 year ago
I'm encountering the same problem
I had the same problem, have you solved it yet?
I solved it and I found that the author provided the WASPv1 pretrained model. Therefore, you need to change the OmniPose/models/omnipose.py to waspv1
python inference.py --cfg=experiments/coco/omnipose_w48_384x288.yaml experiments/coco/omnipose_w48_384x288.yaml MODEL_FILE: 'weights/coco/OmniPose_HRw48_384/checkpoint.pth'
inference.py modify
plt.savefig(save_path, format='jpg', bbox_inches='tight', dpi=100)
models/omnipose.py uncomment self.wasp comment self.waspv2
change model.load_state_dict(new_model_state_dict, strict=True) strict=False to True It will print the missing keys as follows.: Missing key(s) in state_dict: "waspv2.aspp1.atrous_conv.spatialConv.weight", "waspv2.aspp1.atrous_conv.pointConv.weight", "waspv2.aspp2.atrous_conv.spatialConv.weight", "waspv2.aspp2.atrous_conv.pointConv.weight", "waspv2.aspp3.atrous_conv.spatialConv.weight", "waspv2.aspp3.atrous_conv.pointConv.weight", "waspv2.aspp4.atrous_conv.spatialConv.weight", "waspv2.aspp4.atrous_conv.pointConv.weight".
but models/omnipose.py change from waspv2 to wasp model.load_state_dict(new_model_state_dict, strict=True) pass successfully.
so i think the 'checkpoint.pth' is wasp instead of waspv2 in the paper
Trying to run the test.py and inference.py using pretrained_models returns 0.0 avg_precision and random keypoints inside the images. Are the provided models pre-trained? Is there anything that I am missing?