You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When we execute code that leads us to CPL_geos_binop with feature collections A and B, we end up:
creating a tree of items in B
iterating over A, and
using the tree to find matching items in B
if matching items are found, creating a prepared geometry for A[i]
calling a GEOS predicate using the prepared geometry
For a point-in-polygon join, we get a big performance boost by preparing our polygon geometries and testing each point against the prepared polygons. But we only end up doing this if our polygons are in argument A and our points are in argument B. If the arguments are reversed, we end up preparing the points and testing them against unprepared polygons, which is much less useful.
Is it worth trying to infer the geometry types of A and B and transparently switching them if it would be beneficial? Or, should documentation inform the user about the performance implications of argument order?
The text was updated successfully, but these errors were encountered:
When we execute code that leads us to
CPL_geos_binop
with feature collectionsA
andB
, we end up:B
A
, andB
A[i]
For a point-in-polygon join, we get a big performance boost by preparing our polygon geometries and testing each point against the prepared polygons. But we only end up doing this if our polygons are in argument
A
and our points are in argumentB
. If the arguments are reversed, we end up preparing the points and testing them against unprepared polygons, which is much less useful.Is it worth trying to infer the geometry types of
A
andB
and transparently switching them if it would be beneficial? Or, should documentation inform the user about the performance implications of argument order?The text was updated successfully, but these errors were encountered: