medpy.features.intensity.shifted_mean_gauss#

medpy.features.intensity.shifted_mean_gauss(image, offset=None, sigma=5, voxelspacing=None, mask=slice(None, None, None))[source]#

The approximate mean over a small region at an offset from each voxel.

Functions like local_mean_gauss, but instead of computing the average over a small patch around the current voxel, the region is centered at an offset away. Can be used to use a distant regions average as feature for a voxel.

Parameters:
imagearray_like or list/tuple of array_like

A single image or a list/tuple of images (for multi-spectral case).

offsetsequence of ints

At this offset in voxels of the current position the region is placed.

sigmanumber or sequence of numbers

Standard deviation for Gaussian kernel. The standard deviations of the Gaussian filter are given for each axis as a sequence, or as a single number, in which case it is equal for all axes. Note that the voxel spacing of the image is taken into account, the given values are treated as mm.

voxelspacingsequence of floats

The side-length of each voxel.

maskarray_like

A binary mask for the image.

Returns:
shifted_mean_gaussndarray

The weighted mean intensities over a region at offset away from each voxel.

See also

local_mean_gauss