[SciPy-user] k nearest neighbour

Stefan van der Walt stefan@sun.ac...
Thu Oct 25 01:58:01 CDT 2007

Hi Barry

On Wed, Oct 24, 2007 at 02:51:03PM -0700, Barry Wark wrote:
> For those interested, I've cleaned up (and documented a little) my
> wrapper for the Approximate Nearest Neighbor library. The source is
> available as a zip archive at
> http://rieke-server.physiol.washington.edu/~barry/ann/ANNwrapper.zip
> (BSD license).

Fantastic, this is a very useful contribution.

> The setup.py contains instructions for installation and usage. You
> will need the ANN library (from http://www.cs.umd.edu/~mount/ANN/),
> setuptools, and SWIG installed.

Maybe also add instructions to build in-place, i.e.

   python setup.py build_ext -i

> I think this wrapper may be useful as an addition to scipy, but I
> haven't investigated where it might be most appropriate. I'd be happy
> to relicense if necessary.

The license is LGPL, so a SciKit would be appropriate.

> Any suggestions or patches welcome.

For statistical unit tests, use numpy.testing.assert_almost_equal;
this leaves a bit of leeway for floating point roundoff (some of the
tests currently fail [randomly] on my system).


More information about the SciPy-user mailing list