sid8491
sid8491

Reputation: 6800

Python: Networkx get path between given two nodes with nodes and edges

Is there any function to get the list of all paths which will consist of nodes and the edges between any two given nodes from a graph?

Functions like dijkstra_path() and shortest_path() etc return only nodes.

Upvotes: 2

Views: 541

Answers (1)

Keyb0ardwarri0r
Keyb0ardwarri0r

Reputation: 237

I think you're looking for the get_edge_data() function. Check the page for examples how to use it.

Upvotes: 2

Related Questions