isotropic_diffusionisotropic_diffusionIsotropicDiffusionIsotropicDiffusionisotropic_diffusion (Operator)

Name

isotropic_diffusionisotropic_diffusionIsotropicDiffusionIsotropicDiffusionisotropic_diffusion — Perform an isotropic diffusion of an image.

Signature

isotropic_diffusion(Image : SmoothedImage : Sigma, Iterations : )

Herror isotropic_diffusion(const Hobject Image, Hobject* SmoothedImage, double Sigma, const Hlong Iterations)

Herror T_isotropic_diffusion(const Hobject Image, Hobject* SmoothedImage, const Htuple Sigma, const Htuple Iterations)

void IsotropicDiffusion(const HObject& Image, HObject* SmoothedImage, const HTuple& Sigma, const HTuple& Iterations)

HImage HImage::IsotropicDiffusion(double Sigma, Hlong Iterations) const

static void HOperatorSet.IsotropicDiffusion(HObject image, out HObject smoothedImage, HTuple sigma, HTuple iterations)

HImage HImage.IsotropicDiffusion(double sigma, int iterations)

def isotropic_diffusion(image: HObject, sigma: float, iterations: int) -> HObject

Description

The operator isotropic_diffusionisotropic_diffusionIsotropicDiffusionIsotropicDiffusionIsotropicDiffusionisotropic_diffusion performs an isotropic diffusion of the input image ImageImageImageImageimageimage. This corresponds to a convolution of the image matrix with a Gaussian mask of standard deviation SigmaSigmaSigmaSigmasigmasigma. If the parameter IterationsIterationsIterationsIterationsiterationsiterations is set to 0, such a convolution is performed explicitly. For input images with a full ROI, isotropic_diffusionisotropic_diffusionIsotropicDiffusionIsotropicDiffusionIsotropicDiffusionisotropic_diffusion returns the same results as the operator derivate_gaussderivate_gaussDerivateGaussDerivateGaussDerivateGaussderivate_gauss when choosing 'none'"none""none""none""none""none" for its parameter ComponentComponentComponentComponentcomponentcomponent. If the gray value matrix is larger than the ROI of ImageImageImageImageimageimage the two operators differ since derivate_gaussderivate_gaussDerivateGaussDerivateGaussDerivateGaussderivate_gauss takes the gray values outside of the ROI into account, while isotropic_diffusionisotropic_diffusionIsotropicDiffusionIsotropicDiffusionIsotropicDiffusionisotropic_diffusion mirrors the values at the boundary of the ROI in any case. The computational complexity increases linearly with the value of SigmaSigmaSigmaSigmasigmasigma.

If IterationsIterationsIterationsIterationsiterationsiterations has a positive value the smoothing process is considered as an application of the heat equation on the gray value function u with the initial value defined by the gray values of ImageImageImageImageimageimage at a time . This equation is then solved up to a time , which is equivalent to the above convolution, using an iterative procedure for parabolic partial differential equations. The computational complexity is proportional to the value of IterationsIterationsIterationsIterationsiterationsiterations and independent of SigmaSigmaSigmaSigmasigmasigma in this case. For small values of IterationsIterationsIterationsIterationsiterationsiterations, the computational accuracy is very low, however. For this reason, choosing IterationsIterationsIterationsIterationsiterationsiterations < 3 is not recommended.

For smaller values of SigmaSigmaSigmaSigmasigmasigma, the convolution implementation is typically the faster method. Since the runtime of the partial differential equation solver only depends on the number of iterations and not on the value of SigmaSigmaSigmaSigmasigmasigma, it is typically faster for large values of SigmaSigmaSigmaSigmasigmasigma if few iterations are chosen (e.g., IterationsIterationsIterationsIterationsiterationsiterations = 3).

For an explanation of the concept of smoothing filters see the introduction of chapter Filters / Smoothing.

Attention

Note that filter operators may return unexpected results if an image with a reduced domain is used as input. Please refer to the chapter Filters.

Execution Information

Parameters

ImageImageImageImageimageimage (input_object)  (multichannel-)image(-array) objectHImageHObjectHImageHobject (byte / uint2 / real)

Input image.

SmoothedImageSmoothedImageSmoothedImageSmoothedImagesmoothedImagesmoothed_image (output_object)  image(-array) objectHImageHObjectHImageHobject * (byte / uint2 / real)

Output image.

SigmaSigmaSigmaSigmasigmasigma (input_control)  real HTuplefloatHTupleHtuple (real) (double) (double) (double)

Standard deviation of the Gauss distribution.

Default value: 1.0

Suggested values: 0.1, 0.5, 1.0, 3.0, 10.0, 20.0, 50.0

Restriction: Sigma > 0

IterationsIterationsIterationsIterationsiterationsiterations (input_control)  integer HTupleintHTupleHtuple (integer) (int / long) (Hlong) (Hlong)

Number of iterations.

Default value: 10

Suggested values: 0, 3, 10, 100, 500

Restriction: Iterations >= 0

Module

Foundation