Skip to main content

I'd like to learn how to extract end nodes (as opposed to nodes at intersections) from a list of nodes coming out of the TopologyBuilder. I'm only putting in a few alignments that intersect in the TopologyBuilder. I've seen some similar questions here but there wasn't enough detail in the answers for me to catch on. An example workflow or screenshot would be great.

 

Hi @osdev​ , if you check the Generate List From Input Edges option in the TopologyBuilder, a list attribute storing the information of connected edges will be added to every node feature output from the Node port. You can count the number of the elements in the list to determine if a node is dead end.topologybuilder-generate-list-from-edges


Hi @osdev​ , if you check the Generate List From Input Edges option in the TopologyBuilder, a list attribute storing the information of connected edges will be added to every node feature output from the Node port. You can count the number of the elements in the list to determine if a node is dead end.topologybuilder-generate-list-from-edges

Thank you @Takashi Iijima​ ! It seems like a start node has _edge{0}.fme_arc_id value = 1 while an end point has value = -1. Is that correct? If so, what transformer do you recommend using to filter out the _node_number(s) from the list that have an _edge{0}.fme_arc_id value = 1 or -1?


Thank you @Takashi Iijima​ ! It seems like a start node has _edge{0}.fme_arc_id value = 1 while an end point has value = -1. Is that correct? If so, what transformer do you recommend using to filter out the _node_number(s) from the list that have an _edge{0}.fme_arc_id value = 1 or -1?

I don't think my logic above is correct. I added a Tester on nodes targeting _edge{0}.fme_arc_id and pulled values = 1 and -1 from the list. I ran a test with 3 intersecting edges thinking it should return 6 results with 3 values = 1 and 3 values = -1 for start and end notes, but this did not happen.


Thank you @Takashi Iijima​ ! It seems like a start node has _edge{0}.fme_arc_id value = 1 while an end point has value = -1. Is that correct? If so, what transformer do you recommend using to filter out the _node_number(s) from the list that have an _edge{0}.fme_arc_id value = 1 or -1?

My follow up question is what transformer and logic is needed to identify the start and end nodes from the list w/ attributes _attr_name and _attr_value for _edge{0}.fme_arc_ids?


Thank you @Takashi Iijima​ ! It seems like a start node has _edge{0}.fme_arc_id value = 1 while an end point has value = -1. Is that correct? If so, what transformer do you recommend using to filter out the _node_number(s) from the list that have an _edge{0}.fme_arc_id value = 1 or -1?

The value of each element of the "_edge{}.fme_arc_id" indicates the value of "_edge_id" of an edge connected to the node, and the number of elements in the list is equal to the number of edges connected to the node.

You can determine the node is a dead end by counting the number of elements in the list. That is, you can say the node is a dead end if the list has just one element. You can use the ListElementCounter to get the number of elements in a list attribute.

 

>Addition] This description and the figure below (from the Help of TopologyBuilder) could help you.

 

 <_edgeslistname>{}.fme_arc_id

The ID of the edge connected to this node. The magnitude of the ID corresponds to the _edge_id of the connected edge. If the ID is positive, the start of the edge is connected to the node. If the ID is negative, the end of the edge is connected to the node.

fig-in-help


Thank you @Takashi Iijima​ ! It seems like a start node has _edge{0}.fme_arc_id value = 1 while an end point has value = -1. Is that correct? If so, what transformer do you recommend using to filter out the _node_number(s) from the list that have an _edge{0}.fme_arc_id value = 1 or -1?

Oh, the arrow head of the red line in the figure seems to indicate reverse direction of flow. Could you please check this? @mark2atsafe​ 


Maybe run my Node Valence transformer I have posted on FME Hub? This does the calculations and adds points at the nodes with a valence (count). If the valence is 1 it is a dangle, 2 a pseudonode, 3+ a real node.

You also need to segment direction, so the fnode and tnode attributes will tell you if it is a start or end node. Of course any node can be either for different connecting segments. I use this to make sure every manhole on a gravity network has an exit. You can also check all pipes run into the sea or lake and that all dangles are either a source or sink. Great for QA of a network before you do any analysis.

 


Maybe run my Node Valence transformer I have posted on FME Hub? This does the calculations and adds points at the nodes with a valence (count). If the valence is 1 it is a dangle, 2 a pseudonode, 3+ a real node.

You also need to segment direction, so the fnode and tnode attributes will tell you if it is a start or end node. Of course any node can be either for different connecting segments. I use this to make sure every manhole on a gravity network has an exit. You can also check all pipes run into the sea or lake and that all dangles are either a source or sink. Great for QA of a network before you do any analysis.

 

Thank you @Takashi Iijima​  and @kimo​. I have reached my goal to eliminate intersection points and keep end points. I did not have to use these tricks and was able to just change the TopologyBuilder transformer settings to accomplish it in my case. Thanks again.


Reply