Skip to main content

I’m looking to determine the number of line segments (green) to the end of a network branch (road network) from a given point in the network (red dot).

Ultimately, I want to do this to be able to determine if a network branch is a dead-end up to a certain threshold of number of road segments (i.e. 30 segments, but would not consider 5000 to be a dead-end...threshold to be determined)

I feel like using the StreamOrderCalculator to determine the Strahler Order is almost what I want except that loops may be present (as shown in teal) which removes that option.

I’ve tried various things with the Stream and Network transformers, but can’t seem to figure it out.

I’ve also tried with a PythonCaller, but I really struggle to translate a Python solution on dummy values to one that actually uses features and their geometry. I feel like I spend hours fiddling with syntax.

Any ideas would be greatly appreciated. Thanks.

Hi, @aaron_chaput.

Looking into your use-case scenario, I can suggest a transformer to start with that may help.

For determining (counting) the number of line segments, take a peek at the Intersector transformer. In short, this will determine line segments by comparing line features and splitting them in smaller segments when an intersection is found; afterwards, generating a list for those segments.

Hope this helps!


Hi Ali,

Thanks for your response.

The linework is already split between nodes so running the intersector produces no intersections as lines ending at the same point aren’t considered to be intersecting.

Any other suggestions?


Reply