Skip to main content

Module convolution3d

Module convolution3d 

Source
Expand description

3D Convolution and Volumetric Filtering

This module provides 3D convolution and cross-correlation, separable Gaussian filtering, box filtering, non-separable median filtering, and Laplacian-of-Gaussian (LoG) blob detection for volumetric (Array3<f64>) data.

§Border / Padding Modes

Three padding strategies are available via Padding3D:

VariantBehaviour at the boundary
ZeroOut-of-bounds indices map to 0.0
ReflectMirror reflection around the edge voxel
ReplicateClamp-to-edge (nearest-neighbour extrapolation)

§Separable Filter Optimization

Filters that are separable (Gaussian, uniform/box) are implemented as three successive 1D convolutions along z, y, and x. This reduces the per-voxel work from O(k³) to O(3k) where k is the 1D kernel half-width.

Enums§

Padding3D
Padding strategy for 3D convolution / filtering operations.

Functions§

convolve3d
3D discrete convolution.
correlate3d
3D cross-correlation.
gaussian_filter3d
3D separable Gaussian filter with per-axis sigma values.
laplacian_of_gaussian3d
3D Laplacian of Gaussian (LoG) filter for blob detection.
median_filter3d
3D median filter with a rectangular window.
uniform_filter3d
3D separable uniform (box) filter with per-axis window sizes.