pub fn spfa_filtered<G, F>(
graph: &G,
source: G::Node,
edge_cost: F,
) -> Result<Option<BellmanFord<G::Node>>>Expand description
Computes SPFA while omitting edges whose cost is None.
ยงErrors
Returns an error for arithmetic overflow or a reachable negative cycle.