Wanggcong / Spatial-Temporal-Re-identification

[AAAI 2019] Spatial Temporal Re-identification
MIT License
384 stars 77 forks source link

*** KeyError: 'query_f' #20

Open IvyYZ opened 5 years ago

IvyYZ commented 5 years ago

When I run "python3 evaluate_st.py --name ft_ResNet50_pcb_market_e ", I have some problems. problem like this: *** KeyError: 'query_f' I load model is "model/modelft_ResNet50_pcb_market_e/pytorch_result2.mat", which from the link (baiduyun Link:https://pan.baidu.com/s/1QMp22dVGJvBH45e4XPdeKw password:dn7b). I checked the code: result = scipy.io.loadmat('model/'+name+'/'+'pytorch_result2.mat') I found "result" has no key 'query_f'. I don't know how to operate.

Wanggcong commented 4 years ago

When I run "python3 evaluate_st.py --name ft_ResNet50_pcb_market_e ", I have some problems. problem like this: *** KeyError: 'query_f' I load model is "model/modelft_ResNet50_pcb_market_e/pytorch_result2.mat", which from the link (baiduyun Link:https://pan.baidu.com/s/1QMp22dVGJvBH45e4XPdeKw password:dn7b). I checked the code: result = scipy.io.loadmat('model/'+name+'/'+'pytorch_result2.mat') I found "result" has no key 'query_f'. I don't know how to operate.

I guess the file path could be incorrect. "model/modelft_ResNet50_pcb_market_e/pytorch_result2.mat"

should be "model/ft_ResNet50_pcb_market_e/pytorch_result2.mat"

I think you can check your path, and use the os module to construct the correct path, e.g., os.path.join(xxx,xxx).