EXPOLRAS

Extract and refine polygons from raster


EnvironmentsPYTHON :: EASI :: MODELER
Quick linksDescription :: Parameters :: Parameter descriptions :: Details :: Example :: Related

Back to top

Description


EXPOLRAS converts an input raster image to a binary image using a specified threshold value, extracts polygons from the resulting binary image, and then filters them based on area and compactness values. Finally, it outputs results to a vector layer.
Back to top

Parameters


Name Type Caption Length Value range
FILI * String Input file name 1 - 192  
DBIC * Integer Input raster channel 1 - 1  
THRTYPE * String Conversion threshold type 10 - 10 Percentage | PixelValue
Default: PixelValue
TVAL * Float Threshold value 1 - 2  
AREAVAL Float Area value 0 - 2  
COMPVAL Float Compactness value 0 - 2  
FILO * String Output file name 1 - 192  
FTYPE String Output file type 0 - 4 See Parameter Details.
Default: PIX
FOPTIONS String Output file options 0 - 64  
MONITOR String Monitor mode 0 - 3 ON, OFF
Default: ON

* Required parameter
Back to top

Parameter descriptions

FILI

The name of the GDB-supported file that contains the image to be converted and filtered.

DBIC

The input raster channel to use to extract the polygons. You can specify only one channel. To create polygons resulting from change-detection analysis, specify the channel that contains the change-detection results.

THRTYPE

The threshold type to use to convert the input raster to a binary image.

Supported types are:

The value attributed to the specified threshold type is defined with the Threshold value (TVAL) parameter.

TVAL

The minimum and maximum threshold values, based on the value specified for the Threshold type (THRTYPE) parameter. If only one value is specified, pixels with values (or percentile value) equal to or above the specified value are retained.

When this parameter specifies a pixel value, that value should be within the dynamic range of the specified input channel (DBIC).

Note: If you specify the same pixel value for the minimum and maximum thresholds, only pixels of that value are used.

AREAVAL

The minimum and maximum area values, in pixels, by which to filter extracted features based on their size.

All polygons with values within the defined range are retained. If only one value is specified, polygons with an area equal to or above the specified value are retained.

COMPVAL

The minimum and maximum values of compactness for the target polygons.

All polygons with compactness values within the defined range are retained. If only one value is specified, polygons with compactness values equal to or above the specified value are retained.

Compactness is a ratio describing of the area of a polygon to its perimeter, defined as follows:

Compactness = 4*3.141592653589*Area / (Perimeter * Perimeter)

The value of compactness is between 0 and 1, where 1 represents a circle.

FILO

The name of the output file.

If necessary, you can specify an existing PCIDSK file, in which case the output vector segment will be appended to that file. You can also specify a name of a new file to create.

The name of the output file can be the same as the input file. If the specified output file already exists, it must be updatable and must support vector segments; if it is not, or if the format does not support vectors, it will cause an error.

FTYPE

The format type of the output file, represented by its file extension. The format type must be a GDB-supported vector file type.

Supported file format codes include, among others:

The default value is PIX.

For more information on GDB-recognized file types, including file name extensions, see Supported file formats under GDB file formats in the Technical referencesection of the CATALYST Professional Help.

FOPTIONS

The file creation options to be applied when creating the output file. These are specific to the file format; in each case, the default of no options is allowed. FOPTIONS can be used to specify the compression schemes, file format subtypes, and other information.

Different options are available for each file type. For more information on GDB-recognized file types, including the available options, see Supported file formats under GDB file formats in the Technical referencesection of the CATALYST Professional Help.

MONITOR

The program progress can be monitored by printing the percentage of processing completed. A system parameter, MONITOR, controls this activity.

Available options are:

Back to top

Details

EXPOLRAS produces polygons for pixels for which the digital number (DN) or percentile value is higher than, or within the range of, the value specified as threshold (TVAL) and filters out those that do not fit within the specified area and compactness range of values. By default, only the threshold value is required; polygons will be derived using pixels above the specified threshold value. This function is typically used in conjunction with a change-detection image; for example, the output from CHDETOP or CCDINTEN.

When a percentage threshold is specified, it represents values of significance. The pixel value corresponding to the specified percentile is calculated from the input image, and only the pixels above the specified percentile (or within the percentile range) are retained. By specifying a threshold of 95 (95 percent) for processing a change-detection image, the pixels falling above the 95th percentile of change will be kept.

If you specify a minimum area value, only those polygons larger than the specified area value are retained, and the attribute table will contain the area value (for the remaining polygons) in pixel units in the "PixelCount" field. If you specify a compactness value or range, only those polygons above the defined compactness (or within the defined range) are retained, and their compactness value is written to the attribute table in the "Compactness" field.

The following fields are computed and written to the output attributes: Area, Perimeter, PixelCount, Compactness, Length and Orientation. Length is computed as the longest distance between any two vertices of each extracted polygon shape. Orientation is the slope of the line connecting those two vertices, in degrees. If you were extracting ships from imagery, the Length value could approximate the keel length while the Orientation could be the ship's heading.

If none of the polygons match the area or compactness criteria (for example, if the polygons are smaller than the specified area value) an error will occur.

Note that NoData pixels are excluded from consideration with one exception. When EXPOLRAS is run with Threshold type set to PIXELVALUE and threshold minimum and maximum are both specifed as the NoData number, then polygons will be extracted around those NoData pixels only. For example: THRTYPE=PIXELVALUE and TVAL=0,0 and NoData=0.

Back to top

Example

EASI>FILI	=	"chdetop.pix"
EASI>DBIC	=	1
EASI>THRTYPE	=	"PixelValue"
EASI>TVAL	=	70
EASI>AREAVAL	=	10.0	! only features larger than 10 pixels are retained
EASI>COMPVAL	=
EASI>FILO	=	"vector.pix"
EASI>FTYPE	=
EASI>FOPTIONS	=

EASI>RUN expolras

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