Open LucaMarconato opened 3 months ago
A solution would be to benchmark the polygon query and bounding box implementation for points and shapes and see if one is significantly faster than the other. Ideally the polygon query is fast enough and we can drop the bounding box query implementation for points and shapes.
Note that polygon query implementation for raster types is simply calling the implementation of bounding box query for raster types; this will not change.
Ideally the polygon query is fast enough and we can drop the bounding box query implementation for points and shapes.
good point, I can see that it's faster with geopandas already vectorized methods, but would be good to benchmark indeed
Bounding box query selects circles whose center is contained inside the box, polygon query selects circles that intersect the box in any point.
You can reproduce with this code:
Which gives these three plots.
Full data
Bounding box query
Polygon query