Skip to main content
Question

Assign incremental ID to a network based on connectivity

  • June 14, 2020
  • 5 replies
  • 6 views

chandan

Hello,

I have two layer of networks, one is base (red line) and another is candidate (black lines). Want to populate ID in candidate layer as per connectivity with base. All first intersect of candidate layer should get ID 1 then remaining lines should follow the order. Any help? Thanks in advance.

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

5 replies

danilo_fme
Celebrity
Forum|alt.badge.img+51
  • Celebrity
  • 2077 replies
  • June 14, 2020

Hi @chandan

Your case is similar with this interesting Link

As you can see, the transformer StreamOrderCalculator is responsible to do this calculator.

 

Thanks,

Danilo

 


chandan
  • Author
  • 8 replies
  • June 16, 2020

Hi @chandan

Your case is similar with this interesting Link

As you can see, the transformer StreamOrderCalculator is responsible to do this calculator.

 

Thanks,

Danilo

 

Hi @danilo_fme,

Thanks, I tried with StreamOrderCalculator, but it was not giving output the way I'm expecting.


jdh
Contributor
Forum|alt.badge.img+37
  • Contributor
  • 2002 replies
  • June 16, 2020

Unfortunately neither the Horton nor the Strahler method for calcualting stream order is going to give you what you want, so the StreamOrderCalculator will not help.

 

 

What you are interested in is called Topological Stream Ordering. In FME, I would do this with a topologyBuilder and then in a PythonCaller calculate the stream order via a breadth first search (BFS).

 

As an aside, my FME UC 2020 presentation was going to be on graph theory (which includes topological sorting). Would you be willing to discuss your use case with me, I'm always looking for real life examples.


chandan
  • Author
  • 8 replies
  • July 11, 2020

Thanks @jdh, @danilo_fme for your suggestions.

Finally I solve this problem using ArcPy. Using SystemCaller to execute this standalone script.incremaental_id.py


danilo_fme
Celebrity
Forum|alt.badge.img+51
  • Celebrity
  • 2077 replies
  • July 11, 2020

Thanks @jdh, @danilo_fme for your suggestions.

Finally I solve this problem using ArcPy. Using SystemCaller to execute this standalone script.incremaental_id.py

Excellent news @chandan