[SciPy-Dev] Enhancements to scipy.spatial.cKDTree
Mon Jul 16 18:21:04 CDT 2012
Ok, I finished cleaning up the other functions that keep track of
rectangle-rectangle min/max distances. The other enhancements with respect
to int's and PyArray_DATA are also in (one case where it's not so easy to
get rid of PyArray_DATA(arr) is when arr is only defined as an np.ndarray,
as it must if it's a class member variable). I'll attack query_ball_point
and perhaps query tomorrow night and do some more general clean-up then as
well (e.g., in how Rectangle objects get set up). I haven't yet looked
into the ref-count issue Sturla brought up.
Thanks for all the useful feedback today!
On Mon, Jul 16, 2012 at 7:08 PM, Sturla Molden <email@example.com> wrote:
> Den 16.07.2012 02:00, skrev Patrick Varilly:
>> That said, now that the initial effort is complete, it's obvious that a
>> clear pattern recurs in the kd-tree walking algorithms: keeping incremental
>> track of the minimum/maximum distances between two hyperrectangles as
>> they're successively split (alternatively, a hyperrectangle and a point).
>> If that primitive is abstracted, the code becomes a lot more readable
> Yes, that was much better :-)
> +1 for doping it like this (even if there is a small speed penalty).
> We might even do this to the original cKDTree.query function as well.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the SciPy-Dev