Skip to main content

I have a workspace that removes specific vertices using a point feature class. Hopefully if anyone is looking for such a tool they will find this help topic. It is located on Geonet:

https://community.esri.com/thread/95310

Here is the problem:

This workspace works wonderfully except that many features fail to output. After troubleshooting the workspace, I think I have determined the problem is with the incoming data. If I go back to the original data in ArcGIS and use the "Replace Geometry Tool" in the advanced editing toolbar. The features will then output in the workspace. However, I don't want to manually fix all of the failed features--though it's certainly better than manually deleting all of the vertices.

Does anyone have any idea what might be causing this, and what can be done to fix it automatically?

I have tried Repair Geometry (Arc) and Geometry Validator (FME) with everything passed . I have also tried loading copy/paste, and appending the features to a new geodatabase/feature class.

I'd appreciate any help anyone can provide. The workspace and geodatabase are attached if anyone would like to see firsthand what is going on.

Thanks.

Hi @justinv, every vertex to be removed seems to be on edges of rectangular shapes. If my observation was correct, the Generalizer (Douglas algorithm) might help you. I tested tolerance = 1e-4, but you will have to determine the optimal tolerance according to your requirement.


Thanks, Takashi.

Yes, the generalizer works very well for those mostly rectangular features. I have been using this transformer but I am looking for something with a little more control over what gets removed and what doesn't. Sometimes even the extra vertices along edges are legitimate and I don't want them removed. I have point files with attributes that make it easy for me to separate the good from the bad. The Generalizer can't take this into account. Previously I excluded the polygons that had these legitimate vertices or had more complex geometry, like the area in the southeast (rivers, coastlines, etc.), ran the Generalizer, and then went back and removed the extra vertices later. It leaves a lot of cleanup.

This feature class has about 3,000 features and is manageable. I am working with feature classes with over 2 million features.

At this point, am seeing a combination of the two for a solution. Perhaps run the vertex cleaner. Then run the Generalizer on the failed feature classes that are rectangular. Then manually clean up the rest. I think FME can do it all though.

Thanks again.


I found that each boundary line of the failed polygon starts (and ends) with a middle point on an edge, and also a point read from "DeleteTheseVertices" feature type matches the start/end points. Result, such a boundary will be an unclosed line after removing the start/end nodes, then the PointConnector outputs them via the Line port.

Probably you could restore the unclosed lines to polygons by closing them with LineCloser.


Hi @takashi, I see what you are saying. The failing features are missing the last closing point because it was removed in the change detector. I am wondering if somehow I can just duplicate the first point and add the value of the last point plus 1. Perhaps I could do that with a list.

I'll give it a shot.

 


I was able to get this to work by adding another start/end point to all of the features. Before the PointConnector, I added a StatisticsCalculator grouped by the shell attribute to get the min and max of the _count. Since the points are sorted, a DuplicateRemover leaves the first/last point. Then the _count gets calculated to the max plus one. One more sort on the _count gets everything ready for the point connector. This creates an extra start/end point for every feature, but I think that doesn't matter since the point connector is grouped by the shell.

Thank you your replies @takashi.


Reply