graspnet / graspnet-baseline

Baseline model for "GraspNet-1Billion: A Large-Scale Benchmark for General Object Grasping" (CVPR 2020)
https://graspnet.net/
Other
521 stars 153 forks source link

About knn in lablel_generation #53

Closed stunback closed 1 year ago

stunback commented 1 year ago

Hello, thanks for your excellent works. And I have a problem in label_generation.py, line 60 that:

view_inds = knn(grasp_views_trans_, grasp_views_, k=1).squeeze() - 1

why the knn result indices need to -1 ?

Hope for your reply, thanks a lot.

chenxi-wang commented 1 year ago

If I remember correctly, the indices returned from this knn implementation start from 1 instead of 0. So the results need to -1.