Using FME 2017.0.1.1 (Build 17291) is there any way to constrain the extent of created Voronoi polygons to polygonal features of another layer? Instead of clipping the Voronoi polygons after creating them.

Example below, I need Voronoi polygons to the extent of the green background polygons. Not simply clipped to the extent of the entirety of the background shapefile (Layer B).

If clipped afterwards, some of the data from points within the green polygons may overlap with the red area. If the red area had its own points (and Voronoi polygons) some of that area would be lost to points in the green.

enter image description here

These will be Voronoi polygons inside already created Voronoi polygons, so the background data set is continuous and all polygons will most likely contain one or more points.

~~This is a section of my previous workbench that created the background Voronoi diagram. As you can see, it is clipped at the end, which is fine as I only wanted that layer to be clipped to an outer boundary. Now I would like this next layer to be constrained by many features.~~

UPDATE: After using a PK from the polygons (Layer B) as a foreign key on the points (Layer A) and using the "Group By" parameter on the VoronoiDiagrammer, I get this error message in the Translation Log.

VoronoiDiagrammer(SurfaceModelFactory): Fail to set up the Surface Model. A minimum of 3 points are required for the Surface Model

Many of my 'Layer B' polygons only contain 2 points from 'Layer A'.

If I clone all the points, can I randomly offset the clones before the VoronoiDiagrammer?


  • SpatialFilter the polygons (Layer A) to remove any which do not contain any points (Layer B) before giving points the foreign key.

  • Create 2 clones of all the points and offset the 2 sets of clones to different constants. (Creating very small triangles). This removes the error of:

Surface Model cannot be constructed. Either all points are linear or initial set of points did not consist of 3 non NAN elevations

If all clones were offset using the same shift in coordinates.

To get the workbench to run all the way through, I have to set the offset to a minute 1mm from the original x,y ensuring that all 3 created points fall within the polygon of 'Layer A'. The last problem is that if a polygon from 'Layer A' only contains one original point form 'Layer B', the Voronoi process only outputs the tiny triangles and does not fill to the extent of the polygon in 'Layer A'.

Tiny triangle polygon

  • If your points some how had an attribute which matched the red or green polygons, you could then use the groupby function which would potentially only run the voronoi inside the green. I think you should groupby some unique polygon identifier. – Fezter Aug 2 '17 at 1:03
  • I have performed a Counter and PointOnAreaOverlayer to give the polygons a primary key and then add that as a foreign key to the points. My next problem is I am now getting the error >VoronoiDiagrammer(SurfaceModelFactory): Fail to set up the Surface Model. A minimum of 3 points are required for the Surface Model, as some of my polygons only contain 2 points. – whjd Aug 2 '17 at 7:35
  • How can a polygon contain only 2 points? – julsbreakdown Aug 2 '17 at 8:36
  • I have added a clarification, only 2 points from my point layer intersect with my polygon layer. – whjd Aug 2 '17 at 9:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.