stefankoegl / kdtree

A Python implementation of a kd-tree
ISC License
365 stars 118 forks source link

Now search_knn_dist returns the distances with the point itself #49

Open harish1996 opened 4 years ago

harish1996 commented 4 years ago

Adds the distances also with the point itself during calls of search_knn_dist. Calculating distances of each of the nodes again is redundant. If one doesn't need the distances, they can just ignore it and just form a new list using list comprehension.

only_nodes = [ i[0] for i in results ]

coveralls commented 4 years ago

Coverage Status

Coverage decreased (-0.05%) to 86.268% when pulling 63c586d5d3d462db7a1915919d9fd2b6de0482ed on harish1996:master into 587edc7056d7735177ad56a84ad5abccdea91693 on stefankoegl:master.