Skip to main content
Question

Fail to convert lines to polygons correctly,


jamal
Forum|alt.badge.img+5
Fail to convert lines to polygon correctly,

 

 

I have applied the workbench below to first clean the lines and then to convert them to polygons. The correct number of polygons should match the number of texts. My thought is that the tools applied to clean the lines are not sufficient.

 

 

CAD file:

 

http://www.mediafire.com/download/742ckkkp6jaxnm7/Parcels_Al_Samou_03.dwg

 

 

 

 

 

 

 

 

What other tools should be included in the workbench to first clean the lines:

 

1. Remove duplicates

 

2. Ensure lines snapping

 

 

Thank you

 

 

Best

 

 

Jamal

17 replies

takashi
Influencer
  • September 8, 2014
Hi Jamal,

 

 

I think segment snapping before the Intersector would be effective. And stroking arcs (and ellipses if exist) before the snapping might also be effective.

 

 

In addition, found these exceptional cases in the data.

 

1) three polygons that contain multiple texts for each.

 

2) one polygon that contains no text.

 

3) one text that does not correspond to any polygon.

 

4) a few lines that don't become polygon edges.

 

 

Takashi

takashi
Influencer
  • September 8, 2014
5) two texts that duplicate about both geometry and text string.

fmelizard
Safer
Forum|alt.badge.img+18
  • Safer
  • September 8, 2014
I agree with Takashi, serious data integrity checks and cleaning should be done before transformation to polygons.

jamal
Forum|alt.badge.img+5
  • Author
  • September 8, 2014
Thanks Takashi and ETLS-Itay,

 

Sure the CAD data is really “dirty”. This is why we need to clean it as much as possible.

 

1. I have applied the ArcStroker

 

2. But couldn’t find the “segment snapping” tool.

 

 

However, I think that the number of polygons derived from lines should be CLOSE to the number of texts. Otherwise, this will indicate that the lines are not yet cleaned.

 

 

By the way, there is no effect neither for the “ArcStroker” nor for the “matcher”.

 

 

What other tools should be applied to make the number of polygons quite close to the number of texts?

 

 

 

 


takashi
Influencer
  • September 8, 2014
Take a look at the "Snapping Type" parameter of the Snapper transformer.

jamal
Forum|alt.badge.img+5
  • Author
  • September 8, 2014
You are correct Takashi,

 

The data is dirty to a degree that all tools will never clean it. I check the resulted polygons and found out many slivers.

 

Better if the data is correct at the level of AutoCAD and then applying FME.

 

 

 

 


takashi
Influencer
  • September 8, 2014
Why not try Snapper (Snapping Type: Segment Snapping) ?

 

I inspected your data with this workspace, FYI.

 

 


jamal
Forum|alt.badge.img+5
  • Author
  • September 9, 2014
Many thanks Takashi. It is much better now with the snapper. But we still need some manual work on the original CAD data.

 

 

 

 

 

 

 

 

Best

 

 

Jamal

takashi
Influencer
  • September 10, 2014
Please check again my first post in this thread.

 

"I think segment snapping before the Intersector would be effective. And stroking arcs (and ellipses if exist) before the snapping might also be effective."

 

 

This is the result of my inspection about your data. Red polygon contains no text; Green polygons contain multiple texts for each; Red text (left-top corner) does not correspond to any polygon.

 

 


jamal
Forum|alt.badge.img+5
  • Author
  • September 10, 2014
Very much appreciated Takashi for the massive efforts. Your valuable advices introduce better results

 

 

 

 

 

 

I tried to build same workbench as yours but

 

 

1. I fail to build the testfilter

 

2. To enlarge the text to be visible in the “fme inspector”

 

 

 

 

 

 

 

Could you please share your workbench?

takashi
Influencer
  • September 11, 2014
Find this link.

 

https://www.dropbox.com/s/drgpym10j6ty7sp/140911_acad2none.fmw?dl=0

 

 

To enlarge text size in FME Data Inspector, modify "fme_text_size" attribute value.

jamal
Forum|alt.badge.img+5
  • Author
  • September 11, 2014
Thank you very much Takashi,

 

 

I have applied the same settings for the “testfilter” but with no luck.

 

 

CAD file:

 

http://www.mediafire.com/download/or2juzglb27ja7g/Parcels_Al_Samou_04.dwg

 

 

Workbench:

 

http://www.mediafire.com/view/6prk49av2uk621k/Parcels_CAD_To_GIS_05.fmw

 

 

 

 

 

 

 


jamal
Forum|alt.badge.img+5
  • Author
  • September 11, 2014
I didn't get the same result for:

 

 

Single text

 

Multiple text

 

No text

takashi
Influencer
  • September 11, 2014
The SpatialRelator outputs the Requestor features after collecting attributes of related Supplier(s).

 

And, which of the ArcStroker and the Snapper should be used previously?

 

See more carefully my workspace, posts, and related help docs., please.

jamal
Forum|alt.badge.img+5
  • Author
  • September 11, 2014
Perfect. This is really great.

 

 

Very much appreciated for the massive efforts and help.

 

 

 

 

 


ponceta
Contributor
Forum|alt.badge.img+7
  • Contributor
  • June 22, 2017

The LineCloser transformer has done the job in my case.


ponceta
Contributor
Forum|alt.badge.img+7
  • Contributor
  • June 22, 2017
ponceta wrote:

The LineCloser transformer has done the job in my case.

I didn't had the snapping needs btw.

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