Relative Content

Tag Archive for networkxgraph-theorydepth-first-search

Algorithm to orientate edges in NetworkX

I have a tree that has three types of vertices: [red, blue and grey]. There can be multiple of each kind. However, rooting a spanning tree on any grey vertex, red and blue vertices will ALWAYS be leaf vertices.