lemniscate.pytorch icon indicating copy to clipboard operation
lemniscate.pytorch copied to clipboard

Current evaluation is incorrect

Open kaleidoscopical opened this issue 5 years ago • 5 comments

It is possible that the 30-nearest neighbors share same labels (only 1 prediction). Therefore, it is impossible to calculate the top-5 acc. Please re-evaluate the scripts. Thank you.

kaleidoscopical avatar Oct 26 '19 13:10 kaleidoscopical

Top-k means first n (n <= k) predictions. Having 1 prediction for certain samples is ok.

yjxiong avatar Nov 05 '19 21:11 yjxiong

Then, your code can not reproduce the reported top-5 results in your paper : )

kaleidoscopical avatar Nov 08 '19 09:11 kaleidoscopical

Please let us know the accuracy you got in experiments. We may help investigate.

yjxiong avatar Nov 08 '19 18:11 yjxiong

@kaleidoscopical which top-5 number are you referring to? Thanks.

zhirongw avatar Jan 13 '20 05:01 zhirongw

Hello! Thanks for sharing your implementation. I have the feeling that top-5 scores are incorrectly computed here. The line computes "the sum" of all 5 predictions. Instead I would write

top5 = top5 + (correct.narrow(1,0,5).sum(dim=1) > 0).sum().item()

Can you please correct me if I am wrong?

mbsariyildiz avatar Apr 15 '20 15:04 mbsariyildiz