>  Docs Center  >  Using ENVI  >  Mahalanobis Distance
ENVI

Mahalanobis Distance

Mahalanobis Distance

Mahalanobis distance classification is a direction-sensitive distance classifier that uses statistics for each class. It is similar to Maximum Likelihood classification but assumes all class covariances are equal and therefore is a faster method. All pixels are classified to the closest ROI class unless you specify a distance threshold, in which case some pixels may be unclassified if they do not meet the threshold.

Reference: Richards, J.A. Remote Sensing Digital Image Analysis Berlin: Springer-Verlag (1999), 240 pp.

  1. Use the ROI Tool to define training regions for each class. The more pixels and classes, the better the results will be.
  2. Use the ROI Tool to save the ROIs to an .roi file.
  3. Display the input file you will use for Mahalanobis Distance classification, along with the ROI file.
  4. Select one of the following:
    • From the Toolbox, select Classification > Supervised Classification > Mahalanobis Distance Classification.
    • From the Endmember Collection dialog menu bar, select Algorithm > Mahalanobis Distance. Import (or re-import) the endmembers so that ENVI will import the endmember covariance information along with the endmember spectra. Click Apply.

    The Classification Input File dialog appears.

  5. Select an input file and perform optional spatial and spectral subsetting, and/or masking, then click OK. The Mahalanobis Distance Parameters dialog appears.
  6. In the Select Classes from Regions list, select ROIs and/or vectors as training classes. The ROIs listed are derived from the available ROIs in the ROI Tool dialog. The vectors listed are derived from the open vectors in the Available Vectors List.
  7. Select one of the following thresholding options from the Set Max Distance Error area:
    • None: Use no standard deviation threshold.
    • Single Value: Use a single threshold for all classes. Enter a value in the Set Max Distance Error field, in DNs. ENVI does not classify pixels at a distance greater than this value.
  8. If you set values for both Set Max stdev from Mean and Set Max Distance Error, the classification uses the smaller of the two to determine which pixels to classify. If you select None for both parameters, then ENVI classifies all pixels.

  9. Multiple Values: Enter a different threshold for each class. Use this option as follows:
    1. In the list of classes, select the class or classes to which you want to assign different threshold values and click Multiple Values. The Assign Max Distance Error dialog appears.
    2. Select a class, then enter a threshold value in the field at the bottom of the dialog. Repeat for each class. Click OK when you are finished.
  10. Select classification output to File or Memory.
  11. Use the Output Rule Images? toggle button to select whether or not to create rule images. Use rule images to create intermediate classification image results before final assignment of classes. You can later use rule images in the Rule Classifier to create a new classification image without having to recalculate the entire classification.
  12. If you selected Yes to output rule images, select output to File or Memory.
  13. Click Preview to see a 256 x 256 spatial subset from the center of the output classification image. Change the parameters as needed and click Preview again to update the display.
  14. Click OK. ENVI adds the resulting output to the Layer Manager. If you selected to output rule images, ENVI creates one for each class with the pixel values equal to the distances from the class means. Areas that satisfied the minimum distance criteria are carried over as classified areas into the classified image. If a pixel falls into two or more classes, ENVI classifies it into the class coinciding with the first-listed ROI.



© 2019 Harris Geospatial Solutions, Inc. |  Legal
My Account    |    Store    |    Contact Us