DESATUR

Desaturate an image


EnvironmentsPYTHON :: EASI :: MODELER
Batch ModeYes
Quick linksDescription :: Parameters :: Parameter descriptions :: Details :: Algorithm

Back to top

Description


DESATUR alters imagery to reduce large saturated (overly bright) areas without affecting the surrounding areas and overall radiometry.
Back to top

Parameters


Name Type Length Value range
InputRef: Reference image layers * Raster port 1 - 1024  
Input: Input image layers * Raster port 1 - 1024  
Output: Desaturated layers Raster port 0 - 1024  
DESATAMT Integer 0 - 1 1 - 99
Default: 25
DESATPER Integer 0 - 1 1 - 99
Default: 50
Power Float 0 - 1024 Default: 2
PyramidLevel Integer 0 - 1024 Default: 64

* Required parameter
Back to top

Parameter descriptions

InputRef: Reference image layers

The reference imagery on which to base desaturation statistics. This file is typically a full-mosaic overview. The InputRef and Input channels are assumed to have a one-to-one correspondence in type and order, though they can be at different resolutions.

Overviews must exist for the reference file or be created with PYRAMID.

Input: Input image layers

The data to read from the input image file to be processed. The InputRef and Input channels are assumed to have a one-to-one correspondence in type and order, though they can be at different resolutions. The first input channel specified will be written to the first channel in the output, and so on.

This data must have the same projection as the reference image and be completely inside the area covered by it.

Data should be 8-bit (8U) or 16-bit (16U). Other data types, such as real, will be processed, but may yield poor results if values are outside the range of 0 to 65,535.

Output: Desaturated layers

The name of the file to which the desaturated imagery will be written. This file will have the same dimensions, projection, and data type as that specified for Input. This file will be created and a file with the same name cannot already exist.

DESATAMT

The amount (or aggressiveness) of desaturation to perform. This relates approximately to the amount (area) of the image that can be modified. The range of values is from 1 (apply almost no desaturization) to 99 (desaturate virtually the entire image). A high value, such as 50, means all bright and semi-bright areas will be desaturated. A low value, such as 5, means only a small number of very bright areas will be modified. Starting with a lower value is recommended.

This parameter is optional.

DESATPER

Percentage of bright area pixels to be desaturated. Of the bright pixels identified as candidates, those that occur below the specified percentage will not be modified, while those above may be tweaked. The range of values is from 1% (essentially no bright areas are modified) to 99% (almost all bright areas will be modified). A higher value will mean more modification is made and results will be more substantial. A low value, such as 10, means only subtle changes can occur. The default value is 50 so half of the pixels in the bright regions will be modified.

This parameter is optional.

Power

The power to apply: the higher the value, the more aggressive the desaturation.

This parameter is optional.

PyramidLevel

The pyramid level from the InputRef to compute statistics. A smaller value, such as 16, targets smaller features. A value of 16 or less or 512 or greater may yield undesirable results.

This parameter is optional.

Back to top

Details

DESATUR is an algorithm that can be used to adjust overly bright areas in any image, but it was developed specifically to create better-looking mosaics. Images often have large overly bright (or saturated) areas in which detail appears "washed out" when an enhancement (LUT) is applied. Such areas are typically quarries, beaches, building roofs, parking lots, and so forth.

Attempting to bring out detail in the washed-out areas by darkening them results in an image that is unacceptably darker overall. DESATUR solves this problem by automatically identifying washed-out areas and adjusting the data values in these areas without modifying the surrounding areas. When an enhancement is applied to this modified image, the washed-out areas will have more detail. The overall radiometry of the image is not affected.

DESATUR is ideally suited to large image mosaics as a post-processing step. The mosaic overview (usually created with MOSPREP) is used to derive global statistics and control the processing of the full-resolution mosaic tiles.

InputRef specifies the reference imagery, such as a mosaic preview. It must have overviews (or pyramids), with powers of two (2,4,8,16...) recommended. Input is the data to be desaturated. The area covered by Input must be inside the area covered by InputRef. Output specifies the name of the file that will receive the processed data. It must be a new file that will be created with the same projection, extents, and metadata as Input.

The reference file is used to control global parameters and processing to ensure that mosaic-tile files are each processed in the same way to ensure a seamless result between tiles.

The input parameters can be used to override the default processing options.

If DBIC, DESATAMT, DESATPER or DESATOPT are changed, the metadata will be ignored and the processing parameters will be recomputed as normal. If the imagery in FILREF is changed, the optional run of DESATUR must be repeated to update the metadata; otherwise, improper values will be used. The metadata tags used can be identified in FILREF with the prefix DESATUR_ at the file and image-channel levels.

Back to top

Algorithm

The algorithm is proprietary to PCI Geomatics.

© PCI Geomatics Enterprises, Inc.®, 2026. All rights reserved.