IPSDK  4_1_0_2
IPSDK : Image Processing Software Development Kit

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

IPSDKIPLADVANCEDMORPHOLOGY_API image::ImagePtr ipsdk::imaproc::advmorpho::localMaxima2dImg (const image::ImageConstPtr &pInImg)
 wrapper function for algorithm allowing to extract local maxima 2d from an image More...
 
IPSDKIPLADVANCEDMORPHOLOGY_API void ipsdk::imaproc::advmorpho::localMaxima2dImg (const image::ImageConstPtr &pInImg, const image::ImagePtr &pOutBinImg)
 wrapper function for algorithm allowing to extract local maxima 2d from an image More...
 
IPSDKIPLADVANCEDMORPHOLOGY_API image::ImagePtr ipsdk::imaproc::advmorpho::localMinima2dImg (const image::ImageConstPtr &pInImg)
 wrapper function for algorithm allowing to extract local minima 2d from an image More...
 
IPSDKIPLADVANCEDMORPHOLOGY_API void ipsdk::imaproc::advmorpho::localMinima2dImg (const image::ImageConstPtr &pInImg, const image::ImagePtr &pOutBinImg)
 wrapper function for algorithm allowing to extract local minima 2d from an image More...
 

Detailed Description

algorithm allowing to extract local extrema 2d from an image

This algorithm allows, given an input image InImg and a searched extrema type defined by InLocalExtremumType parameter, to compute a binary ouput image OutBinImg where all set pixels are local extrema.

This means that if a pixel is set in output image, all neighbor value respect one of following condition :

This is illustrated in case of a 1d signal :

localExtremaGraph.png

Here is an example of a local maxima extraction applied to an unsigned char input image :

localExtrema2dImg.png

Attributes description

Attribute description for algorithm :

Name ToolTip Default Initializer
ipsdk::imaproc::attr::InImg [Input] image for processing operation X
ipsdk::imaproc::attr::InLocalExtremumType [Input] local extremum type X
ipsdk::imaproc::attr::OutBinImg [Output] binary image for processing operation duplicateInOut (_pOutBinImg, _pInImg, ipsdk::image::eImageBufferType::eIBT_Binary)

Global Rule description

Global rule description for algorithm :
ipsdk::imaproc::matchSize (_pInImg,_pOutBinImg) && 
ipsdk::imaproc::noInSitu (_pInImg,_pOutBinImg)

Example of Python code :

Example imports

import PyIPSDK
import PyIPSDK.IPSDKIPLAdvancedMorphology as advmorpho

Code Example

# opening of input image
inImg = PyIPSDK.loadTiffImageFile(inputImgPath)
# local maxima 2d computation
outImg = advmorpho.localMaxima2dImg(inImg)

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 = localMaxima2dImg(pInImg);
// mark local minima in input image
ImagePtr pOutMinImg = localMinima2dImg(pInImg);
See also
LocalExtrema2dImgLvl1
LocalExtrema2dImgLvl2
LocalExtrema2dImgLvl3

Function Documentation

◆ localMaxima2dImg() [1/2]

IPSDKIPLADVANCEDMORPHOLOGY_API image::ImagePtr ipsdk::imaproc::advmorpho::localMaxima2dImg ( const image::ImageConstPtr pInImg)

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

Exceptions
ipsdk::processor::IPSDKBaseProcessingExceptionon failure

◆ localMinima2dImg() [1/2]

IPSDKIPLADVANCEDMORPHOLOGY_API image::ImagePtr ipsdk::imaproc::advmorpho::localMinima2dImg ( const image::ImageConstPtr pInImg)

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

Exceptions
ipsdk::processor::IPSDKBaseProcessingExceptionon failure

◆ localMaxima2dImg() [2/2]

IPSDKIPLADVANCEDMORPHOLOGY_API void ipsdk::imaproc::advmorpho::localMaxima2dImg ( const image::ImageConstPtr pInImg,
const image::ImagePtr pOutBinImg 
)

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

Exceptions
ipsdk::processor::IPSDKBaseProcessingExceptionon failure

◆ localMinima2dImg() [2/2]

IPSDKIPLADVANCEDMORPHOLOGY_API void ipsdk::imaproc::advmorpho::localMinima2dImg ( const image::ImageConstPtr pInImg,
const image::ImagePtr pOutBinImg 
)

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

Exceptions
ipsdk::processor::IPSDKBaseProcessingExceptionon failure