transbigdata.get_k_shortest_paths
- transbigdata.get_k_shortest_paths(G, stop, ostation, dstation, k)
Obtain the k th shortest paths from the metro nextwork
- Parameters:
G (networkx.classes.graph.Graph) – metro network
stop (DataFrame) – metro stop dataframe
ostation (str) – O station name
dstation (str) – D station name
k (int) – the k th shortest paths
- Returns:
paths – travel path: list of travel paths
- Return type:
list