princeton-vl / pytorch_stacked_hourglass

Pytorch implementation of the ECCV 2016 paper "Stacked Hourglass Networks for Human Pose Estimation"
BSD 3-Clause "New" or "Revised" License
469 stars 94 forks source link

run a pretrained module #24

Closed hankroldd closed 3 years ago

hankroldd commented 3 years ago

I have downloaded the 2HG pre-trained module and want to apply it on the test.py. But there's an error
'' train.py", , in reload
config['train']['optimizer'].load_state_dict(checkpoint['optimizer']) ''optimizer.py" in load_state_dict raise ValueError("loaded state dict contains a parameter group " ValueError: loaded state dict contains a parameter group that doesn't match the size of optimizer's group

Is there any way I can rectify this problem? Or what is the appropriate way to use the pre-trained module based on the code.

crockwell commented 3 years ago

Have you changed the params in task/pose.py? For example, nstack should be 2 for 2 HG version. Apologies if this wasn't documented super clearly

hankroldd commented 3 years ago

Thank you for your help. I didn't quite understand this parameter before