Function reformat_coronal
Source pub fn reformat_coronal(
volume: &ArrayBase<OwnedRepr<f64>, Dim<[usize; 3]>>,
slice_idx: usize,
) -> Result<ArrayBase<OwnedRepr<f64>, Dim<[usize; 2]>>, NdimageError>
Expand description
Extract a coronal (constant-y) slice from a 3D volume.
Returns a 2D array of shape (depth, width).
§Arguments
volume – 3D array (depth, height, width).
slice_idx – Height index to extract (0 ≤ slice_idx < height).
§Errors
Returns NdimageError::InvalidInput when slice_idx is out of range.