layumi / Person_reID_baseline_pytorch

:bouncing_ball_person: Pytorch ReID: A tiny, friendly, strong pytorch implement of person re-id / vehicle re-id baseline. Tutorial 👉https://github.com/layumi/Person_reID_baseline_pytorch/tree/master/tutorial
https://www.zdzheng.xyz
MIT License
4.1k stars 1.01k forks source link

Evaluation metric incorrect? #191

Open PatrickBue opened 4 years ago

PatrickBue commented 4 years ago

I noticed that in this line the CMC is divided by the number of query images: https://github.com/layumi/Person_reID_baseline_pytorch/blob/master/evaluate.py#L87

However, the number of values summed up to form CMC (ie the CMC_tmp's) is typically lower than the number of query images. See this line: https://github.com/layumi/Person_reID_baseline_pytorch/blob/master/evaluate.py#L80

Is that intended and if so why is that? Thx!

layumi commented 4 years ago

Hi @PatrickBue You may check this line, if the ground-truth is not in the gallery. We will skip it, and return CMC_tmp=0, which equals to the continue. https://github.com/layumi/Person_reID_baseline_pytorch/blob/master/evaluate.py#L33