python中的K最近邻居 [英] K nearest neighbour in python

查看:123
本文介绍了python中的K最近邻居的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在python中计算K最近邻.我应该使用哪个图书馆?

解决方案

我认为您应该使用 scikit ann .

此处有一个很好的教程. >

根据文档:

ann是由SWIG生成的python封装程序,用于近似最近邻居(ANN)库( http://www.cs.umd.edu/~mount/ANN/),由David M. Mount和Sunil Arya开发. ann提供了一个不变的kdtree实现(通过ANN),它可以执行k个最近邻居并近似k

I would like to calculate K-nearest neighbour in python. what library should i use?

解决方案

I think that you should use scikit ann.

There is a good tutorial about the nearest neightbour here.

According to the documentation :

ann is a SWIG-generated python wrapper for the Approximate Nearest Neighbor (ANN) Library (http://www.cs.umd.edu/~mount/ANN/), developed by David M. Mount and Sunil Arya. ann provides an immutable kdtree implementation (via ANN) which can perform k-nearest neighbor and approximate k

这篇关于python中的K最近邻居的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆