Skip to main content

 

Hi everyone,

I have a set of consecutive lines, and I need to detect when there is a digitization direction conflict between them. As shown in the image below, the green arrows represent the direction of my lines, but Line 2 is oriented differently compared to the others.

Is there a way in FME to detect such conflicts? Ideally, I’d like to flag or filter out the lines that have a reversed direction compared to their neighbors.

 

 

You should be able to do something with the line combiner. Under advanced settings if you choose the Preserve Orientation option, lines won’t be combined if they are not in the same direction. If you preserve lines as paths you can count the number of parts to see where lines have not been combined (you’ll have to account for the first section separately).

 

You could also choose not to Preserve Orientation, build paths, split them, then look for unmatched geometries between your original lines and the split lines.


Try the TopologyBuilder with the edge port output. There should be a ‘_from_node’ and ‘_to_node’ attribute on each of lines. Use the Matcher on one of those attributes, and the matched port should produce the lines that are going in the direction of the same node.


You should be able to do something with the line combiner. Under advanced settings if you choose the Preserve Orientation option, lines won’t be combined if they are not in the same direction. If you preserve lines as paths you can count the number of parts to see where lines have not been combined (you’ll have to account for the first section separately).

 

You could also choose not to Preserve Orientation, build paths, split them, then look for unmatched geometries between your original lines and the split lines.

Unfortunately, it didn’t work. The lines were combined anyway.