networkx.dfs_preorder
networkx.dfs_predecessor
Return list of nodes connected to source in depth-first-search postorder.
Traverse the graph G with depth-first-search from source. Non-recursive algorithm.