Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
目前有一个工作示例使用scipy.spatial.KDTree最近邻查找一些 x,y 点。
scipy.spatial.KDTree
问题是,如果我有每个 x,y 点的日期时间数据,我可以将其放入 KDTree 并修改我的空间最近邻搜索以进行最近时空邻居搜索吗?
搜索最近的空间邻居:
pts = np.array([[1, 50], [1.89, 52.4]]) print tree.query(pts, k=5)
pts = np.array([[1, 50], [1.89, 52.4]])
print tree.query(pts, k=5)