Hi,
This may improve the performance.
- In the Navigator window, make sure that the Clipper features (polygons) will be read first. If the reader for the Clippers was not at the top of the tree, move it to the top.
- Set "Clippers First" to the "Clipper Type" parameter of the Clipper transformer.
Takashi
I think Takashi's answer is the one that is going to work for you. But another possibility would be to maybe pre-process the data using a simpler method, in order to drop anything that is nowhere close to a match.
For example, use a BoundingBoxAccumulator on the polygons, then use that bounding box as the filter in a SpatialFilter to find what lines are completely outside of it. Those lines can be discarded, as if they are completely outside the bounding box, they are never going to be touched by the Clipper.
Depending on how many features there are, it could save the Clipper a lot of work.
I don't say for sure this would be faster, and if this is a one-off project it might not be worth bothering with, but I've had some success with that technique in the past (outside of FME) so if this is a recurring process it would be worth experimenting.
I think Takashi's answer is the one that is going to work for you. But another possibility would be to maybe pre-process the data using a simpler method, in order to drop anything that is nowhere close to a match.
For example, use a BoundingBoxAccumulator on the polygons, then use that bounding box as the filter in a SpatialFilter to find what lines are completely outside of it. Those lines can be discarded, as if they are completely outside the bounding box, they are never going to be touched by the Clipper.
Depending on how many features there are, it could save the Clipper a lot of work.
I don't say for sure this would be faster, and if this is a one-off project it might not be worth bothering with, but I've had some success with that technique in the past (outside of FME) so if this is a recurring process it would be worth experimenting.
I agree, when dealing with 20,000+ features there is usually a performance boost in pre-filtering the data. Less than that performance gain in the clipper is offset by the cost of the spatialFilter.
Yeah, i always try not to use clippers on sets with a large number of clippees....too sloow.
Depending on how many objects you have, i suggest a AreOnArea overlayer followed by a tester.
AreaonArea has as added advantage the possible use of parallel processing.
First make sure all objects have a unique id.
Use a (single) tiler on both inputs, then separate them using a tester on "fme_feature_type" (expose on readers). Then use a AreaOnArea overlayer and group by tile id's (for instance row_id and column_id).
Mind setting parallel processing on aggressive or higher...you will hog down your entire machine for the duration of the proces ( all cores at 100%..lol).
After this a tester to test for overlaps >1 and fme_feature_type = clipperobjectnames.
Even though the tiling takes a bit o' time, the total proces will be fast.
Try it out.