fn tv_objective(
x: &[f64],
mu: f64,
masks: &HomogeneityMasks,
grid: &Grid,
ws: &mut TvWorkspace,
df: &mut [f64],
) -> f64Expand description
Smoothed weighted-TV objective and its gradient.
Returns f_μ(x) and writes ∇f_μ(x) into df. Two passes over the volume,
each parallel over z-slabs: the first builds the masked gradients and the
smoothing weight w, the second applies the adjoint differences.