Skip to main content
Solved

Generalising being too aggressive at times.

  • September 28, 2020
  • 3 replies
  • 103 views

bjudes
Enthusiast
Forum|alt.badge.img+10

Hi,

I have a dataset that as part of a cleanup I am generalising. It is a vector dataset derived from aerial photography, therefore it has a slightly pixelated look. The point of the generalising is to remove this look and 'smooth' the output.

The problem is that at times the output becomes too generalised. See below where relatively straight lines become quite pronounced.

OneTwo

In this instance, I do not want the lines to change much. But for example below these particular parameters do a great job. Here, with the same parameters as above it has done a great job of removing the pixelated look.

Three

Four

Is there any way to limit the generalisation of the 90 degree angles and allowing the smoothing to take place in other areas?

I think it might be unlikely there is a solution, it may just be a limitation of the generaliser transformer. I have tried all the different smoothing parameters/algorithms and this seems to be the best. I'm currently using the NURBfit (Smooth) with a degree of basis polynomial of between 2 and 4.

 

Thanks for any help.

B

Best answer by bjudes

Thanks @hkingsbury​ and @Hans van der Maarel​, in the end I used the Densifier transformer. This put more structure on the polygon and the edges were much more in check with what they were before.

Thanks for the help.

B

View original
Did this help you find an answer to your question?

3 replies

hkingsbury
Celebrity
Forum|alt.badge.img+53
  • Celebrity
  • September 28, 2020

Hey, just had a go at generalizing a perfect polygon. The NURBfit algorithm produced an oval like in your example. this is because its a smoothing algorith, you're most likely after a generalizing algorithm.

See here: http://docs.safe.com/fme/2020.1/html/FME_Desktop_Documentation/FME_Transformers/Transformers/generalizer.htm

 

With the douglas algorithm with tolerance set to 1 (or something else) what does your second example look like?


redgeographics
Celebrity
Forum|alt.badge.img+49

To expand on @hkingsbury​ 's suggestion, a combination of a generalizing and a smoothing algorithm, e.g a Douglas followed by a NURBfit (so 2 Generalizer transformers in a row), could yield good results. You'll also need to play a bit with the tolerances. For the Douglas I'd start experimenting around half the original pixel size and see what that does.


bjudes
Enthusiast
Forum|alt.badge.img+10
  • Author
  • Enthusiast
  • Best Answer
  • October 13, 2020

Thanks @hkingsbury​ and @Hans van der Maarel​, in the end I used the Densifier transformer. This put more structure on the polygon and the edges were much more in check with what they were before.

Thanks for the help.

B


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