This task applies an enhanced Lee filter to a raster, to reduce speckling while preserving texture information. The enhanced Lee filter is an adaptation of the Lee filter and similarly uses local statistics (coefficient of variation) within individual filter windows.

Each pixel is put into one of three classes, which are treated as follows:

  • Homogeneous: The pixel value is replaced by the average of the filter window.
  • Heterogeneous: The pixel value is replaced by a weighted average.
  • Point target: The pixel value is not changed.

Reference: Lopes, A., R. Touzi, and E. Nezry. "Adaptive Speckle Filters and Scene Heterogeneity." IEEE Transactions on Geoscience and Remote Sensing 28, No. 6 (1990): 992-1000.

Example


; Start the application
e = ENVI()
 
; Open an input file
File = Filepath('elev_t.jpg', Subdir=['examples','data'])
Raster = e.OpenRaster(File)
 
; Get the task from the catalog of ENVITasks
Task = ENVITask('EnhancedLeeAdaptiveFilter')
 
; Define the task input raster
Task.INPUT_RASTER = Raster
 
; Define a size for the square (NxN) filtering window
Task.WINDOW_SIZE = 5
 
; Define the homogeneous cutoff value
Task.HOMOGENEOUS_CUTOFF = 0.0650
 
; Define the heterogeneous cutoff value
Task.HETEROGENEOUS_CUTOFF = 1.850
 
; Define the damping factor
Task.DAMPING_FACTOR = 1.20
 
; Run the task
Task.Execute
 
; Get the collection of data objects currently available in the Data Manager
DataColl = e.Data
 
; Add the output to the Data Manager
DataColl.Add, Task.OUTPUT_RASTER
 
; Display the result
View = e.GetView()
Layer = View.CreateLayer(Task.OUTPUT_RASTER)

Syntax


Result = ENVITask('EnhancedLeeAdaptiveFilter')

Input properties (Set, Get): DAMPING_FACTOR, HETEROGENEOUS_CUTOFF, HOMOGENEOUS_CUTOFF, INPUT_RASTER, OUTPUT_RASTER_URI, WINDOW_SIZE

Output properties (Get only): OUTPUT_RASTER

Properties marked as "Set" are those that you can set to specific values. You can also retrieve their current values any time. Properties marked as "Get" are those whose values you can retrieve but not set.

Methods


This task inherits the following methods from ENVITask:

AddParameter

Execute

Parameter

ParameterNames

RemoveParameter

Properties


This task inherits the following properties from ENVITask:

COMMUTE_ON_DOWNSAMPLE

COMMUTE_ON_SUBSET

DESCRIPTION

DISPLAY_NAME

NAME

REVISION

TAGS

This task also contains the following properties:

DAMPING_FACTOR (required)

Specify a floating-point damping factor that inversely defines the extent of the exponential damping in the weighted average for the heterogeneous class. A larger damping factor produces less averaging.

HETEROGENEOUS_CUTOFF (optional)

Specify a floating-point value that represents the coefficient of variation cutoff for heterogeneous areas. The default value is 1.732.

HOMOGENEOUS_CUTOFF (optional)

Specify a floating-point value that represents the coefficient of variation cutoff for homogeneous areas. The default value is 0.523.

INPUT_RASTER (required)

Specify a raster on which to perform enhanced Lee adaptive filtering.

OUTPUT_RASTER

This is a reference to the output raster of filetype ENVI.

OUTPUT_RASTER_URI (optional)

Specify a string with the fully qualified filename and path of the associated OUTPUT_RASTER. If you do not specify this property, or set it to an exclamation symbol (!), a temporary file will be created.

WINDOW_SIZE (optional)

Specify a square filtering window size, in pixels. The default value is 3.

Version History


ENVI 5.3

Introduced

API Version


4.3

See Also


ENVITask, ENVISubsetRaster, AdditiveLeeAdaptiveFilter Task, AdditiveMultiplicativeLeeAdaptiveFilter Task, BitErrorAdaptiveFilter Task, EnhancedFrostAdaptiveFilter Task, FrostAdaptiveFilter Task, GammaAdaptiveFilter Task, KuanAdaptiveFilter Task, LocalSigmaAdaptiveFilter Task, MultiplicativeLeeAdaptiveFilter Task