该算法的名称,有一个numpy的/ SciPy的实现呢?算法、有一个、名称、SciPy

2023-09-12 21:22:21 作者:白满川

我已经看到了这个算法描述,我宁愿不另起炉灶,如果一个标准的实施存在。我还了解到,如果有一个SciPy的/ numpy的实现,它通常是比什么都快得多,我可以推出自己的蟒蛇。

I've seen this algorithm described, and I'd rather not reinvent the wheel if a standard implementation exists. I've also learned that if there is a scipy/numpy implementation, it is usually much faster than anything I can roll myself in python.

我在飞机上(数百万)的大量点。与包括所有点的大箱子开始,我想盒子不断细分为相等的面积分箱。细分将继续递归,而至少有1000分的分箱。该算法返回描述细分和指向树的每个叶结点的映射树

I have a large number of points on the plane (several million). Starting with a large box that encompasses all the points, I'd like to continuously subdivide the box into equal area sub-boxes. The subdivision continues recursively while there are at least 1,000 points in the sub-box. The algorithm returns a tree that describes the subdivisions and the mapping of the points to each leaf node of the tree.

这是什么算法的名称(类似分而治之?),以及是否有这样做的时候给点意见的2D numpy的阵列的标准方法?

What is the name of this algorithm (something like divide and conquer?), and is there a standard method of doing it when given a 2D numpy array of points?

推荐答案

这就是所谓的一个四叉树分区。至于Python的code,见这个线程

It's called a quadtree partition. As far as Python code, see this thread.