yxgeee / FD-GAN

[NeurIPS-2018] FD-GAN: Pose-guided Feature Distilling GAN for Robust Person Re-identification.
https://yxgeee.github.io/projects/fdgan.html
281 stars 80 forks source link

load_state_dict error in stateII #19

Closed ahuwangsheng closed 5 years ago

ahuwangsheng commented 5 years ago

The following figure shows the keys for the model.state_dict saved in stage1 image The following figure shows the keys for the state_dict loaded in stage11 image

The following figure shows the errors,what should I do?@yxgeee image

heerduo commented 5 years ago

The following figure shows the keys for the model.state_dict saved in stage1 image The following figure shows the keys for the state_dict loaded in stage11 image

The following figure shows the errors,what should I do?@yxgeee image

Hello, I encounter the same problem. Have you solved it?

yxgeee commented 5 years ago

You could kindly use or remove the function remove_module_key function (https://github.com/yxgeee/FD-GAN/blob/master/fdgan/model.py#L88) to match the key name of loaded state dict and your model.

heerduo commented 5 years ago

Thanks a lot!