ClosingBallByReconstruction3d
Performs a three-dimensional closing by reconstruction with a structuring element matching with a cube.
Access to parameter description
A closing by reconstruction consists in applying a dilation followed by a morphological reconstruction. In the binary case, closing by reconstruction can be used for filling small holes without modifying edges of the large ones. In the grayscale case, opening by reconstruction can be used for performing a Top Hat by reconstruction for detecting dark small structures without getting artifacts from the boundary concavities of large structures.
Its 2D grayscale behavior is illustrated in the ClosingByReconstruction2d documentation (Figure 1).
See also
Access to parameter description
A closing by reconstruction consists in applying a dilation followed by a morphological reconstruction. In the binary case, closing by reconstruction can be used for filling small holes without modifying edges of the large ones. In the grayscale case, opening by reconstruction can be used for performing a Top Hat by reconstruction for detecting dark small structures without getting artifacts from the boundary concavities of large structures.
Its 2D grayscale behavior is illustrated in the ClosingByReconstruction2d documentation (Figure 1).
See also
Function Syntax
This function returns outputImage.
// Function prototype
std::shared_ptr< iolink::ImageView > closingBallByReconstruction3d( std::shared_ptr< iolink::ImageView > inputImage, uint32_t kernelRadius, ClosingBallByReconstruction3d::Precision precision, std::shared_ptr< iolink::ImageView > outputImage = nullptr );
This function returns outputImage.
// Function prototype. closing_ball_by_reconstruction_3d(input_image: idt.ImageType, kernel_radius: int = 3, precision: ClosingBallByReconstruction3d.Precision = ClosingBallByReconstruction3d.Precision.FASTER, output_image: idt.ImageType = None) -> idt.ImageType
This function returns outputImage.
// Function prototype. public static IOLink.ImageView ClosingBallByReconstruction3d( IOLink.ImageView inputImage, UInt32 kernelRadius = 3, ClosingBallByReconstruction3d.Precision precision = ImageDev.ClosingBallByReconstruction3d.Precision.FASTER, IOLink.ImageView outputImage = null );
Class Syntax
Parameters
Parameter Name | Description | Type | Supported Values | Default Value | |||||
---|---|---|---|---|---|---|---|---|---|
inputImage |
The input image. | Image | Binary, Label or Grayscale | nullptr | |||||
kernelRadius |
The length of the sphere radius in voxels. | UInt32 | >=1 | 3 | |||||
precision |
The precision of the computation method.
|
Enumeration | FASTER | ||||||
outputImage |
The output image. Its dimensions and type are forced to the same values as the input image. | Image | nullptr |
Parameter Name | Description | Type | Supported Values | Default Value | |||||
---|---|---|---|---|---|---|---|---|---|
input_image |
The input image. | image | Binary, Label or Grayscale | None | |||||
kernel_radius |
The length of the sphere radius in voxels. | uint32 | >=1 | 3 | |||||
precision |
The precision of the computation method.
|
enumeration | FASTER | ||||||
output_image |
The output image. Its dimensions and type are forced to the same values as the input image. | image | None |
Parameter Name | Description | Type | Supported Values | Default Value | |||||
---|---|---|---|---|---|---|---|---|---|
inputImage |
The input image. | Image | Binary, Label or Grayscale | null | |||||
kernelRadius |
The length of the sphere radius in voxels. | UInt32 | >=1 | 3 | |||||
precision |
The precision of the computation method.
|
Enumeration | FASTER | ||||||
outputImage |
The output image. Its dimensions and type are forced to the same values as the input image. | Image | null |
Object Examples
auto foam = readVipImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "foam.vip" ); ClosingBallByReconstruction3d closingBallByReconstruction3dAlgo; closingBallByReconstruction3dAlgo.setInputImage( foam ); closingBallByReconstruction3dAlgo.setKernelRadius( 3 ); closingBallByReconstruction3dAlgo.setPrecision( ClosingBallByReconstruction3d::Precision::FASTER ); closingBallByReconstruction3dAlgo.execute(); std::cout << "outputImage:" << closingBallByReconstruction3dAlgo.outputImage()->toString();
foam = imagedev.read_vip_image(imagedev_data.get_image_path("foam.vip")) closing_ball_by_reconstruction_3d_algo = imagedev.ClosingBallByReconstruction3d() closing_ball_by_reconstruction_3d_algo.input_image = foam closing_ball_by_reconstruction_3d_algo.kernel_radius = 3 closing_ball_by_reconstruction_3d_algo.precision = imagedev.ClosingBallByReconstruction3d.FASTER closing_ball_by_reconstruction_3d_algo.execute() print("output_image:", str(closing_ball_by_reconstruction_3d_algo.output_image))
ImageView foam = Data.ReadVipImage( @"Data/images/foam.vip" ); ClosingBallByReconstruction3d closingBallByReconstruction3dAlgo = new ClosingBallByReconstruction3d { inputImage = foam, kernelRadius = 3, precision = ClosingBallByReconstruction3d.Precision.FASTER }; closingBallByReconstruction3dAlgo.Execute(); Console.WriteLine( "outputImage:" + closingBallByReconstruction3dAlgo.outputImage.ToString() );
Function Examples
auto foam = readVipImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "foam.vip" ); auto result = closingBallByReconstruction3d( foam, 3, ClosingBallByReconstruction3d::Precision::FASTER ); std::cout << "outputImage:" << result->toString();
foam = imagedev.read_vip_image(imagedev_data.get_image_path("foam.vip")) result = imagedev.closing_ball_by_reconstruction_3d(foam, 3, imagedev.ClosingBallByReconstruction3d.FASTER) print("output_image:", str(result))
ImageView foam = Data.ReadVipImage( @"Data/images/foam.vip" ); IOLink.ImageView result = Processing.ClosingBallByReconstruction3d( foam, 3, ClosingBallByReconstruction3d.Precision.FASTER ); Console.WriteLine( "outputImage:" + result.ToString() );