Skip to main content
Question

How to run FMETransformer in pythoncaller


mccunee
Contributor
Forum|alt.badge.img+2

I need to use the PythonCaller because the area on area overlayer doesn’t work with my input featureset. I want each polygon in featureset A to overlay against all the polygons in Featureset B (which does not self intersect) and then drop overlays with NA values in specific columns. I found documentation for the fmeobjects.PythonCaller, but the documentation doesn’t include how to actually run the transformer.

fmeobjects.FMETransformer — Python FME API FME 2024.1 b24615 documentation (safe.com)

i.e. what do I do with f = fmeobjects.FMETransformer after I’ve set the attributes?

Additionally, it’s unclear what the parameters are for this object, as there is no function definition returned to define what is required for each transformer type.

AreaOnAreaOverlayer (safe.com)

Related questions:

AreaonAreaOverlay with intersecting features | Community (safe.com)

Where is the FME User manual | Community (safe.com)

3 replies

redgeographics
Celebrity
Forum|alt.badge.img+47

It doesn’t sound like something you wouldn’t be able to accomplish with regular transformers to be honest. If you want to pursue that option, could you please share how you’ve set things up?


jkr_wrk
Influencer
Forum|alt.badge.img+28
  • August 9, 2024

I don't understand your complete goal. And that's why I don't know how to come with the right solution.

 

But if you store the complete geometry, a label “A” and an ID to the AreaOnAreaOverlaying features you can check what portion of A is overlaying what portion of B. And restore the ID and even the Geometry of FeatureSet A.


s.jager
Influencer
Forum|alt.badge.img+16
  • Influencer
  • August 9, 2024

As the others have said, it is very unclear what you are trying to achieve. In part that is because the phrase “doesn’t work” is not very helpful: do you get error messages? Does it not do what you expect? Does it return strange results? A bit more explanation of “doesn’t work” would already be quite helpful in this case. Personally I find the AreaOnAreaOverlayer not very useful as it is right now, and never use it.

However: Maybe the Clipper would work in your scenario? If you’re worried about the original geometry, it’s easy enough to use the GeometryExtractor to preserve the geometry, and possibly restore it after you’ve done your work.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings