```{index} single: Filters; ITK Otsu Multiple Thresholds Image Filter ``` # ITK Otsu Multiple Thresholds Image Filter Threshold an image using multiple Otsu Thresholds. ## Group (Subgroup) ITKThresholding (Thresholding) ## Description This filter creates a labeled image that separates the input image into various classes. The filter computes the thresholds using the OtsuMultipleThresholdsCalculator and applies those thresholds to the input image using the ThresholdLabelerImageFilter . The NumberOfHistogramBins and NumberOfThresholds can be set for the Calculator. The LabelOffset can be set for the ThresholdLabelerImageFilter . This filter also includes an option to use the valley emphasis algorithm from H.F. Ng, "Automatic thresholding for defect detection", Pattern Recognition Letters, (27): 1644-1649, 2006. The valley emphasis algorithm is particularly effective when the object to be thresholded is small. See the following tests for examples: itkOtsuMultipleThresholdsImageFilterTest3 and itkOtsuMultipleThresholdsImageFilterTest4 To use this algorithm, simple call the setter: SetValleyEmphasis(true) It is turned off by default.* ScalarImageToHistogramGenerator - OtsuMultipleThresholdsCalculator - ThresholdLabelerImageFilter ![](Images/ITKOtsuThreshold.png) ### Input Parameter(s) | Parameter Name | Parameter Type | Parameter Notes | Description | |----------------|----------------|-----------------|-------------| | Number Of Thresholds | UInt8 | | Set/Get the number of thresholds. Default is 1. | | Label Offset | UInt8 | | Set/Get the offset which labels have to start from. Default is 0. | | Number Of Histogram Bins | Scalar Value |UInt32 | Set/Get the number of histogram bins. Default is 128. | | Valley Emphasis | Bool | | Set/Get the use of valley emphasis. Default is false. | | ReturnBinMidpoint | Bool | | Should the threshold value be mid-point of the bin or the maximum? Default is to return bin maximum. | ### Input Cell Data | Parameter Name | Parameter Type | Parameter Notes | Description | |----------------|----------------|-----------------|-------------| | Image Geometry | Geometry Selection | Image | Select the Image Geometry Group from the DataStructure. | | Input Cell Data | Array Selection | Allowed Types: int8, uint8, int16, uint16, int32, uint32, int64, uint64, float32, float64 | The image data that will be processed by this filter. | ### Output Cell Data | Parameter Name | Parameter Type | Parameter Notes | Description | |----------------|----------------|-----------------|-------------| | Output Cell Data | DataObjectName | | The result of the processing will be stored in this Data Array inside the same group as the input data. | ## Example Pipelines ## License & Copyright Please see the description file distributed with this plugin. ## DREAM3D-NX Help If you need help, need to file a bug report or want to request a new feature, please head over to the [DREAM3DNX-Issues](https://github.com/BlueQuartzSoftware/DREAM3DNX-Issues/discussions) GitHub site where the community of DREAM3D-NX users can help answer your questions.