IPSDK  4_1_0_2
IPSDK : Image Processing Software Development Kit

algorithm allowing to extract dilated local extrema 3d from an image More...

IPSDKIPLADVANCEDMORPHOLOGY_API image::ImagePtr ipsdk::imaproc::advmorpho::dilateLocalMaxima3dImg (const image::ImageConstPtr &pInImg3d, const ipReal32 inDilateFactor)
 wrapper function for algorithm allowing to extract dilated local maxima 3d from an image More...
 
IPSDKIPLADVANCEDMORPHOLOGY_API void ipsdk::imaproc::advmorpho::dilateLocalMaxima3dImg (const image::ImageConstPtr &pInImg3d, const ipReal32 inDilateFactor, const image::ImagePtr &pOutBinImg)
 wrapper function for algorithm allowing to extract dilated local maxima 3d from an image More...
 
IPSDKIPLADVANCEDMORPHOLOGY_API image::ImagePtr ipsdk::imaproc::advmorpho::dilateLocalMinima3dImg (const image::ImageConstPtr &pInImg3d, const ipReal32 inDilateFactor)
 wrapper function for algorithm allowing to extract dilated local minima 3d from an image More...
 
IPSDKIPLADVANCEDMORPHOLOGY_API void ipsdk::imaproc::advmorpho::dilateLocalMinima3dImg (const image::ImageConstPtr &pInImg3d, const ipReal32 inDilateFactor, const image::ImagePtr &pOutBinImg)
 wrapper function for algorithm allowing to extract dilated local minima 3d from an image More...
 

Detailed Description

algorithm allowing to extract dilated local extrema 3d from an image

This algorithm allows, given an input image InImg3d, a dilation factor InDilateFactor and a searched extrema type defined by InLocalExtremumType parameter, to compute a binary ouput image OutBinImg where all set pixels are part of a dilated local extrema.

Note
This algorithm is an extension of Local Extrema 3d algorithm allowing to dilate (and in some case merge) local extrema. Using this algorithm with a value of InDilateFactor set to 0 is equivalent of using Local Extrema 3d algorithm.
Dilation factor InDilateFactor is a grey scale factor (not a geometric factor) since local extrema are dilated with a distance based on grey scale difference.

Output image is computed has follow (local maxima case) :

\[ OutBinImg[i] = \left\{ \begin{matrix} 1 & if & InImg3d[i] >= InImg3d[E_i] - InDilateFactor \\ 0 & otherwise \end{matrix} \right. \]

where pixel with index $E_i$ is :

This is illustrated in case of a 1d signal :

dilateLocalExtremaGraph.png

Examples of dilated local maxima extraction are illustrated in 2d case : see Dilate Local Extrema 2d.

Attributes description

Attribute description for algorithm :

Name ToolTip Default Initializer
ipsdk::imaproc::attr::InImg3d [Input] 3d image for operation X
ipsdk::imaproc::attr::InDilateFactor [Input] factor used for dilation X
ipsdk::imaproc::attr::InLocalExtremumType [Input] local extremum type X
ipsdk::imaproc::attr::OutOptWk1Img [Output Optional] Temporary working image for algorithm X
ipsdk::imaproc::attr::OutBinImg [Output] binary image for processing operation duplicateInOut (_pOutBinImg, _pInImg3d, ipsdk::image::eImageBufferType::eIBT_Binary)

Global Rule description

Global rule description for algorithm :
(ipsdk::imaproc::matchSize (_pInImg3d,_pOutBinImg) && 
 ipsdk::processor::ifIsSet (_pOutOptWk1Img,
  ipsdk::imaproc::matchSizeAndType (_pInImg3d,_pOutOptWk1Img)))

Example of Python code :

Example imports

import PyIPSDK
import PyIPSDK.IPSDKIPLAdvancedMorphology as advmorpho

Code Example

# opening of input image
inImg = PyIPSDK.loadTiffImageFile(inputImgPath)
# dilate local maxima 3d computation
outImg = advmorpho.dilateLocalMaxima3dImg(inImg, 5)

Example of C++ code :

Example informations

Associated library

IPSDKIPLAdvancedMorphology

Header file

Code Example

// opening of input image
ImagePtr pInImg = loadTiffImageFile(inputImgPath);
// mark local maxima in input image
ImagePtr pOutMaxImg = dilateLocalMaxima3dImg(pInImg, 5);
// mark local minima in input image
ImagePtr pOutMinImg = dilateLocalMinima3dImg(pInImg, 5);
See also
DilateLocalExtrema3dImgLvl1

Function Documentation

◆ dilateLocalMaxima3dImg() [1/2]

IPSDKIPLADVANCEDMORPHOLOGY_API image::ImagePtr ipsdk::imaproc::advmorpho::dilateLocalMaxima3dImg ( const image::ImageConstPtr pInImg3d,
const ipReal32  inDilateFactor 
)

wrapper function for algorithm allowing to extract dilated local maxima 3d from an image

Exceptions
ipsdk::processor::IPSDKBaseProcessingExceptionon failure

◆ dilateLocalMinima3dImg() [1/2]

IPSDKIPLADVANCEDMORPHOLOGY_API image::ImagePtr ipsdk::imaproc::advmorpho::dilateLocalMinima3dImg ( const image::ImageConstPtr pInImg3d,
const ipReal32  inDilateFactor 
)

wrapper function for algorithm allowing to extract dilated local minima 3d from an image

Exceptions
ipsdk::processor::IPSDKBaseProcessingExceptionon failure

◆ dilateLocalMaxima3dImg() [2/2]

IPSDKIPLADVANCEDMORPHOLOGY_API void ipsdk::imaproc::advmorpho::dilateLocalMaxima3dImg ( const image::ImageConstPtr pInImg3d,
const ipReal32  inDilateFactor,
const image::ImagePtr pOutBinImg 
)

wrapper function for algorithm allowing to extract dilated local maxima 3d from an image

Exceptions
ipsdk::processor::IPSDKBaseProcessingExceptionon failure

◆ dilateLocalMinima3dImg() [2/2]

IPSDKIPLADVANCEDMORPHOLOGY_API void ipsdk::imaproc::advmorpho::dilateLocalMinima3dImg ( const image::ImageConstPtr pInImg3d,
const ipReal32  inDilateFactor,
const image::ImagePtr pOutBinImg 
)

wrapper function for algorithm allowing to extract dilated local minima 3d from an image

Exceptions
ipsdk::processor::IPSDKBaseProcessingExceptionon failure