Re:Making Python 100x faster with less than 100 lines of Rust
by wcrossbow on Thursday March 30, 2023 @08:50AM
(#35371839)
Im assuming the polygons dont change to often so you can amortize the construction of the quadtree. Depending on your world view the implementation is trivial since Shapely, a dependency they already likely have, has an implementation of it.
Re:Making Python 100x faster with less than 100 lines of Rust
by ohr on Friday March 31, 2023 @07:54AM
(#35385664)
Author here: actually, in this analogy (as this is just a demo library), the polygons change each time so we couldn't use this type of optimization (at least not in a straightforward way).
(e.g. it doesn't need to be "as fast as possible", just fast enough to no longer be a workflow bottleneck)