PANDORE Version 6 GREYC-IMAGE

phistothresholding



Performs multi-thresholding on image using histogram analysis.



Synopsis

phistothresholding length [im_in|-] [im_out|-]

Description

phistothresholding classifies the input image pixels into a small number of clusters according to their value. Every pixel p of the input image is assigned to a cluster identified by the related threshold value:

   if threshold[k-1]<im_out[p]<=threshold[k].
   then im_out[p]=threshold[k]

The last threshold is equal to 255.

The number of clusters and the value of the thresholds are determined from the histogram. Thresholds are located as regional maxima of the histogram. The maxima are searched in the space of length gray levels around the gray level i.

Notice: This operator can only work on grayscale image of bytes.

Parameters

Inputs

Outputs

Result

Returns the number of thresholds.

Examples

Segments the tangram pieces:

   phistothresholding 10 tangram.pan out.pan

See also

Thresholding

C++ prototype

Errc PHistoThresholding( const Img2duc &im_in, Img2dsl &im_out, int length );

Version française

Multi-seuillage d'une image de niveaux de gris par une ligne de partage des eaux de son histogramme.


Author: Olivier Lezoray