ash_model.paths.shortest_s_walk¶
- ash_model.paths.shortest_s_walk(h, s, fr=None, to=None, start=None, end=None, weight=False, edge=True)[source]¶
Compute shortest s-walk(s) considering weight or dual hypergraph.
If edge=True, operates on s-line-graph; otherwise uses dual hypergraph node graph.
- Parameters:
h (ASH) – ASH instance.
s (int) – Minimum overlap size.
fr (str | None) – Starting hyperedge ID (node or edge depending).
to (str | None) – Ending hyperedge ID.
start (int | None) – Start time bound.
end (int | None) – End time bound.
weight (bool) – Use edge weight attribute ‘w’ if True.
edge (bool) – If False, compute on dual hypergraph.
- Returns:
Single path list if both fr and to set, else dict mapping.
- Return type: