Maximum Likelihood Classification
Maximum likelihood classification assumes that the statistics for each class in each band are normally distributed and calculates the probability that a given pixel belongs to a specific class. Unless you select a probability threshold, all pixels are classified. Each pixel is assigned to the class that has the highest probability (that is, the maximum likelihood). If the highest probability is smaller than a threshold you specify, the pixel remains unclassified.
ENVI implements maximum likelihood classification by calculating the following discriminant functions for each pixel in the image (Richards, 1999):
Where:
i = class
x = n-dimensional data (where n is the number of bands)
p(ωi) = probability that class ωi occurs in the image and is assumed the same for all classes
|Σi| = determinant of the covariance matrix of the data in class ωi
Σi-1 = its inverse matrix
mi = mean vector
Reference: Richards, J. Remote Sensing Digital Image Analysis, Berlin: Springer-Verlag (1999), 240 pp.
You can also write a script to perform Maximum Likelihood classification using the MaximumLikelihoodClassification task.
- From the Toolbox, select Classification > Supervised Classification > Maximum Likelihood Classification. The Maximum Likelihood Classification dialog appears.
- Select an Input Raster and perform optional spatial and spectral subsetting, and/or masking.
- Select the Input ROIs file that represents the classes. Statistics from the ROIs are used as input to the Maximum Likelihood calculation.
- In the Threshold Probability field, enter a scalar value for all classes or array of values, one per class, from 0 to and 1. For arrays, the number of elements must equal the number of classes. Pixels with a value lower than the threshold will not be classified. The default value is 0.00000000. The threshold is a probability minimum for inclusion in a class. For example, a value of 0.9 will include fewer pixels in a class than a value of 0.5 because a 90 percent probability requirement is more strict than allowing a pixel in a class based on a chance of 50 percent.
- Specify a filename and location for the Output Rule Raster. A rule raster is a greyscale image that shows intermediate classification results, where each band represents a rule raster for each class. With Maximum Likelihood classification, pixel values contain a maximum likelihood discriminant function with a modified Chi Squared probability distribution. Higher rule image values indicate higher probabilities.
-
Enable the Display result check box to display the output in the view when processing is complete. Otherwise, if the check box is disabled, the result can be loaded from the Data Manager.
- Specify a filename and location for the Output Raster (the classification raster).
-
Enable the Display result check box to display the output in the view when processing is complete. Otherwise, if the check box is disabled, the result can be loaded from the Data Manager.
- Enable the Preview check box to preview the settings before processing the data. The preview is calculated only on the area in the view and uses the resolution level at which you are viewing the image. To preview a different area in your image, pan and zoom to the area of interest and re-enable the Preview option. Depending on the algorithm being used by the tool, the preview result might be different from the final result of processing on the full extent, full resolution of the input image in the following scenarios: 1) If you zoomed out of the input raster in the view by 50%, or a percentage less than 50%, ENVI uses a downsampled image at the closest resolution level to calculate the preview, or 2) If the entire image is not visible in the view, ENVI uses the subset in the viewable area of the input image to calculate the preview.
-
To see an ENVI Modeler version of this tool that shows how it is constructed from individual tasks, click Open in Modeler.
-
To reuse these task settings in future ENVI sessions, save them to a file. Click the down arrow next to the OK button
, select Save Parameter Values, then specify the path and filename to save to. Note that some parameter types, such as rasters, vectors, and ROIs, will not be saved with the file. To apply the saved task settings, click the down arrow and select Restore Parameter Values, then select the file where you previously saved your settings.
-
You can run the process in the background on your computer or in the background on an ENVI Server (if available). Click the down arrow
next to the OK button and select one of the following:
- Run Task in the Background: Runs the process on your computer. This method does not use an ENVI Server. The job progress will show in the ENVI Job Console's Background Jobs tab.
- Run Task on envi_server_name. Runs the process on the selected ENVI Server. The job progress will show in the ENVI Job Console's envi_server_name tab.
See ENVI Job Console for details on monitoring ENVI Server jobs and viewing results. See ENVI Servers for details on configuring and using an ENVI Server.
- Click OK.