IPSDK 0.2
IPSDK : Image Processing Software Development Kit
Check multiphased 3d neighourhoodSee full documentation
imagecheckMultiphasedNeighourhood3dImg (inLabelImg,nbLabels,bIgnoreForeground)

Detailed Description

Set the intensity to 1 if the number of neighbours with higher values are greater than the specified input value.

Given an iput label image, the algorithm computes a binary image in which pixels are set to 1 if the label image counts at least InNbLabels different labels in its 3x3x3 neighbourhood.

It is possible to process only background pixels by setting the InIgnoreForeground flag to true.

A 2D example is given in the Check multiphased 2d neighourhood description.

Example of Python code :

Example imports

import PyIPSDK
import PyIPSDK.IPSDKIPLBasicMorphology as morpho

Code Example

# opening of input image
inImg = PyIPSDK.loadTiffImageFile(inputImgPath)
# boundary 3d image computation
outImg = morpho.checkMultiphasedNeighourhood3dImg(inImg, 3, True)

Example of C++ code :

Example informations

Header file

#include <IPSDKIPL/IPSDKIPLBasicMorphology/Processor/CheckMultiphasedNeighourhood3dImg/CheckMultiphasedNeighourhood3dImg.h>

Code Example

// opening input image
ImagePtr pInLabelImg = loadTiffImageFile(inputImgPath);
// compute boundary on input image
ImagePtr pOutImg = checkMultiphasedNeighourhood3dImg(pInLabelImg, 3, bIgnoreForeground);