graph_tool.topology.all_predecessors#
- graph_tool.topology.all_predecessors(g, dist_map, pred_map, weights=None, epsilon=1e-08)[source]#
Return a property map with all possible predecessors in the search tree determined by
dist_mapandpred_map.- Parameters:
- g
Graph Graph to be used.
- dist_map
VertexPropertyMap Vertex property map with the distances from
sourceto all other vertices.- pred_map
VertexPropertyMap Vertex property map with the predecessors in the search tree.
- weights
EdgePropertyMap(optional, default:None) The edge weights.
- epsilon
float(optional, default:1e-8) Maximum relative difference between distances to be considered “equal”, in case floating-point weights are used.
- g
- Returns:
- all_preds_map
VertexPropertyMap Vector-valued vertex property map with all possible predecessors in the search tree.
- all_preds_map