3

I have a single-part polygon containing thousands of features which I converted/dissolved into a multipart polygon. Which is faster to process (i.e. when I clip them using a simple rectangular polygon)? Is there any basis or explanation for that?

0

1 Answer 1

6

Clipping, intersection etc are performed two steps:

  1. Identify which features should be processed
  2. Process each feature found in the previous step.

For step #1, the bounding box of each feature is typically used first, ideally stored in a spatial index. If using a layer with a single giant (multi)polygon, then the feature will be typically returned. If using a layer with many small (single)polygons, only the features truly intersecting will be found.

For step #2, the number of vertices in each feature to be process matters a lot. If a single giant (multi)polygon is to be processed, the computation becomes very complex and slow. If many small features were to be processed, the clipping/intersection becomes very fast.

Overall, it is faster to process many small polygons rather than bigger ones.

1
  • +1 You might note that there is a law of diminishing returns involved -- once all the polygons are tiny, making more of them may slow things down again.
    – Vince
    Jan 22 at 13:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.