pub fn wl_hash_iterations(
graph: &Graph,
labels: Option<&[u32]>,
max_iterations: u32,
) -> IgraphResult<Vec<WlHashResult>>Expand description
Compute WL hashes at each iteration level (subtree patterns of depth 0..k).
Returns a vector of WlHashResult for iterations 0 through
max_iterations (or until stabilization). This is useful for
WL subtree kernel computation where you need hashes at every depth.
ยงExamples
use rust_igraph::{Graph, wl_hash_iterations};
let g = Graph::from_edges(&[(0,1),(1,2),(2,3),(3,0)], false, Some(4)).unwrap();
let iters = wl_hash_iterations(&g, None, 3).unwrap();
assert!(!iters.is_empty());
assert!(iters.len() <= 4); // initial + up to 3 iterations