Open gdalle opened 2 years ago
What about returning a named tuple instead of a custom struct?
The problem is that not all shortest path algorithms are created equal. While Dijkstra can fill a correct shortest path tree, A* only finds the shortest s-d path with no guarantee on the vertices explored in between
However, normalizing the A* output could help solve #59
In a future version, I think A* should return a vector of nodes instead of edges. And we could add methods for Dijkstra & Co which, when called with a source and and destination, would also return a vector of nodes
At the moment,
a_star
returns a list of edges, whiledijkstra_shortest_paths
returns a custom state object. Would it make sense to have homogeneous outputs, at least for the single-source case?