msmbuilder.tpt.Dijkstra

msmbuilder.tpt.Dijkstra(sources, sinks, net_flux)[source]

A modified Dijkstra algorithm that dynamically computes the cost of all paths from A to B, weighted by NFlux.

Parameters:

sources : array_like, int

The indices of the source states (i.e. for state A in rxn A -> B)

sinks : array_like, int

Indices of sink states (state B)

NFlux : sparse matrix

Matrix of the net flux from A to B, see function GetFlux

Returns:

pi : array_like

The paths from A->B, pi[i] = node preceeding i

b : array_like

The flux passing through each node

See also

DijkstraTopPaths
child function DijkstraTopPaths is probably the function you want to call to find paths through an MSM network. This is a utility function called by DijkstraTopPaths, but may be useful in some specific cases