R/extendr-wrappers.R
graph_smooth_rust.RdThe pixel neighborhood graph is reconstructed in
Rust with petgraph from width/height/neighbors (no adjacency
matrix crosses the FFI boundary), the combinatorial Laplacian
L = D - W is assembled directly in CSC form, and the linear system
(I + alpha * L) x = b is solved band-by-band with an iterative
Krylov solver: Conjugate Gradient ("cg", the default – the
operator is symmetric positive-definite) or BiCGSTAB ("bicgstab").
graph_smooth_rust(data, width, height, alpha, neighbors, solver)