Skip to main content

Module traversal

Module traversal 

Source
Expand description

Graph traversal. Phase 0 ships BFS; ALGO-TR-002 adds DFS; ALGO-TR-001 adds the multi-output BFS variant bfs_tree.

Structs§

BfsSimple
Result of bfs_simple.
BfsTree
Result of a multi-output BFS scan from a single root. Returned by bfs_tree.
DfsSimple
Result of dfs_simple.
DfsTree
Result of a multi-output DFS scan from a single root. Returned by dfs_tree.
NeighborSampleResult
Result of k-hop neighborhood sampling.

Enums§

BfsMode
Direction mode for bfs_simple.
DfsMode
Direction mode for dfs_simple.

Functions§

bfs
Visit order of vertices reachable from root, in BFS order.
bfs_simple
Mode-aware BFS from a single root, returning visit order, layer boundaries, and BFS-tree parents.
bfs_tree
Multi-output BFS from root. Returns visit order, per-vertex distances, and per-vertex BFS-tree parent in a single pass.
dfs
Pre-order visit of vertices reachable from root, in DFS order.
dfs_simple
Mode-aware DFS from a single root, returning pre/post-order, parents, and DFS-tree depth.
dfs_tree
Multi-output DFS from root. Returns visit order (pre and post), per-vertex parents, and DFS-tree depth in a single pass.
neighbor_sample
Sample k-hop neighborhoods around seed vertices.
neighbor_sample_weighted
Sample k-hop neighborhoods with importance-weighted sampling.