optimization question
Paul Harris
paulharris at computer.org
Mon Mar 30 23:55:59 UTC 2009
Hi Willi,
I agree, this change was done at one point but it was not done correctly,
and was giving incorrect results.
I had been hoping to make the changes as part of an overall
templated-distance change, but that hasn't happened yet.
2009/3/30 Willi Richert <w.richert at gmx.net>
> Hi,
>
> in kdtree.hpp and node.hpp very often sqrt is used.
>
> d = sqrt(d);
> if (d <= __max)
> ...
> __max itself is also a sqrt()ed value
>
> IMHO, the speed could be improved if that is omitted everywhere. Just
> comparing the squared distances should work if the specified ranges are
> converted once at the interface methods.
>
> wr
>
> _______________________________________________
> libkdtree-devel mailing list
> libkdtree-devel at lists.alioth.debian.org
> http://lists.alioth.debian.org/mailman/listinfo/libkdtree-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.alioth.debian.org/pipermail/libkdtree-devel/attachments/20090331/ef12b51e/attachment.htm
More information about the libkdtree-devel
mailing list