Skip to main content

fansi

Function fansi 

Source
pub fn fansi(
    local_field: &[f64],
    mask: &[u8],
    grid: &Grid,
    bdir: (f64, f64, f64),
    params: &FansiParams,
    progress: impl FnMut(usize, usize),
) -> Vec<f64>
Expand description

FANSI nlTV/nlTGV dipole inversion.

§Arguments

  • local_field - Local field values (nx * ny * nz).
  • mask - Binary mask (nx * ny * nz), non-zero = inside ROI.
  • grid - Volume grid (dimensions and voxel sizes).
  • bdir - B0 field direction.
  • params - FANSI parameters (is_tgv selects nlTGV vs nlTV).
  • progress - Progress callback (iteration, max_iter).

§Returns

Estimated susceptibility map, masked to the ROI.