ImageDev

ImageLocalMaxima3d

Removes the non-local maxima from the gradient amplitude of a three-dimensional image.

Access to parameter description

For an introduction: For each voxel of a gradient image, gray level values within the neighborhood in the direction of the gradient are computed (given by X, Y, and Z gradients). If this value is greater than all of its neighbors it is kept, otherwise it is set to 0.

This algorithm eliminates some noise effects. It is very useful after having applied the GradientOperator3d algorithm.

The output edges are one pixel thickness edges. It is then possible to perform a HysteresisThresholding algorithm.

See also

Function Syntax

This function returns outputImage.
// Function prototype
std::shared_ptr< iolink::ImageView > imageLocalMaxima3d( std::shared_ptr< iolink::ImageView > inputImageX, std::shared_ptr< iolink::ImageView > inputImageY, std::shared_ptr< iolink::ImageView > inputImageZ, std::shared_ptr< iolink::ImageView > inputAmplitudeImage, std::shared_ptr< iolink::ImageView > outputImage = NULL );
This function returns outputImage.
// Function prototype.
image_local_maxima_3d( input_image_x,
                       input_image_y,
                       input_image_z,
                       input_amplitude_image,
                       output_image = None )
This function returns outputImage.
// Function prototype.
public static IOLink.ImageView
ImageLocalMaxima3d( IOLink.ImageView inputImageX,
                    IOLink.ImageView inputImageY,
                    IOLink.ImageView inputImageZ,
                    IOLink.ImageView inputAmplitudeImage,
                    IOLink.ImageView outputImage = null );

Class Syntax

Parameters

Parameter Name Description Type Supported Values Default Value
input
inputImageX
The X-gradient input image. Image Grayscale or Multispectral nullptr
input
inputImageY
The Y-gradient input image. Image Grayscale or Multispectral nullptr
input
inputImageZ
The Z-gradient input image. Image Grayscale or Multispectral nullptr
input
inputAmplitudeImage
The gradient amplitude input image. Image Binary, Label, Grayscale or Multispectral nullptr
output
outputImage
The output image. Image nullptr
Parameter Name Description Type Supported Values Default Value
input
input_image_x
The X-gradient input image. image Grayscale or Multispectral None
input
input_image_y
The Y-gradient input image. image Grayscale or Multispectral None
input
input_image_z
The Z-gradient input image. image Grayscale or Multispectral None
input
input_amplitude_image
The gradient amplitude input image. image Binary, Label, Grayscale or Multispectral None
output
output_image
The output image. image None
Parameter Name Description Type Supported Values Default Value
input
inputImageX
The X-gradient input image. Image Grayscale or Multispectral null
input
inputImageY
The Y-gradient input image. Image Grayscale or Multispectral null
input
inputImageZ
The Z-gradient input image. Image Grayscale or Multispectral null
input
inputAmplitudeImage
The gradient amplitude input image. Image Binary, Label, Grayscale or Multispectral null
output
outputImage
The output image. Image null

Object Examples

auto foam = readVipImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "foam.vip" );

ImageLocalMaxima3d imageLocalMaxima3dAlgo;
imageLocalMaxima3dAlgo.setInputImageX( foam );
imageLocalMaxima3dAlgo.setInputImageY( foam );
imageLocalMaxima3dAlgo.setInputImageZ( foam );
imageLocalMaxima3dAlgo.setInputAmplitudeImage( foam );
imageLocalMaxima3dAlgo.execute();

std::cout << "outputImage:" << imageLocalMaxima3dAlgo.outputImage()->toString();
foam = imagedev.read_vip_image(imagedev_data.get_image_path("foam.vip"))

image_local_maxima_3d_algo = imagedev.ImageLocalMaxima3d()
image_local_maxima_3d_algo.input_image_x = foam
image_local_maxima_3d_algo.input_image_y = foam
image_local_maxima_3d_algo.input_image_z = foam
image_local_maxima_3d_algo.input_amplitude_image = foam
image_local_maxima_3d_algo.execute()

print( "output_image:", str( image_local_maxima_3d_algo.output_image ) )
ImageView foam = Data.ReadVipImage( @"Data/images/foam.vip" );

ImageLocalMaxima3d imageLocalMaxima3dAlgo = new ImageLocalMaxima3d
{
    inputImageX = foam,
    inputImageY = foam,
    inputImageZ = foam,
    inputAmplitudeImage = foam
};
imageLocalMaxima3dAlgo.Execute();

Console.WriteLine( "outputImage:" + imageLocalMaxima3dAlgo.outputImage.ToString() );

Function Examples

auto foam = readVipImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "foam.vip" );

auto result = imageLocalMaxima3d( foam, foam, foam, foam );

std::cout << "outputImage:" << result->toString();
foam = imagedev.read_vip_image(imagedev_data.get_image_path("foam.vip"))

result = imagedev.image_local_maxima_3d( foam, foam, foam, foam )

print( "output_image:", str( result ) )
ImageView foam = Data.ReadVipImage( @"Data/images/foam.vip" );

IOLink.ImageView result = Processing.ImageLocalMaxima3d( foam, foam, foam, foam );

Console.WriteLine( "outputImage:" + result.ToString() );