Hello Tiago,
Thank you for your advice. I built the graph as follow:
*weight = graph.new_edge_property("double")
eprops = [weight]
graph.add_edge_list(connections, hashed = True, string_vals = True, eprops =
eprops)*
After building the graph, I would like to execute shortest_distance() from a
source node to a target node:
*dist = shortest_distance(graph, source = 'start', target = 'end', weights =
weight)*
Seems like I need to use vertex indices of the 'start' and 'end' nodes for
input source and target, respectively.
How can I find vertex indices using vertex values (strings)? Is this finding
in O(1) time complexity?
Thanks!
--
Sent from:
http://main-discussion-list-for-the-graph-tool-project.982480.n3.nabble.com/
_______________________________________________
graph-tool mailing list
[email protected]
https://lists.skewed.de/mailman/listinfo/graph-tool