SIEVE

Sieve filter (class merging)


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

Back to top

Description


Reads an image channel and merges image value polygons smaller than a user-specified threshold with the largest neighboring polygon. This function is typically used to filter small classification polygons from a classification result.
Back to top

Parameters


Name Type Length Value range
Input: Input raster channel* Raster port 1 - 1  
Output: Output raster channel* Raster port 1 - 1  
Polygon Size Threshold Integer 0 - 1 1 -
Exclude Values List Integer 0 - 48  
Connectedness of Lines Integer 0 - 1 4 | 8
Default: 4

* Required parameter
Back to top

Parameter descriptions

Input: Input raster channel

Specifies the image channel that contains the classification polygons.

Output: Output raster channel

Specifies the image channel to receive the merged classification result. The output channel may be the same as the specified input channel.

Note: 32-bit real data will be truncated to integer values.

Polygon Size Threshold

Specifies the size, in pixels, of the smallest polygon not to be merged into a neighbor. This value must be greater than zero.

Note: Large Polygon Size Threshold values require more memory.

Exclude Values List

Specifies a list of up to 48 image values to exclude from the sieve operation. Polygons with these values will not be replaced, nor will other polygons be replaced with these values unless the polygon is surrounded by pixels in this list.

Connectedness of Lines

Specifies whether polygons are determined on the basis of eight connectedness, or four connectedness.

Supported values are:

Polygons are determined on the basis of adjacent pixels of the same value. In a four-connected polygon, pixels are considered adjacent if they are in contact horizontally or vertically. Eight connectedness also includes pixels in contact on the diagonal.

Back to top

Details

SIEVE performs a sieve filtering operation on the input data. The sieve filter removes all polygons smaller than the given size, measured in pixel area. Each polygon smaller than the defined threshold is merged with its largest neighbor.

A polygon is defined as a four- or eight-connected collection of pixels with the same digital value. Eight-connected implies that two pixels with the same gray-level value are part of the polygon if they are side-by-side, one above the other, or diagonally in contact. Four-connected, on the other hand, only includes side-by-side, or one above the other contact.

SIEVE may need to make multiple passes to remove all polygons smaller than the threshold size, though this is rarely necessary. Note that SIEVE operates on integer values, and 32R input channels will lose precision.

SIEVE builds up a list of all the polygons in the input channel in memory; therefore, input channels with many small polygons require much more memory than those with relatively few polygons. An error occurs if SIEVE exhausts available memory for storing polygon information. It may be helpful to run FMO to reduce the number of polygons before running SIEVE.

SIEVE copies the metadata from the input channel to the output channel.

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