User Guid
User Guid
Guide
0901ENV35USR
Restricted Rights Notice
The ENVI® and IDL® software programs and the accompanying procedures, functions, and docu-
mentation described herein are sold under license agreement. Their use, duplication, and disclosure
are subject to the restrictions stated in the license agreement. Research System, Inc., reserves the
right to make changes to this document at any time and without notice.
Limitation of Warranty
Research Systems, Inc. makes no warranties, either express or implied, as to any matter not
expressly set forth in the license agreement, including without limitation the condition of the soft-
ware, merchantability, or fitness for any particular purpose.
Research Systems, Inc. shall not be liable for any direct, consequential, or other damages suffered
by the Licensee or any others resulting from use of the ENVI and IDL software packages or their
documentation.
Acknowledgments
ENVI® and IDL ® are registered trademarks of Research Systems, Inc., registered in the United States Patent and Trademark
Office, for the computer program described herein. Dancing Pixels, Pixel Purity Index, PPI, n-Dimensional Visualizer, Spec-
tral Analyst, Spectral Feature Fitting, SFF, Mixture-Tuned Matched Filtering, MTMF, 3D-SurfaceView, Band Math, Spectral
Math, ENVI Extension, Empirical Flat Field Optimal Reflectance Transformation (EFFORT), and Virtual Mosaic are trade-
marks of Research Systems, Inc.
Numerical Recipes™ is a trademark of Numerical Recipes Software. Numerical Recipes routines are used by permission.
GRG2™ is a trademark of Windward Technologies, Inc. The GRG2 software for nonlinear optimization is used by permission.
NCSA Hierarchical Data Format (HDF) Software Library and Utilities
Copyright © 1988-1998 The Board of Trustees of the University of Illinois
All rights reserved.
CDF Library
Copyright © 1999
National Space Science Data Center
NASA/Goddard Space Flight Center
NetCDF Library
Copyright © 1993-1996 University Corporation for Atmospheric Research/Unidata
HDF EOS Library
Copyright © 1996 Hughes and Applied Research Corporation
This software is based in part on the work of the Independent JPEG Group.
This product contains StoneTable™, by StoneTablet Publishing. All rights to StoneTable™ and its documentation are retained by
StoneTablet Publishing, PO Box 12665, Portland OR 97212-0665. Copyright © 1992-1997 StoneTablet Publishing
WASTE text engine © 1993-1996 Marco Piovanelli
Portions of this software are copyrighted by INTERSOLV, Inc., 1991-1998.
Use of this software for providing LZW capability for any purpose is not authorized unless user first enters into a license agreement
with Unisys under U.S. Patent No. 4,558,302 and foreign counterparts. For information concerning licensing, please contact: Unisys
Corporation, Welch Licensing Department - C1SW19, Township Line & Union Meeting Roads, P.O. Box 500, Blue Bell, PA 19424.
Portions of this computer program are copyright © 1995-1999 LizardTech, Inc. All rights reserved. MrSID is protected by U.S. Patent
No. 5,710,835. Foreign Patents Pending.
Other trademarks and registered trademarks are the property of the respective trademark holders.
Contents
Preface ................................................................................................... 11
Introduction to ENVI ....................................................................................................... 12
ENVI, ENVI RT, and IDL .............................................................................................. 14
General Review of ENVI Functionality .......................................................................... 15
ENVI Documentation ...................................................................................................... 18
About this Manual ........................................................................................................... 20
Using ENVI Online Help ................................................................................................ 21
Reporting Problems ......................................................................................................... 28
Chapter 1:
Introduction to ENVI .............................................................................. 31
Starting ENVI .................................................................................................................. 32
ENVI Graphical User Interface (GUI) ............................................................................ 33
General Image Display Concepts .................................................................................... 34
Data Management ............................................................................................................ 39
Memory Management ..................................................................................................... 41
Chapter 2:
File Management .................................................................................. 63
The File Menu .................................................................................................................. 64
Opening Image Files ........................................................................................................ 65
Opening External Files .................................................................................................... 68
Opening Vector Files ....................................................................................................... 89
Opening Previous Files .................................................................................................... 98
Editing ENVI Headers ..................................................................................................... 99
Generating Test Data ..................................................................................................... 112
Using the Data Viewer ................................................................................................... 115
Saving Files .................................................................................................................... 117
Importing IDL Variables ................................................................................................ 124
Exporting to IDL Variables ........................................................................................... 125
Compiling IDL Code ..................................................................................................... 126
IDL CPU Parameters ..................................................................................................... 127
Tape Utilities .................................................................................................................. 129
The Scan Directory List ................................................................................................. 153
Changing Output Directories ......................................................................................... 157
Saving Sessions to Scripts ............................................................................................. 157
Executing Startup Scripts ............................................................................................... 157
Restoring Display Groups .............................................................................................. 157
Using the ENVI Queue Manager ................................................................................... 158
Logging Processing Information .................................................................................... 159
Closing all Files ............................................................................................................. 159
Setting ENVI Preferences .............................................................................................. 160
Chapter 3:
Display Management .......................................................................... 169
The Window Menu ........................................................................................................ 170
Using the Window Finder .............................................................................................. 171
Starting New Displays ................................................................................................... 172
Starting New Vector Windows ...................................................................................... 172
Chapter 4:
Interactive Display Functions ............................................................ 211
The Display Menu ......................................................................................................... 212
Display Functions .......................................................................................................... 214
Creating Vector Layers ................................................................................................. 215
Saving Display Groups .................................................................................................. 216
Setting Display Preferences ........................................................................................... 217
Overlays ......................................................................................................................... 220
Annotating Images ........................................................................................................ 222
Overlaying Classes ........................................................................................................ 243
Plotting Contour Lines .................................................................................................. 249
Interactive Density Slicing ............................................................................................ 255
Grid Lines ...................................................................................................................... 256
Defining Regions of Interest ......................................................................................... 261
Creating QuickMaps ...................................................................................................... 289
Overlaying Vectors ........................................................................................................ 295
Contrast Stretching and Quick Filtering ........................................................................ 316
Display Filtering ............................................................................................................ 317
Applying Default (Quick) Stretches .............................................................................. 318
Matching Histograms .................................................................................................... 320
Using Interactive Stretching .......................................................................................... 321
Chapter 5:
Basic Tools .......................................................................................... 409
The Basic Tools Menu ................................................................................................... 410
Resizing Data (Spatial/Spectral) .................................................................................... 411
Subsetting Data via ROIs ............................................................................................... 418
Rotating Images ............................................................................................................. 419
Layer Stacking ............................................................................................................... 421
Converting Data (BSQ, BIL, BIP) ................................................................................. 423
Stretching Data ............................................................................................................... 425
Statistics ......................................................................................................................... 427
Using the Measurement Tool ......................................................................................... 437
Band Math ...................................................................................................................... 441
Spectral Math ................................................................................................................. 449
Segmenting Images ........................................................................................................ 450
Regions of Interest ......................................................................................................... 452
Mosaicking Images ........................................................................................................ 457
Masking .......................................................................................................................... 458
General Purpose Utilities ............................................................................................... 464
Chapter 6:
Classification ....................................................................................... 493
The Classification Menu ............................................................................................... 494
Collecting Endmember Spectra ..................................................................................... 495
Supervised Classification .............................................................................................. 503
Unsupervised Classification .......................................................................................... 517
Creating Class Images from ROIs ................................................................................. 522
Post Classification ......................................................................................................... 523
Chapter 7:
Transforms ........................................................................................... 549
The Transforms Menu ................................................................................................... 550
Image Sharpening .......................................................................................................... 551
Calculating Band Ratios ................................................................................................ 553
Principal Component Analysis ...................................................................................... 556
Minimum Noise Fraction Transform ............................................................................ 563
Color Transforms .......................................................................................................... 575
Applying Decorrelation Stretch ..................................................................................... 580
Applying Saturation Stretch .......................................................................................... 581
Creating Synthetic Color Images .................................................................................. 582
Calculating Vegetation Indices ..................................................................................... 584
Chapter 8:
Filters ................................................................................................... 587
The Filter Menu ............................................................................................................. 588
Convolution Filters ........................................................................................................ 589
Morphology Filters ........................................................................................................ 594
Using Texture Filters ..................................................................................................... 599
Using Adaptive Filters ................................................................................................... 604
Using Frequency Filters (FFTs) .................................................................................... 611
Chapter 9:
Spectral Tools ...................................................................................... 617
The Spectral Menu ........................................................................................................ 618
Spectral Libraries .......................................................................................................... 619
Chapter 10:
Map Tools ............................................................................................ 699
The Map Menu ............................................................................................................... 700
Registration .................................................................................................................... 701
Orthorectification ........................................................................................................... 720
Image Mosaicking .......................................................................................................... 731
Georeferencing from Input Geometry ........................................................................... 745
Georeferencing SeaWiFS Data ...................................................................................... 752
Georeference AVHRR Data .......................................................................................... 755
Selecting Map Projection Types .................................................................................... 757
Building Customized Map Projections .......................................................................... 758
Converting Map Projections .......................................................................................... 762
Layer Stacking ............................................................................................................... 764
Converting Map Coordinates ......................................................................................... 765
Converting ASCII Coordinates ...................................................................................... 767
Merging Old Projection Files ......................................................................................... 769
Using GPS-Link ............................................................................................................. 770
Chapter 11:
Vector Tools ........................................................................................ 773
The Vector Menu ........................................................................................................... 774
Opening Vector Files ..................................................................................................... 775
The Available Vectors List ............................................................................................ 776
Creating Vector Layers .................................................................................................. 777
Creating World Boundary Layers .................................................................................. 779
Chapter 12:
Topographic Tools .............................................................................. 787
The Topographic Menu ................................................................................................. 788
Opening Topographic Files ........................................................................................... 789
Using Topographic Modeling ....................................................................................... 790
Extracting Topographic Features .................................................................................. 794
Creating Hill Shade Images ........................................................................................... 797
Replacing Bad Values ................................................................................................... 800
Rasterizing Point Data ................................................................................................... 801
Using 3-D SurfaceView ................................................................................................ 802
Chapter 13:
Radar Tools .......................................................................................... 819
The Radar Menu ............................................................................................................ 820
Opening Radar Files ...................................................................................................... 821
Removing Antenna Gain Variations ............................................................................. 824
Resampling to Ground Ranges ...................................................................................... 826
Generating Incidence Angle Images ............................................................................. 828
Adaptive Filters ............................................................................................................. 829
Texture Filters ............................................................................................................... 830
Creating Synthetic Color Images .................................................................................. 831
Using Polarimetric Tools ............................................................................................... 832
Using TOPSAR Tools ................................................................................................... 857
Appendix A:
Installing and Customizing ENVI ....................................................... 859
ENVI Hardware Requirements ..................................................................................... 860
Installing and Starting ENVI ......................................................................................... 861
Platform Dependencies .................................................................................................. 862
ENVI Items to be Aware of ........................................................................................... 864
Appendix B:
ENVI File Formats ............................................................................... 877
ENVI Header Format ..................................................................................................... 879
ENVI Graphic Colors File ............................................................................................. 883
ENVI File Type File (filetype.txt) ................................................................................. 884
ENVI Sensor File (sensor.txt) ........................................................................................ 885
ENVI Map Projections File ........................................................................................... 886
ENVI Ellipsoid File (ellipse.txt) .................................................................................... 887
ENVI Datum File (datum.txt) ........................................................................................ 888
ENVI State Plane Projection Files ................................................................................. 889
ENVI Spectral Library Files .......................................................................................... 890
ENVI Previous Files List ............................................................................................... 891
Other ENVI ASCII Files ................................................................................................ 892
Appendix C:
ENVI Spectral Libraries ...................................................................... 899
General Information ....................................................................................................... 900
USGS Spectral Library (Minerals) ................................................................................ 901
USGS Spectral Library (Vegetation) ............................................................................. 902
Additional Vegetation Libraries .................................................................................... 903
JPL Spectral Library ...................................................................................................... 904
IGCP264 Spectral Library ............................................................................................. 905
JHU Spectral Library ..................................................................................................... 907
Appendix D:
ENVI Map Projections ........................................................................ 911
Map Projections ............................................................................................................. 913
Introduction to ENVI
ENVI® (the Environment for Visualizing Images) is a revolutionary image
processing system. From its inception, ENVI was designed to address the numerous
and specific needs of those who regularly use satellite and aircraft remote sensing
data. ENVI provides comprehensive data visualization and analysis for images of any
size and any type—all from within an innovative and user-friendly environment.
Advantages of ENVI
ENVI’s developers are scientists who actively participate in remote sensing research.
Because of their interests in the development of the field, these scientists continually
supplement ENVI with leading-edge technology and innovative and useful functions.
ENVI’s power and applicability to current remote sensing problems are continually
expanding.
One of ENVI’s strengths lies in its unique approach to image processing—it
combines file-based and band-based techniques with interactive functions. When a
data input file is opened, its bands are stored in a list, where they can be accessed by
all system functions. If multiple files are opened, bands of disparate data types can be
processed as a group. ENVI displays these bands in 8- or 24- bit displays windows.
ENVI’s display window groups consist of a main image window, a zoom window,
and a scroll window, all of which are re-sizeable. ENVI provides its users with many
unique interactive analysis capabilities, accessed from within these windows. ENVI’s
multiple dynamic overlay capabilities allow easy comparison of images in multiple
displays. Real-time extraction and linked spatial/spectral profiling from multiband
and hyperspectral data give users new ways of looking at high-dimensional data.
ENVI also provides interactive tools to view and analyze vectors and GIS attributes.
Standard capabilities such as contrast stretching and 2-dimensional scatter plots are
just a few of the interactive functions available to ENVI users.
Finally, ENVI provides tools to take image data to final map form. These include
both image-to-image and image-to-map registration, basic orthorectification, image
mosaicking, and map composition utilities. An integrated set of vector GIS import,
export, and analysis tools provide the capability to bring industry-standard GIS data
into ENVI, view and analyze vectors and GIS attributes (as image overlays as well as
in a separate vector analysis window), modify existing vectors, query attributes,
utilize vector layers for raster analysis or generate new vector GIS layers from raster
image processing results, and create standard GIS export-format files.
ENVI provides all of these capabilities and more in one tightly integrated image
analysis package. For additional information about specific functionality, please see
the corresponding sections of interest in this Users’ Guide.
ENVI Documentation
ENVI’s documentation set includes Release Notes (distributed as a .txt file on the
ENVI CD and installed into the ENVI installation directory), the What’s New in
ENVI guide, the ENVI User’s Guide, the ENVI Programmer’s Guide and the ENVI
Tutorials. All documentation (except the Release Notes) is distributed with ENVI in
Adobe Acrobat PDF format.
Note
To view the ENVI manuals in PDF format, you need Adobe Acrobat 3.0 or later.
Acrobat Reader 4.0 with Search is included on your product CD-ROM. Visit Adobe
Systems Web site at www.adobe.com for the latest information and downloads
concerning Acrobat Reader.
Installation Guide
Describes how to install and license ENVI.
routines, batch processing, and other report and plotting tools. The suite of ENVI
routines available to the programmer greatly simplifies development of these routines
while maintaining the same “look-and-feel”.
ENVI Tutorials
ENVI includes tutorials designed to lead the new user through the program’s basic
functionality. These include some remote sensing background and step-by-step
procedures to execute the corresponding ENVI functions. Some of the tutorials
provided are: multispectral classification, georeferencing and registration,
mosaicking, vector overlay and GIS analysis, map composition, several hyperspectral
data analysis tutorials, and both basic and advanced SAR processing. Sample datasets
are provided on the ENVI Tutorial and Data CD’s for use with these tutorials.
Warning
Warnings appear in this format.
Tip
Helpful hints and tips appear in this format.
2. In the ENVI Online Help Window, select from the following options:
• Click on the colored underlined links to view more information.
• Click on the “Contents,” “Index,” or “Search” tabs in the left window
pane.
• Click on the “Contents,” “Index,” or “Find” buttons at the top of the
window.
See the following sections for details.
1. Double-click
on a book or
click the “+” to
reveal the list of
topics.
2. Double-click
on a topic to
display it.
Figure 2: The ENVI Online Help Contents window with the highlighted
topic displayed.
Figure 3: The ENVI Online Help Index window with the highlighted
topic displayed.
Figure 4: The ENVI Online Help Find window with the highlighted
topic displayed.
Click on
these links
to view the
details.
Reporting Problems
When you encounter a problem with ENVI, please report them as quickly as possible
so we can fix it. This section is intended to help you report problems in a way that
will help us correct the problem rapidly.
Background Information
When a bug is reported and verified, we correct it in a later release. Sometimes, a bug
only occurs when running on a certain machine, operating system, or graphics device.
For these reasons, we need to know the following facts when you report a bug:
• Your ENVI installation number.
• The version of ENVI you are running.
• The type of machine it is running on.
• The operating system version it is running under.
• The type and version of your windowing system.
• The graphics device, if the problem involves graphics.
The installation number is assigned by us when you purchase ENVI. The ENVI
version, site number, and type of machine are printed when ENVI is started.
Under Unix, the version of the operating system can usually be found in the file
/etc/motd. It is also printed when the machine boots. In any event, your system
administrator should know.
Under Windows 95, Windows 98, Windows 2000, and Windows NT version 4, select
“About” from the Help menu in the Windows Explorer.
On the Macintosh, select “About this Macintosh” from the apple menu.
Double Check
Before reporting a problem, you should verify that the problem is a bug and not
simply a matter of misinterpreting the expected outcome of a specific function or
action. Double check by reviewing the documentation and the online help or by
checking with a local expert. Make sure your system is properly configured with
enough virtual memory and sufficient operating system quotas.
If you cannot find the information you need in the ENVI written guides or online
help, please let us know so we can improve the clarity and content of the
documentation.
Mail
Research Systems, Inc.
4990 Pearl East Circle
Boulder, Colorado 80301
Telephone
(303) 786-9900 (Voice)
(303) 786-9909 (Fax)
(303) 413-3920 (IDL technical support direct line)
Electronic Mail
[email protected]
Starting ENVI
Before starting ENVI, ensure that it is properly installed as described in the
installation guide. The installation guide is included with the ENVI CDs.
• To start ENVI in Unix, enter “envi” at the UNIX command line.
• To start ENVI RT in Unix, enter “envi_rt” at the UNIX command line.
• To start ENVI (or ENVI RT) from a Macintosh system, drag the ENVI or
ENVI RT icon onto the IDL 5.4 icon.
• To start ENVI (or ENVI Runtime) from a Windows system, select Start >
Programs > ENVI 3.4 > ENVI.
The ENVI Main Menu appears when the program has successfully loaded and
executed.
Figure 1-1: An ENVI Display Group. These windows can be individually placed
anywhere on the screen.
Resizing Windows
Most ENVI windows and dialogs, including all image display windows, can be
dynamically resized up to the full screen dimensions.
1. Place the mouse cursor on the edge or corner of the dialog or window until the
cursor becomes a two-way arrow (see Figure 1-2).
2. Click with the left mouse button and drag the window to the desired size and
shape.
Tip
When you resize a Scroll window, the resampling factor is automatically changed to
take advantage of the new image size. The resampling factor appears in parentheses
in the Scroll window’s title bar. If you resize the Main image window so that it is
large enough to contain the entire image, the scroll window will disappear. It will
reappear if the image window is made smaller.
Figure 1-2: An ENVI display window. Notice the two-way arrow cursor on
the right edge.
Supplemental Windows
ENVI image displays may have a large number of associated supplemental windows.
Supplemental windows are typically started from the Display menu (see “The
Display Menu” on page 212), and may include X, Y, Z, and arbitrary profiles,
histograms, scatter plots, and animation windows. Each supplemental window is
associated with a specific image display group. Multiple displays can have
independent groups of supplemental windows.
Data Management
ENVI provides a number of tools for managing images, vector data, dialogs, and
individual windows. These tools are discussed in the following sections.
writing of memory calculations to disk files. These actions allow optimized use of
system memory (see “The Available Files List” on page 173).
Note
Use the “Cancel” button to terminate processing if the increment is less than 100%.
If the increment is equal to 100%, interruption of the function is not possible.
Memory Management
ENVI allows processing of large data sets by tailoring to system memory resources.
ENVI uses tiling to break data sets into manageable pieces and allows you to set the
size of a tile in the ENVI configuration file.
Tiling Operations
ENVI uses “tiling” to allow the processing of large images and to control system
memory usage. A tile is a piece of data read from the disk or from memory in one
piece. The size of an individual tile in ENVI is controlled by setting the desired value
in the ENVI configuration file (see “The ENVI Configuration File” on page 867). For
images stored as BSQ (Band Sequential), each tile is a spatial subset of an individual
band. For images stored sequentially in BIL (Band Interleaved by Line) format, each
tile is a single image line of all bands. For BIP (Band Interleaved by Pixel) format,
each tile is all of the pixels in an image line for all bands. Tiling is generally
transparent to you as the user and is used by ENVI to insure that hardware memory
limitations do not impose processing limitations (see “Configuration File Details” on
page 867 and “Additional Caching Information” on page 876).
ENVI Basics
This section describes standard ENVI file opening procedures and options and other
standard ENVI functions that are common in many ENVI windows and dialogs.
4. Click “OK.”
Figure 1-6: The Input File dialog shows expanded and collapsed image file
bands.
Subsetting by Samples/Lines
• To select by starting and ending values of the subset, enter the starting and
ending values of the samples and/or lines into the appropriate text boxes, or
enter the desired number of lines or pixels in the boxes labeled “NS” or “NL”
respectively.
The size of the original data set and the size of the currently-selected subset
appear below the text boxes.
Subsetting by Images
To select the spatial subset interactively from the image:
1. In the Select Spatial Subset dialog, click on the “Image” button.
The Subset Function dialog appears. A subsampled version of the selected
image band is displayed (Figure 1-8). A box on the image outlines the
currently selected subset.
2. To change the subset size or location, select from the following options:
• In the Subset Function Dialog, click and grab on one of the corners of the
box and drag to the desired location.
• To move the box around the image, click on the box and drag it to the
desired location.
• Change the values in the “Samples” or “Lines” text boxes.
3. Click “OK.”
The starting and ending sample and line coordinates appear in the text boxes
labeled “Samples” and “Lines.”
Subsetting by Map Coordinates
For georeferenced images, you may select the subset by map coordinates or
latitude/longitude coordinates:
1. In the Select Spatial Subset dialog, click on the “Map” button.
The Spatial Subset By Map Coordinates dialog appears. It is divided into two
sections: one for the upper left map coordinate and the other for the lower right
coordinate.
2. Enter the upper left coordinate and lower right coordinate (the corners) of the
subset into the corresponding text boxes.
Note
The default values displayed are the upper left and lower right coordinates of the
full image.
3. Use the arrow toggle buttons to select the subset by latitude and longitude
values for each coordinate.
• To change the map projection of the coordinates, click on the
corresponding “Change Proj” button and follow the instructions in
“Selecting Map Projection Types” on page 757.
4. Click “OK.”
Figure 1-10: In the Subset Image by ROI Extent dialog, select the ROI(s) to use
as the area of a spatial subset.
2. In the Subset Image by ROI Extent dialog, select the ROI(s) and click “OK.”
The file will be subset to the area encompassing the selected ROI(s).
Selecting a Spectral Subset
Use spectral subsetting to limit application of a function to selected bands of an
image. For subsetting by spatial regions instead of spectral bands, see “Selecting a
Spatial Subset” on page 45.
1. From within the file selection dialog, click the “Spectral Subset” button.
The File Spectral Subset dialog appears. The appearance of this dialog varies
depending on whether the image has a bad bands list. A bad band will not be
included in the processing (Figure 1-11).
A list of bands available for selection appear in the center of the dialog.
2. Select a spectral subset using one of the following methods:
• Use the mouse to select a series of bands by left-clicking and dragging
across the desired bands. Select multiple, non-adjacent bands by left-
clicking on individual bands while depressing the Ctrl key.
• Enter the min and max band numbers in the text fields to the left of the
“Add Range” button to select a series of bands. The series will be selected
when you click the “Add Range” button.
For images with a “Bad Bands” list, click on the “Apply BBL” button to apply
the Band Bands List (see “Editing Ancillary Header Information” on
page 102). ENVI automatically deselects individual bands that are marked
“Bad.” Bad bands do not appear in the output image.
3. Click “OK” to return to the file selection dialog.
Figure 1-11: The Spectral Subset dialog with three bands selected.
• To select a group of files that are listed consecutively, click on the first file in
the group, press and hold the “shift” key, and click the last file in the group. Or,
click and drag the cursor over the group of items with the left mouse button.
The items are “selected” when they are “highlighted.”
• To select multiple files that are not listed consecutively, press and hold the
“ctrl” key on your keyboard and click on each desired file.
• If the dialog you’re working in displays a “Select All Items” button, click the
button to select all of the items in the list.
De-Selecting Items
• To de-select a single item, hold the “crtl” key down and click on the item.
• If the dialog you’re working in displays a “Clear All Items” or “Clear” button,
click it to de-select all of the items in the list.
Figure 1-12: In the list on the left, you can select only one item. In the list on the
right, you can select multiple items.
Figure 1-13: Select output to “File” or “Memory” (top). If you click “Choose,” the
Output Filename window appears.(bottom).
The dialog closes, the parameters are saved, and the function can be executed later
from the ENVI Queue Manager.
Note
If you exit ENVI without executing the queued functions, a warning will appear.
Compressing Output
Use the “Compress” check box to compress your output. ENVI applies a lossless
GZIP format compression to the output file. When a compressed file is opened in
ENVI, ENVI reads the file and uncompresses it on-the-fly.
Warning
Be aware that ENVI cannot read compressed files that are larger than two
gigabytes. If you compress a large file and it remains larger than two gigabytes
when compressed, you will not be able to read it with ENVI.
text header file provides information to ENVI about the dimensions of the image, the
imbedded header if present, the data format, and other pertinent information. The
required information is entered interactively or is automatically created with file
ingest, and can be edited and changed later. You can generate an ENVI header outside
ENVI by using a text editor (see “ENVI Header Format” on page 879).
• FAST • MRLC
• GeoTIFF • ACRES CCRS
• HDF • ESA CEOS
• NLAPS
SPOT Files
IKONOS Files
• GeoTIFF
• NITF
AVHRR
• KLM/Level 1b
• SHARP
SeaWiFS Files
• HDF
• CEOS
EOS Files
• ASTER 1A/1B
• MODIS 1B
Radar Files
• RADARSAT • JERS
• ERS • TOPSAR
• AIRSAR
Military Files
• ADRG • CIB
• CADRG • NITF
Thermal Files
• TIMS
• MASTER
USGS and Digital Elevation Files
Miscellaneous Formats
Generic Formats
• ASCII • PICT
• BMP • SRF
• HDF • TIFF/GeoTIFF
• JPEG • TIFF world files (.tfw)
• MrSID • XWD
• PDS
Note
ENVI supports the following input TIFF compression formats: CCITT Group 3 & 4
algorithms, Macintosh PackBits algorithm, THunderScan 4-bit RLE algorithm,
NeXT 2-bit RLE algorithm, and LogLuv high dynamic range encoding.
Vector Files:
• ASCII • SRF
• BMP • TIFF (GeoTIFF)
• HDF • TIFF world files (.tfw)
• JPEG • XWD
• PICT
Vector Formats
Use the Header Info dialog to enter the number of samples or pixels, the number of
lines, the number of bands, the offset in bytes from the start of the file to where the
data begins, the storage order of the data, the byte order of the data, the data type and
the file type. The offset is typically used to define the size of the embedded header,
which, if present, contains external information about the file and is usually found
before the actual image data begins; the storage order of the data is the interleave,
which is in the format BSQ, BIP, or BIL; the byte order of the data is in the format
Host (Intel) (Host Least Significant First) for DEC machines and PCs or Network
(IEEE) (Network Most Significant First) for all other platforms); the data type is in
the format byte, integer, floating point, etc.
All additional information stored in the ENVI Header is optional. To access this
optional information, click the “Edit Attributes” button in the Header Info dialog.
This optional information includes setting the default Z-Plot range, default stretch for
display, entering georeferencing information, associated wavelengths and associated
FWHM (full-width-half-maximum) values, sensor type, band names, and bad bands.
For more information, see “Editing ENVI Headers” on page 99.
Note
If you are opening a file directly from a CD-ROM, the created header file will be
saved to the “Alternate Header Directory” specified in the envi .cfg file because you
cannot write to the CD-ROM input directory (see “Installing and Customizing
ENVI” on page 859).
1. Select File > Open External File > the desired format.
2. When the standard file selection dialog appears (see “Selecting Files in ENVI”
on page 42), select a filename and click “Open.”
• To select a group of files that are listed consecutively, click on the first file
in the group, press and hold the “shift” key, and click the last file in the
group. Or, click and drag with the left mouse button to select the desired
group.
• To select multiple files that are not listed consecutively, press and hold the
“ctrl” key on your keyboard and click on each desired file.
3. If ENVI prompts you to enter Output Filename, enter a name for each file as
requested.
See the following sections for detailed descriptions of how to access specific file
formats.
1. Select File > Open External File > Landsat > ACRES CCRS.
2. When the file selection dialog appears, select the Imag_xx.dat file.
ENVI automatically extracts the header information, including UTM georeferencing
information, and enters the image bands into the Available Bands List.
Opening ESA CEOS Landsat TM Files
To read European Space Agency Landsat TM format data:
1. Select File > Open External File > Landsat > ESA CEOS.
2. When the file selection dialog appears, select the input data file.
The files must follow the naming convention of dat_xx.xxx and lea_xx.xxx.
ENVI automatically extracts the necessary header information, including any UTM
georeferencing information, and lists all of the bands in the Available Bands List.
ENVI also creates a meta file—a single file containing all of the bands of a BSQ
formatted file—and lists it in the Available Bands List. ENVI assigns wavelengths to
the bands based on the sensor type. For information about meta files, see “Saving
Files as ENVI Meta Files” on page 119.
ENVI automatically extracts the header information and enters the image bands into
the Available Bands List.
Note
Complex RADARSAT data are read into ENVI as follows: Raw data product - two
bands of byte data, one each for the Z and I Stokes parameters; SLC data product -
two bands of signed integer, one each for the Q and I Stokes parameters.
Note
Each frame file may be made up of hundreds of individual files that appear in the
Available Bands List.
Converting generic image files to ENVI format is limited to images that fit entirely
into system memory with the exception of TIFF, HDF, and BMP format images.
The band(s) from the converted file are listed in the Available Bands List.
1. From the ENVI main menu, select File > Open External File > Generic
Formats > MrSID, or select File > Open Image File.
2. When the standard ENVI file selections dialog appears, select the MrSID
compressed file to be read.
ENVI automatically extracts the needed header information, including any
georeferencing information, and places the image bands in the Available Bands List.
Opening ASCII Files as Image Files
Use Generic Formats to open an ASCII file as an image. Each ASCII value is read as
a pixel DN value. The ASCII values must be separated by white spaces or commas.
Lines at the top of the file that have non-numeric characters or that start with a
semicolon are skipped. The image data in the file must be in the format of an image
array. The number of samples is determined by the number of values in a line, and the
number of lines is determined by the number of lines in the file.
1. Select File > Open External File > Generic Formats > ASCII.
2. When the standard file selection dialog appears, select an ASCII file to input.
The number of samples and lines (columns and rows) are automatically
determined.
3. When the Input ASCII File dialog appears, select BSQ, BIL, or BIP from the
“Interleave” button menu.
4. From the “Data Type” button menu, select the correct data type.
5. Enter or select the number of input bands by using the arrow buttons next to
the “Number of Bands” label or by typing a number into the box.
6. Click “OK.”
The bands are read into memory and entered into the Available Bands List.
Opening TIFF Files
ENVI supports the following TIFF files: TIFF world files (.tfw), GeoTIFF, 1-bit, 4-
bit, 8-bit, 16-bit signed and unsigned integer, 24-bit, 32-bit signed and unsigned long
integer, and 32-bit floating point.
1. Select File > Open External File > Generic Formats > TIFF/GeoTIFF.
2. When the standard file selection dialog appears, select a TIFF file to input.
• If you have a .tfw associated with your TIFF file, follow these additional
steps.
A. When the TIFF World File Input Projection dialog appears, select the
desired input projection and enter the zone number, if needed (see
“Selecting Map Projection Types” on page 757).
B. Click “OK.”
Note
If you have a GeoTIFF file and a TIFF world file, all projection information will be
read directly from the GeoTIFF file.
If you select “File” output, ENVI saves the file in ENVI vector file format.
Tip
You may mix “File” and “Memory” outputs when working with different layers.
5. Assign the input projection type for each layer by highlighting the filename
and selecting the projection of the data from the “Output Projection” list.
6. Click “OK” to start the conversion.
A status window appears. When ENVI has completed the conversion process, each
converted file appears as a layer in the Available Vectors List (“The Available
Vectors List” on page 196).
4. For each file within the list, highlight the file name and select either “File” or
“Memory” output.
If you select “File” output, ENVI saves the file in ENVI vector file format.
Tip
You may mix “File” and “Memory” outputs when working with different layers.
5. Assign the input projection type for each layer by highlighting the filename
and selecting the projection of the data from the “Output Projection” list.
6. Click “OK” to start the conversion.
When ENVI has completed the conversion process, each converted file appears as a
layer in the Available Vectors List (see “The Available Vectors List” on page 196).
5. Assign the input projection type for each layer by highlighting the filename
and selecting the projection of the data in the “Output Projection” list.
6. Click “OK” to start the conversion.
A status window appears indicating the processing status. When the conversion
process is complete, each converted file appears as a layer in the Available Vectors
List (see “The Available Vectors List” on page 196).
Tip
The files are also accessible from the Main Window of the display (see “Overlaying
Vectors” on page 295).
5. Assign the input projection type for each layer by highlighting the filename
and selecting the projection of the data in the “Output Projection” list.
6. Enter the correct DGN scale factor for your file to convert the vectors to the
proper projection scale.
Use degrees for Geographic projection and meters or feet for all other types.
7. Click “OK” to start the conversion.
A status window appears. When ENVI has completed the conversion process, each
converted file appears as a single ENVI vector layer in the Available Vectors List
(see “The Available Vectors List” on page 196).
Note
Whenever you read in DLG or DXF files and select output to file, .evf files are
automatically created.
1. Select File > Open Vector File > ENVI Vector File (.evf).
2. When the standard file selection dialog appears, select a file to be read.
The individual layer for the selected file is automatically loaded into the Available
Vectors List (see “The Available Vectors List” on page 196).
The file names under the Open Previous File menu item are stored in a user-selected
ASCII file (see “Setting ENVI Preferences” on page 160). The format of this file is
described in “ENVI Previous Files List” on page 891.
• To open a file from the previous files list, select File > Open Previous File >
desired file name.
The filename is listed in the Available Bands List.
To save an image file as and ENVI format file, see “Saving Files as Standard ENVI
Files” on page 117.
• The “xstart” and “ystart” fields define the image coordinates for the upper
left hand pixel in the image. Images that are spatial subsets of larger images
will often use an image coordinate system that references the parent
(or larger) image so that the two can be linked and dynamically overlaid.
The default values are (1,1) so that the upper left hand pixel has an image
coordinate of (1,1).
Note
Changing the value of “xstart” or “ystart” does not affect the way ENVI
reads the image data from the file.
• Use the “Data Type” pulldown menu to select the appropriate data type (byte,
integer, unsigned integer, long integer, unsigned long integer, floating point,
double precision, 64-bit integer and unsigned 64-bit integer, complex, or
double complex).
• Use the “Byte Order” pulldown menu to select the byte order of the data. This
parameter varies by platform:
• For DEC machines and PC’s, select “Host (Intel)”: Host Least Significant
First.
• For all other platforms, select “Network (IEEE)”: Network Most
Significant First.
• Use the “Interleave” menu to select the data storage order from these choices:
• “BSQ” (Band Sequential).
• “BIL” (Band Interleaved by Line).
• “BIP” (Band Interleaved by Pixel).
• Use the white field at the bottom of the Header Info dialog to insert string text
that describes the data file.
Selecting File Types
ENVI uses the “File Type” header field to automatically identify certain types of data
files. In the Header Info dialog, use the “File Type” field to identify the native file
type of the file that the ENVI header belongs to. The file will have an ENVI Header,
but will still exist in its native format. The ENVI header file can be used to add
ancillary information (i.e., wavelengths) that is used in ENVI.
• From the “File Type” button menu, select a file type.
Tip
For a complete list of all file types recognized by ENVI, see the filetype.txt
file that comes in the menu directory of each ENVI release. You may edit this file
and add new user-defined file types (see Chapter 7, “Custom File Input” in the
ENVI Programmer’s Guide).
The file types include ENVI-specific file types such as meta files, classification files,
virtual mosaics, spectral libraries, and FFT results. The file types also encompass
data-specific formats such as NLAPS, RadarSat, Spot, etc. TIFF, BMP, ERDAS 8.x
and PCI files are also recognized.
Figure 2-5: The Edit Bad Bands List values and Edit Band Name values Dialogs.
The Input ASCII File dialog appears with first few values from the ASCII file
listed.
3. In the “Wavelength Column” text box, enter the number of the ASCII column
that contains the wavelengths.
• To scale the wavelength values on-the-fly, enter a multiplicative scale
factor in the “Multiply Factor” text box.
For example, multiply the imported wavelength values by 100, enter
“100.”
4. In the “FWHM Column” text box, enter the number of the ASCII column that
contains the band width information (used in spectral resampling).
The ASCII file can also contain a Bad Bands List column. The Bad Bands List
column specifies a good band with a “1” and bad band with a “0.”
5. Enter the number of the ASCII column that contains the Bad Bands List.
6. Click “OK.”
7. Click “OK” in the Header Info dialog to write all of the changes to the
header file.
1. From the Header Info dialog, select Edit Attributes > Map Info.
2. In the Map Information dialog, enter the reference pixel coordinates in the
“Image Coord X” and “Y” text boxes and the pixel size in the “Pixel Size X”
and “Y” text boxes. Be sure to enter the pixel size in the units appropriate for
your selected projection.
• If north is not “up” in the image, enter a rotation angle in degrees in the
“Map Rotation” text box. Measure the angle in a clockwise direction
where zero degrees is straight up (see “Overlaying Grid Lines” on
page 258).
3. Select the map projection by clicking on “Change Projection” and selecting the
appropriate projection from the list of projections (see “Selecting Map
Projection Types” on page 757).
4. Enter the coordinates of the reference pixel in the appropriate text boxes.
The corresponding latitude and longitude will be automatically calculated and
can be viewed by clicking on the arrow toggle button to “Geographic
Coordinates.”
5. Click “OK” to return to the Header Info window.
Entering Geographic Information for Non-Georeferenced Files
If your file is not georeferenced but does include geographic information, use this
procedure to place that information in the ENVI header file. Currently, ENVI uses
the first geographic point to place a flag on the geo-browser showing the location of
the file (see “Opening Files with the Geo-Browser” on page 155). The other points
remain in the header for your information only (image georeferencing is defined
using the “MapInfo” field).
1. From the Header Info dialog, select Edit Attributes > Geographic Corners.
2. Enter between one and four pixel locations and their corresponding latitudes
and longitudes.
Note
In ENVI, pixel values always refer to the upper left corner of the pixel. Map
coordinates also typically refer to the upper left corner of the pixel. However, if you
want the map coordinate to reference the middle of the pixel, add 0.5 to the image
coordinate of the reference pixel specified in the “Map Info” field of the header
(e.g., x=1.5, y=1.5 would make the map coordinates refer to the center of the pixel).
2. Enter the number of classes in the Classification Info dialog and click “OK.”
3. When the Class Color Map Editing dialog appears, click on the class name of
the region to be changed from the list “Selected Classes.”
• To change a selected class name, edit it in the “Class Name” text field.
• To change the class color in the RGB color space (0-255 for the three
colors), move the three sliders labeled “Red,” “Green,” or “Blue.”
• To reset the original class colors and names, click “Reset.”
• To change the class colors in the HSV or HLS color spaces:
A. From the “System” pulldown menu in the Class Color Map Editing dialog,
select the appropriate system.
B. Move the “Hue, Saturation, Value” or “Hue, Lightness, Saturation” sliders
to the desired values.
4. To make the changes permanent, click “OK.”
Note
On 24-bit color displays, ENVI does not automatically apply the color changes.
Instead, for 24-bit hardware, apply color changes to the image by clicking on the
“Apply Changes” button, which appears only when 24-bit color is available.
• To set the axes titles, enter the desired axes titles into the “X Axis Title”
and “Y Axis Title” text boxes.
• To specify the size (in pixels) of the box used to calculate an average
spectrum, enter the parameters into the “Z Plot Average Box” fields.
• To specify an additional file name from which to extract Z profiles:
A. Click on “Default Additional Z Profiles.”
B. When the Default Additional Z Profiles dialog appears, click on “Add
New File.”
C. Select the desired file name and click “OK.” The file name will appear in
the list.
• To remove a file name from the list, click on the file name and click on
“Remove Selected File.”
Note
If the Default Stretch is set to “None,” use the Default Stretch set in the ENVI
Configuration File (envi.cfg).
• To evaluate swapping of bytes between Intel and IEEE formats for data
types with more than one byte per value (integer, long integer, and floating
point), select from the Byte_Swap menu: None (no swapping), Short Word
(swapping two bytes for an integer), or Long Word (swapping byte pairs
for long integer and floating point data).
Saving Files
Use Save File As to create a new “standard” ENVI disk file or an ENVI “Meta File”
from bands contained in the Available Bands List and to output image data to various
image processing formats. You can output your data to image processing formats
such as ArcView Raster (.bil), PCI (.pix), ER Mapper, and ERDAS (.lan) and
TIFF files (including GeoTIFF and TIFF world files [.tfw]). In addition, you can
output your image to an ASCII (.txt) file.
Note
New files can only be created from bands that have the same spatial dimensions.
Use ENVI’s integral subsetting capabilities to choose individual bands and to
perform on-the-fly subsetting of files to the correct dimensions. For instructions,
see “Selecting a Spatial Subset” on page 45 and “Selecting a Spectral Subset” on
page 50.
5. Repeat the file selection using the “Import ENVI File” button for each input
file to be included in the new file.
Input files are listed in the “Selected ENVI Files for New File” list.
• To delete a file from the list in the New File Builder dialog, click on the
filename and click “Delete.”
• To change the order in which the files and/or bands are imported, see
“Reordering Files”.
6. Select output to “File” or “Memory.”
7. Click “OK” to build the new file.
The file will be output as a band sequential (BSQ) format.
Reordering Files
1. In the New File Builder dialog, click the “Reorder Files” button.
The Reorder Files dialog appears.
2. Click on a filename or bandname and drag it to the desired position in the list.
3. Repeat for as many filenames or bandnames as needed.
4. Click “OK.”
Removing Superfluous Files
When you create a standard file, use this procedure to remove the bands used to
create it.
• To remove the component files, use the arrow toggle button to select “Yes”
(remove files), or “No,” next to the text label “Remove Superfluous Files?”
Warning
This function physically removes the files from the Available Bands List and the
disk:
If memory items are to be transferred to the new file and “Remove Superfluous
Files” is selected, they are deleted from memory when the new file is created.
If all of the bands from a disk file are to be transferred to the new file and “Remove
Superfluous Files” is selected, the original disk file is physically deleted from the
disk when the new file (either memory or disk file) is created.
2. When the New File Builder dialog appears, click “Import File.”
The Create New File Input File dialog appears.
3. Select files by clicking on the file name(s).
• If the file to be included is not listed, click “Open File” and select the
desired input file.
Tip
You can spatially or spectrally subset a group of files if they are the same size. The
subset will be applied to each file.
2. When the Output PCI Input Filename dialog appears, select the input file and
perform any subsetting.
3. When the Output File to PCI dialog appears, enter an output filename and click
“OK.”
ENVI creates a .pix PCI output file.
Figure 2-12: In the new Export Variable Name dialog, enter an undefined IDL
variable name or select a previously defined variable.
The exported data will be available to use at the ENVI command line.
You can change the settings for how ENVI will use IDL’s thread pool during an
ENVI session by selecting File > IDL CPU Parameters. The “IDL CPU Parameters”
dialog displays.
• Thread Pool number of Processors — The number of threads that IDL will
use in thread pool computations. The default value is equal to the value of the
number of CPUs on your system, so that each thread will have the potential to
run in parallel with the others. Note that there is no benefit to using more
threads than your system has CPUs. However, depending on the size of the
problem and the number of other programs running on the system, there may
be a performance advantage to using fewer CPUs.
• Thread Pool Minimum Elements — The number of data elements (each
element being a single data value of a particular data type) in a computation
that are necessary before IDL will use the thread pool. If the number of
elements is less than the number you specify, ENVI will perform the
computation without using the thread pool. Use this parameter to prevent
ENVI from using the thread pool on tasks that are too small to benefit from it.
The default is 100000.
• Thread Pool Maximum Elements — The maximum number of elements in a
computation that will be processed using the thread pool. Computations with
more than this number of elements will not use the IDL thread pool. Set this
parameter if large jobs are causing virtual memory paging on your system.
Setting this value to 0 removes any limit on maximum number of elements.
The default is 0.
Set the Thread Pool Number of Processors, Thread Pool Minimum Elements, and
Thread Pool Maximum Elements and click “OK”.
Note
Changing the multi-threading options using the IDL CPU Parameters dialog will
only change the options for the current session. The settings will not be saved in the
envi.cfg file. For more information on how to change the settings in the
envi.cfg file, see “The ENVI Configuration File” on page 867.
Tape Utilities
Use Tape Utilities (Figure 2-14) to read MSS, TM, SPOT, AVHRR, AVIRIS,
NLAPS, and CEOS format radar data (including SIR-C/X-SAR, RADARSAT and
ERS-1) from a variety of computer compatible tape (CCT) formats and to read U.S.
Geological Survey DEMs and DLGs (Optional Format only). Also, use the tape
utilities to read BSQ, BIP, or BIL data directly from tape and to control SCSI tape
drives (9 track, 8 mm, and 4 mm media) at the file and record levels.
Flexible tape tools are included with the tape utilities for inputting other data types,
even when a specific format is not directly supported. Also included is a special tape
output utility for writing ENVI files to tape, which preserves header information and
file structure. A corresponding tape input utility is also available for reading ENVI
formatted tapes. Use the tape scan and dump utilities to diagnose tape structures,
build scripts for commonly used tape types, and dump tapes to disk.
Note
Tape functions are supported on UNIX, Microsoft Windows 95, Windows 98,
Windows 2000, and Windows NT platforms.
On UNIX Platforms
The tape devices on UNIX platforms are specified as the name of the tape device in
the /dev directory. For example, to specify device Øb in the /dev/rmt directory,
use the name /dev/rmt/Øb as the ENVI “Tape Device.”
3. In the “File” text box, enter the file number to retrieve from the tape.
4. Click “OK” to scan the tape header.
If AVHRR format data are identified, the AVHRR Tape Output Parameters
dialog appears and the bands available on tape are listed.
• To subset the image being read from tape, enter the starting and ending
lines and/or samples in the text boxes labeled “Samples... To” and/or
“Lines...To” respectively.
5. Select bands to be read by clicking on the toggle buttons next to the desired
band names.
• To designate a range of bands, enter the beginning and ending band
numbers in the text boxes next to the “Add Range” button. Click “Add
Range.”
6. Select output to “File” or to “Memory.”
Tip
File output is recommended.
Note
File output is recommended.
1. Select File > Tape Utilities > Read Known Tape Formats > AVIRIS.
The AVIRIS - Load Tape dialog appears.
2. Select from the following options:
• To designate a different tape device, enter or choose a device.
• To change the tape record size, enter the values into the “MaxRecsize” text
box(es).
Tip
If you designate a different tape device, allow your operating system enough time to
register the new device before proceeding.
3. Click “OK” to have ENVI read the AVIRIS wavelength file and scan the
AVIRIS image header.
• If the data are identified as AVIRIS data, the AVIRIS Tape Output Parameters
dialog appears.
• To subset the image being read from tape, enter the starting and ending
lines and/or samples in the text boxes labeled “Samples... To” and/or
“Lines...To” respectively.
4. Click “OK.”
The USGS DEM Format - Load Tape Dialog appears.
5. Select from the following options:
• To designate a different tape device, enter or choose a device.
• To change the tape record size, enter the values into the “MaxRecsize” text
box(es).
Tip
If you designate a different tape device, allow your operating system enough time to
register the new device before proceeding.
Each individual output file is assigned the root name with the file number
appended. For example, if you enter the root filename test, then file two will
be named test_2.
4. Click “OK” to continue.
The USGS DLG Format - Load Tape dialog appears.
5. Select from the following options:
• To designate a different tape device, enter or choose a device.
• To change the tape record size, enter the values into the “MaxRecsize” text
box(es).
Tip
If you designate a different tape device, allow your operating system enough time to
register the new device before proceeding.
Tip
If you designate a different tape device, allow your operating system enough time to
register the new device before proceeding.
1. Select File > Tape Utilities > Read Known Tape Formats > SIR-C CEOS.
3. Click “OK” to have ENVI scan the tape for standard format SIR-C data.
When the tape scan is completed, the SIR-C Tape File Selection dialog
appears. A list of the SIR-C data files on the tape appears in the “Select Output
Files” list.
4. Click on the box next to the desired data set(s) to choose the data to be read
from the tape.
• To designate a range of data, enter the beginning and ending numbers in
the text boxes next to the “Add Range” button. Click “Add Range.”
5. Click “OK.”
3. Click “OK” to have ENVI scan the tape for standard format RADARSAT data.
When the tape scan is completed, the RADARSAT Tape File Selection dialog
appears. A list of the RADARSAT data files on the tape appear in the “Select
Output Files” list.
4. Click on the box next to the data set(s) to be read from the tape.
• To designate a range of files, enter the beginning and ending numbers in
the text boxes next to the “Add Range” button. Click “Add Range.”
5. Click “OK.”
The RADARSAT Tape Parameters dialog appears. The RADARSAT data sets
that were selected in the RADARSAT Tape File Selection dialog are listed in
the “Selected RADARSAT Tape Files” list.
information, see “Scanning Tapes and Customizing Dumps” on page 150, Chapter
13, “Radar Tools”.
Tip
To conserve disk space, subset the data directly from tape.
1. Select File > Tape Utilities > Read Known Tape Formats > Read Generic
CEOS.
The CEOS Format - Load Tape dialog appears.
2. Select from the following options:
• To designate a different tape device, enter or choose a device.
• To change the tape record size, enter the values into the “MaxRecsize” text
box(es).
Tip
If you designate a different tape device, allow your operating system enough time to
register the new device before proceeding.
3. Click “OK” to have ENVI scan the tape for standard format CEOS data.
When the tape scan is completed, the CEOS Tape File Selection dialog
appears. The CEOS-format data files on the tape appear in the “Select Output
Files” list.
4. Click on the box next to the desired data set(s) to be read from the tape.
• To designate a range files, enter the beginning and ending numbers in the
text boxes next to the “Add Range” button. Click “Add Range.”
5. Click “OK.”
The CEOS Tape Parameters dialog appears.The CEOS data sets that were selected in
the CEOS Tape File Selection dialog appear in the “Selected CEOS Tape Files” list.
CEOS Tape Options
Use the CEOS Tape Parameters dialog to select spatial subsetting from tape and to
assign output file names. Each data set will be independently named and processed.
Subsetting CEOS Data
1. In the CEOS Tape Parameters dialog, click on a data set name.
2. Click the “Spatial Subset” button.
3. Use standard ENVI spatial subsetting to subset the data. For instructions,
see “Selecting a Spatial Subset” on page 45.
4. Repeat steps 1 through 3 for each data set listed in the dialog.
5. Click “OK” to return to the CEOS Tape Parameters dialog.
Entering CEOS Output Filenames
1. In the CEOS Tape Parameters dialog, click on a data set name in the “Selected
CEOS Tape Files” list.
2. In the text box labeled “Enter Output Filename,” enter a filename.
3. Repeat steps 1 and 2 for each data set listed in the dialog.
One image output file is created for each data set selected.
4. Click “OK” to begin reading the tape and processing the data.
The processed images appear in the Available Bands List and can be displayed and
processed using standard ENVI procedures.
Data
File ID Rec ID Information
Type
Data
File ID Rec ID Information
Type
6. Click “Accept.”
The ENVI Format - Load Tape window appears.
7. Select from the following options:
• To designate a different tape device, enter or choose a device.
• To change the tape record size, enter the values into the “MaxRecsize” text
box(es).
Tip
If you designate a different tape device, allow your operating system enough time to
register the new device before proceeding.
8. Click “OK” to have ENVI sequentially output the selected files to tape in
standard ENVI tape format.
A status window lists the progress as each file is written. The tape is rewound at the
end of the processing.
2. In the ENVI Tape Dump Utility window, select Options > Scan Tape.
The ENVI Tape Information Scan window appears as the tape is scanned and
the current file number and the total number of bytes scanned on the tape are
listed.
As each file is completed, the tape information is shown in the ENVI Tape
Dump Utility dialog.
• To interrupt the tape scan at any time, click “Interrupt Tape Scan” at the
bottom of the window (the interrupt may take a few seconds to register
with the system).
If the tape scan is interrupted, the information up to that point is shown and
the tape is automatically rewound. In either case, the file number, the
number of records, and the number of bytes per record are listed.
3. In the ENVI Tape Dump Utility dialog, select from the following options to
select records and bytes and to edit their values:
• To edit values, click on an item in the list. Change the values as they
appear in the corresponding text boxes and press the <Return> key.
This allows combining files/records and selecting subsets of bytes to be
read.
• To add new items to the dump list, enter new values in the text boxes and
click the “Add Entry” button.
• To delete an entry from the list, click on the entry in the list and click
“Delete Entry.”
• To clear the list, select “Clear Entries.”
• To recall data from the previous scan, select Options > Restore Prev Scan.
• To save the Tape Script to an ASCII text file, select File > Save Format
and enter the desired filename.
The default file extension is .fmt. (See “Tape Script Format (.fmt)” on
page 893).
• To recall previously saved Tape Scripts, select File > Restore Format and
select the desired file.
4. In the ENVI Tape Dump Utility dialog, select Options > Dump Tape to read
the tape.
The Tape Dump Output Parameters dialog appears.
5. Use the arrow toggle button to select either “Dump tape records to a single
output file” or “Dump each item to a separate output file.”
6. Enter an output filename and click “OK.”
If separate output files is selected, the output filename entered will be used as a
base filename and the file number that is dumped is appended to the base
filename. For example, if a filename of “test” is entered and files 2 and 3 are
dumped, they will be output as “test_2” and “test_3.”
As the tape is dumped, the status is displayed in the ENVI Dump Tape to
Output File window.
• To interrupt the tape dump, click “Interrupt Tape Dump.”
Tip
If you designate a different tape device, allow your operating system enough time to
register the new device before proceeding.
Note
If a header does not match its ENVI file, ENVI displays a warning message. The
Header Info dialog appears so that you may enter the correct information.
Removing Files
• To remove a single file from the list:
1. Click on a file name.
2. Select File > Remove File.
• To remove all files from the list:
1. Click on a file name.
2. Select File > Remove All Files.
Adding New Directories
• To add a new directory and allow yourself to select files from within that
directory, select Options > Scan New Directory List.
The Directory Scan dialog appears.
Opening Files with the Geo-Browser
Use Geo Browser to scan files and open them based on their geographic location.
ENVI’s Geo-Browser allows map browsing of the locations of georeferenced images.
1. From within the Scanned ENVI Files dialog, select Options > Geo-Browser.
ENVI plots a world map with continent and country outlines. Within the
United States, state outlines also appear.
The locations of georeferenced images (the location of the reference pixel
designated in the ENVI header) are plotted on the world map as flags. For
multiple files with the same location, ENVI plots a different colored flag, with
a number next to it showing the number of files at that location.
Note
The mouse cursor’s latitude and longitude appear in the upper left corner of the
map.
• To identify the file corresponding to a flag, click the right mouse button
near a flag.
ENVI highlights the corresponding file in the Located Files List.
For sites with multiple files, click the right mouse button multiple times to
highlight each corresponding file.
3. After you have selected a file by highlighting it, select File > Open File to
open it.
1. Ensure that all of the files needed to run the queued function(s) are opened and
are listed in the Available Bands List.
2. From the ENVI main menu, select File > ENVI Queue Manager.
The ENVI Queue Manager dialog displays a list of all queued functions.
2. Click “Yes.”
• To change the color, select a color system from the button menu and use
the slider bars to adjust the variables.
Warning
It is not advised to change any of the first 5 colors (black, white, red, green, blue)
because they are used in the ENVI system. Changing graphic colors may affect
previously saved graphic overlays.
1. To ensure that all colors will be available, close all display and plot windows.
2. In the Edit System Preferences window, click the “System Color Tables”
button.
The ENVI Color Table Editor dialog appears. The current color table is
displayed as a narrow gradiated color table on the left side of the dialog. A
white “positioning arrow” appears at the far left and right corners of the color
table. The current system colors are displayed in the “Color Palette Selection”
widget (see Figure 2-23).
3. Select a color system from the button menu next to the “System” label.
The color palette reflects the system change.
4. Select from the following options when defining the color table.
• To keep one color or element constant (i.e., red in RGB or lightness in
HLS), click on the toggle button next to the slider bar of that value.
The two remaining colors represent the horizontal and vertical axes of the
color palette.
• To move points on the interpolation line, click on a point on the line with
the left mouse button and drag to the new position.
• To add points to the interpolation path through the colors, click on a
position in the color palette with the middle mouse button.
• To remove points from the interpolation line, click the right mouse button
on the square interpolation points.
• To designate whether the color table automatically reflects the changes
made as you move the interpolation line, select “On” or “Off” using the
“Update Color Table” arrow toggle button.
• To see the values of a specific color, click on the color with the left mouse
button.
The circle cursor jumps to that location on the palette and the slider bars
show the new values.
• To identify the color represented by a combination of values, move
the slider bars of the values or use the arrow increment buttons to
change them.
The circle cursor moves to the corresponding location on the color palette.
6. Click the “Interp” button to fill in the colors between the new values.
• Click “Reset” to reset the color table to a gray scale image.
• To clear the positioning arrows, click “Clear.”
Adding Color Tables to ENVI
To add the new color table to the current list of ENVI color tables:
1. In the ENVI Color Table Editor, click “Add Current as New Color Table.”
2. When the Add Color Table dialog appears, enter a name into the text box and
click “OK.”
Note
If you do not have permission to write to the colors1.tbl file, you will be
prompted to enter a new color table filename.
If the ENVI Window Finder is lost behind another window, select Window >
Window Finder to bring it to the front again.
• To display a list of all the currently open image files, select Window >
Available Files List.
If the file is a memory item, it is removed from memory and any associated displays
are closed.
Figure 3-4: The Available Bands List: The dialog on the left shows a Gray Scale
band ready to load into a display. The dialog on the right shows RGB bands
ready to load.
Figure 3-5: The Available Bands List shortcut menu, accessed by right-clicking
in the file list.
1. In the Available Bands List, select the “Gray Scale” toggle button.
2. Click on the input band name.
The band name appears in a small text box labeled “Selected Band.”
• If necessary, change the active display (see “Selecting the Active Display”
on page 177).
3. Click “Load Band” to load the band into the active display.
Tip
You can also load the grayscale image by double-clicking the bandname.
1. In the Available Bands List, select the “RGB Color” toggle button.
2. Click in sequence on the red, green, and blue bands to be displayed (or on
individual R, G, or B bands using the toggle buttons).
• If necessary, change the active display (see “Selecting the Active Display”
on page 177).
3. Once the band names have been loaded into the text boxes labeled “R,” “G,”
and “B,” click the “Load RGB” button to load the bands into the current active
image display (see “Selecting the Active Display” on page 177).
Tip
You can also load the image by double-clicking the blue bandname in the list of
available bands, or by using the shortcut menu (see “Available Bands List Shortcut
Menu” on page 177).
• To cancel loading the bands into a display, click the “Cancel” button in the
status window.
The display window will be blank.
After the bands are successfully loaded, a Main Image window, Zoom window, and
Scroll window (for large images) appears. ENVI displays all images with a
default 2% linear stretch. You may change the default stretch in the envi.cfg
file (see “The ENVI Configuration File” on page 867), or by setting a default stretch
in the image header file.
Displaying True Color or Color Infrared Images
If a file has wavelengths in micrometers (µm) and it has bands in the needed
wavelength ranges, you can automatically display a true color image or a color
infrared image directly from the Available Bands List without having to designate the
individual bands for red, green, and blue.
Note
If your data does not have bands of the needed wavelengths, the bands nearest to the
wavelengths will be used. This may produce a gray scale image if red, green, and
blue are set to the same band.
The true color image is made by displaying the band in the red wavelength region
(0.6-0.7 µm) in red, the band in the green region (0.5-0.6 µm) in green, and the band
in the blue region (0.4-0.5 µm) in blue. The color infrared (CIR) image is made by
displaying the band in the near infrared wavelength region (0.76-0.9 µm) in red, the
band in the red region in green, and the band in the green region in blue.
• To automatically display a true color or color infrared image in the current
display window, select a band in the Available Bands List and right-click.
Select Load True Color to <current> or Load CIR to <current> from the
shortcut menu.
• To automatically display a true color or color infrared image in a new display
window, select a band in the Available Bands List and right-click. Select Load
True Color to <new> or Load CIR to <new> from the shortcut menu.
All of the bands of the data set are compressed and the data set appears in the
list in this format:
+<filename>[number of bands] (See Figure 3-6.)
• To “unfold” a data set and make it available for display, simply click the
folded filename.
Folding all Data Sets
• In the Available Bands List, select Options > Fold All Files, or right-click and
use the shortcut menu.
All of the bands of all of the data sets are compressed and each data set appears
in the list in this format: +<filename>[number of bands].
• To unfold a data set, click on the folded filename.
• To unfold all data sets, right click in the list of files and select Unfold All
Files from the shortcut menu.
Figure 3-6: The Available Bands List with the 6 bands of the bhtmref.img data
“folded” into one line.
Figure 3-7: This Main Image window belongs to display number 1. The Zoom
Window Indicator (white box outline) is in the upper right corner.
Scroll bars are not displayed.
Left Button • Click inside the Zoom window indicator and drag it to a
new location. The Zoom window updates when the button
is released.
• Click to center the Zoom window indicator over the current
pixel position. Continue to hold the button and drag to
continuously update the Zoom window.
• Double-click in the Main Image window to display the
Cursor Location/Value dialog.
Middle Button No function.
Right Button Click to display the shortcut menu.
Table 3-1: Functions of the Mouse Buttons in the Main Image window.
Zoom In
Zoom Out Turn Cross Hairs On/Off
Figure 3-8: The ENVI Zoom window with Symbol boxes on. Note the current
zoom factor of 10 is displayed in the window title bar.
• Change the default Zoom window size parameters set in the envi.cfg
configuration file (see Appendix A, “Installing and Customizing ENVI”).
Table 3-2: The Zoom Window Symbol functions with Mouse Button
Descriptions
Figure 3-9: The Scroll window. Note the Main Image window indicator box
(box outline) in the center of the image.
• To control the location of the Main Window Indicator, follow the directions
given in Table 3-4.
• To zoom in the Scroll window, click and drag using the middle mouse button
to draw the meta zoom indicator box around the desired area. This area
replaces the image in the Scroll window.
• To display the original full image in the Scroll window, click the right mouse
button in the Scroll window.
Left Button Click anywhere outside the Main Image window indicator box
in the Scroll window and drag. The Zoom and Main Image
windows update continuously.
Click, drag, and release the Main Window indicator box to
reposition the Main Image. The Zoom and Main Image
windows update when you release the mouse button.
Or:
Click to center the Main Image indicator box and Main Image
display over the selected pixel.
Middle Button Click and drag meta zoom box.
Right Button Click to display the shortcut menu.
• To position the Zoom or Scroll window, click the title bar and drag the window
while holding the left mouse button.
Unhiding
• To show the hidden Zoom and/or Scroll windows, select Window > Show
Zoom Window or Show Scroll Window.
• Right-click in the Image, Zoom or Scroll window and click <Find Display> to
bring up the associated hidden Zoom and/or Scroll window(s).
Note
The Show... menu selections are only available if the corresponding window is
hidden.
• If any image display windows are open, the display names (i.e. Display
#1) appear in the list. Click on the desired display window name to plot the
vectors over the displayed image.
• If any vector windows are open, the vector window names (i.e. Vector
Window #1) appear in the list. Click on the desired vector window name to
plot the vectors in that window.
• To plot the vectors in a new vector window, select “New Vector Window.”
5. Click “OK.”
The Vector Parameters dialog appears with the selected vectors listed (see “The
Vector Parameters Dialog” on page 206).
Note
Changing the projection type does not affect any data points; it only changes the
projection name.
To convert between projections, see the following section. For more map projection
information, see Chapter 10, “Map Tools”.
4. Click the “Maximum Distance” arrow increment buttons to set the maximum
distance to measure, or type the value (in pixels) into the corresponding text
box.
Any pixels with a distance larger than this value will be set to the maximum
distance value +1.
5. From the Distance Kernel button menu, select “Floating Point” or “Integer”
output.
6. Select output to “File” or “Memory.”
7. Click “OK.”
Creating World Boundary Layers
Use Create World Boundaries to create layers of various world boundaries (including
political boundaries, coastlines, rivers, and USA states) from either a high resolution
or a low resolution database.
1. Select Options > Create World Boundaries.
Tip
You can also create world boundaries by selecting Vector > Create World
Boundaries from the ENVI main menu.
coastlines, or the rivers, respectively. The low resolution layers are named
similarly but with an “_lp”, etc. The USA States layer have “_usa” appended
to the root name.
Warning
Building layers from the high resolution database creates very large output files
(~20 MB each).
Opening Files
1. In the Available Vectors List, select File > Open Vector File > vector file type.
2. When the standard file selection dialog appears, select the file (see “Opening
Vector Files” on page 89 for details).
Exporting Vector Layers to a Region of Interest (ROI)
1. In the Available Vectors List, select the vectors to export by clicking on their
names.
2. Select File > Export Layers to ROI.
3. When the Select Data File to Associate with new ROIs dialog appears, select
the data file.
The ROI names are listed in the Region of Interest Controls dialog.
Warning
This can create very large ROIs!
Left Button when Snap to the nearest vector and track map coordinates and
layer is “on” Latitude/Longitude in the Vector Window. (The coordinates
(indicated by an appear listed in the Vector Parameters dialog.)
asterisk [*] next to
the layer name).
Left Button when No snap applied. Independently track map coordinates and
layer is “off” (no Latitude/Longitude in the Vector Window. (The coordinates
asterisk [*] next to appear listed in the Vector Parameters dialog.)
the layer name).
Middle Button. Increase zoom factor by dragging to form a zoom box inside
the window. Decrease zoom factor with single click inside
the window.
Pan the display by clicking at the edge of the window to
center window display around the point.
Right Button Click to display the shortcut menu. For details, see “Vector
Window Shortcut Menu” on page 304.
Figure 3-11: A Vector Window (left) and its associated Vector Parameters
Dialog.
Vector Attributes
Vector layers may have attributes associated with them. ENVI can read ArcView
Shape file attributes and interact with them. You can use the cursor to select vectors
in the vector window and highlight the associated attributes or select an attribute and
highlight the associated vector. You can do a vector attribute query to create new
vector layers with attributes selected using simple mathematical and logical
operators. ENVI also allows you to edit the existing attributes or to add new attributes
to vectors. Point attribute names can be plotted in the vector window and point
symbol sizes associated with attribute values (see “Vector Attributes” on page 309
for instructions).
Note
Currently ENVI only reads ArcView Shape file attributes or attributes added
using ENVI functions.
To display the mouse button description dialog, select one of the following options:
• From the ENVI main menu, select Window > Mouse Button Descriptions or
Help > Mouse Button Descriptions.
• From the Display menu, select Window > Mouse Button Descriptions.
Collecting Points
Use Point Collection to collects points (both pixel locations and map locations) from
display windows. The points are displayed in a table in the ENVI Point Collection
window.
• Select Window > Point Collection.
For detailed information and instructions, see “Collecting Points” on page 368.
Linking Displays
Use display linking to link multiple displays so that all actions in one display are
mirrored in the others. Dynamic overlays are active when displays are linked
(“Working with Multiple Dynamic Overlays” on page 334).
• To link displays, select Window > Link Displays.
Displays may also be linked using the Tools menu in any display or by using the
Zoom window and Main Image window shortcut menus (see “Linking Images” on
page 333 and “Main Image and Zoom Window Shortcut Menu” on page 213).
Creating Vector Layers . . . . . . . . . . . . . . . 215 Using the Line of Sight Calculator . . . . . . 372
Saving Display Groups . . . . . . . . . . . . . . . 216 Using the Spatial Pixel Editor . . . . . . . . . 374
Setting Display Preferences . . . . . . . . . . . . 217 Using the Spectral Pixel Editor . . . . . . . . 377
Overlays . . . . . . . . . . . . . . . . . . . . . . . . . . . 220 Creating Animations . . . . . . . . . . . . . . . . 378
Contrast Stretching and Quick Filtering . . 316 Using 2-D Scatter Plots . . . . . . . . . . . . . . 382
Using Interactive Stretching . . . . . . . . . . . 321 3-D Surface Views . . . . . . . . . . . . . . . . . . 391
Display Linking and Dynamic Overlays . . 333 Starting a New Display Group . . . . . . . . . 392
Interactive Profiles and Spectral Plots . . . . 337 Closing Display Groups . . . . . . . . . . . . . . 393
Extracting Polarization Signatures . . . . . . 356 Closing All Displays . . . . . . . . . . . . . . . . 393
Color Mapping . . . . . . . . . . . . . . . . . . . . . . 358 Maximizing Open Displays . . . . . . . . . . . 393
Using the Pixel Locator . . . . . . . . . . . . . . . 366 Positioning Zoom and Scroll Windows . . 397
Collecting Points . . . . . . . . . . . . . . . . . . . . 368 Display Output Options . . . . . . . . . . . . . . 398
Figure 4-2: The Zoom and Main Image window shortcut menu. On the left, with
interactive linking off; on the right, with interactive linking on.
Display Functions
Use the File menu on the Display menu to create vector layers for the displayed
image, save display groups to a file, open saved display groups, output images to
various formats, print display images, and set preferences for your image displays.
Figure 4-3: Link displays, set display preferences, and save, restore, or print
displays from the Display File menu.
1. Select File > Create New Vector Layer from the Display menu.
2. Enter a layer name and select output to “File” or “Memory.”
The Vector Parameters window appears.
• To draw new vectors, select Mode > Add New [Type].
For detailed information, see “Working with Vector Layers” on page 296.
Resizing Windows
1. In the open display, select File > Preferences.
The Display Parameters dialog appears.
2. Select from the following options:
• To set the size of the Image, Scroll, and/or Zoom windows, enter the size
(in pixels) in the corresponding text boxes.
• To enter a resize factor for the Scroll window, enter it into the “Resize
Factor” text box.
• To set the zoom factor for the Zoom window, enter it into the “Zoom
Factor” text box.
3. Click “OK.”
For additional resizing techniques, see “Resizing the Main Image Window” on
page 185, “Resizing the Zoom Window” on page 188, and “Resizing the Scroll
Window” on page 192.
3. Click “OK.”
Overlays
Use Overlay to place annotation (text, polygons, symbols, etc.), classifications,
density slices, pixel and map grids, contour lines, regions of interest (ROIs) or
vector layers over an image or plot.
Tip
Use ENVI’s QuickMap feature to quickly overlay grid lines, titles, declination
diagrams, North arrows, and borders on georeferenced images. For details, see
“Creating QuickMaps” on page 289.
Figure 4-4: Access a variety of image overlay options from the Overlay menu.
Annotating Images
Use Annotation to add text, symbols, polygons, lines, polylines, shapes, map
information, and gray-scale or color bars to images and plots. For classification
images, add class keys. Annotation options are similar for images, plots or surface
views. Annotations can be saved to files and included in output options.
Annotation can be placed in the Main Image window, the Scroll window, the Zoom
window, or the “virtual borders” of an image.
Tip
Use ENVI’s QuickMap feature to quickly overlay grid lines, titles, declination
diagrams, North arrows, and borders on georeferenced images. For details, see
“Creating QuickMaps” on page 289.
Note
To use virtual borders, append the border to the image prior to annotating the image
(see “Setting Virtual Display Borders” on page 225).
Positioning Annotations
1. In the Annotation dialog, select the “Main,” “Scroll,” or “Zoom” window
toggle button.
Normal mouse operations in the selected window are disabled. However,
normal mouse operations still apply in the other windows.
• To temporarily suspended annotation, select the “Off” toggle button.
All normal mouse operations are again possible in all windows.
2. Position annotation objects by clicking the left mouse button at the desired site
on the image. Refer to Table 4-1 for specific mouse button and positioning
functions.
3. Use the colored diamond-shaped “handle” to place the annotation at the
desired location. (The handle appears on all annotation types.)
4. After the annotation is positioned, click the right mouse button to “fix” the
object at that location on the image.
The diamond-shaped handle disappears after the annotation is “fixed.”
Tip
The text box at the top of the Annotation dialog describes the mouse button
functions for the current annotation mode. MB1 is the left mouse button, MB2 is the
middle mouse button, and MB3 is the right mouse button.
Mouse
Action Interaction Where
Button
• To change text color, click on the “Color” button menu and select the
desired color.
• To place the text on a solid colored background, use the “Back” button
menu to select a color; to place the text directly on the image without a
background (this is the default), select “Off.”
• To adjust the thickness of the text, enter a new thickness value in the
“Thick” textbox or use the increment arrows to change the value in the
“Thick” parameter box.
• To change the text font, click the “Font” button menu and select a font.
• To change the size of the text (in pixels), change the value or use the arrow
increment buttons in the “Size” parameter box.
• To change the orientation of the text on the screen (the angle at which it is
written), enter the value of the angle in degrees (counterclockwise, with
respect to the horizontal [0 degrees]) in the “Orien” parameter box or
toggle the arrow increment buttons.
• To center the text or justify it left or right, choose the appropriate option
under the “Align” button menu.
4. Position and fix the annotation as described in “Positioning Annotations” on
page 223.
A Note About Fonts
Several font types are available from the “Fonts” button menu in the Text Annotation
window, including special ENVI fonts. Use the “ENVI Symbols” font type to place
mining and cartographic symbols, and ENVI and IDL logos.
• To change the orientation of the polygon on the screen, enter the angle in
degrees (counterclockwise) at which to display the polygon with respect to
horizontal (0 degrees) in the “Rotation” parameter box.
The “Rotation” value is always reset to 0 after it has been changed.
4. Position and fix the annotation as described in “Positioning Annotations” on
page 223.
Setting Polygon “Fill” Attributes
Use the “Fill” button menu to set the fill attributes.
• To leave the polygon unfilled, select “None.”
• To fill the polygon with the polygon color, select “Solid.”
• To fill the polygon with equally spaced lines, select “line,” “dashed,” “dotted,”
etc.
• To change the orientation of the fill lines, enter the value of the angle in
degrees (counterclockwise, with respect to the horizontal [0 degrees]), in the
“Orien” parameter box.
• To change the spacing of the lines, enter a value in the “Spc” parameter box.
Mouse
Action Interaction Where
Button
Mouse
Action Interaction Where
Button
The size can also be explicitly changed by entering the desired X and Y
sizes (in pixels) in the text boxes labeled “xsize:” and “ysize:”.
• To delete the shape, press the middle button.
• To fix the object, press the right button as described in Table 4-2.
3. Select from the options described in “Working with Polygon Annotation” on
page 227 to change shape attributes.
Note
When more than one of the unit types is set to “On,” multiple scale bars will be
drawn.
• To set the height of the scale bar(s), in pixels, enter the desired value in the
“Height” parameter box.
• To change the scale bar length, enter the desired length, in scale bar units,
in the “Length” parameter box.
• To change the number of increments shown on the scale bar, enter the
number in the “Inc” parameter box and the number of sub-increments
within the first main increment in the “Sub Inc” parameter box.
The length, increment, and sub-increment parameters are formatted for each
type of scale bar individually.
3. Set the scale bar text attributes by selecting from the options described in
“Working with Text Annotation” on page 226.
4. Press the right mouse button to fix the scale bar position and characteristics.
3. Select from the following options to change the color ramp characteristics.
• To define the ramp width and length, enter the desired value in the
parameter boxes labeled “Width” and “Len.”
• To place labels on the ramp, enter the minimum and maximum values in
the “Min” and “Max” parameter boxes.
• To define the increment (number) of labels to place on the ramp, enter the
value in the “Inc” parameter box.
• To set the label precision (the number of significant figures), enter the
number in the “Precision” parameter box. For example, .25 is a precision
of 2, and .3 is a precision of 1.
Labels are placed at the bottom of horizontal ramps and placed to the right
of vertical ramps. Set Label attributes by selecting from the options
described in “Working with Text Annotation” on page 226.
4. Press the right mouse button to fix the color ramp once it has been positioned
and formatted.
Working with Map Key, Class Key, and Vector Key Annotation
A map key consists of colored squares and corresponding labels for each map item or
class in a classification image. Map keys can be defined interactively and are
automatically created as class keys for classification images. Vector keys are
automatically created for vector layers in the appropriate colors with the layer names
as labels. Vector keys show the vector symbol used for points, a line for polylines,
and a square outline for polygons.
1. In the Annotation dialog, select Object > Map Key.
2. Click the left mouse button at the desired location to position the map key.
• To delete the map key, press the middle mouse button.
3. Click “Edit Map Key Items” to define or change items in the map key.
4. When the Map Key Object Definition dialog appears, select from the list of
Key items.
• To add additional items to the list, click “Add Item.”
• To delete an item, highlight it in the list and click “Delete Item.”
• To change the name of the item, enter the new name in the “Object Name”
text box.
• To define the color of the box, select the desired color using the “Color”
menu.
• To add additional colors, enter the DN values in the “R,” “G,” and “B,” text
boxes for red, green, and blue respectively.
The newly defined color appears as black in the image but will be correct
upon output.
• To change the fill type in the box, use the “Fill” menu.
• To control the fill type, use the “Orien” and “Spc” parameter boxes.
• For vector keys, an “Object Type” button menu is included and has
polygon, polyline, and point selections.
• For a vector polygon item, use the “Fill” button menu and “Orien” and
“Space” parameter boxes to select the polygon fill type.
• For a vector polyline item, use the “Line Style” button menu to select
different line styles.
• For a vector point item, use the “Symbol” menu to select the symbol type
to be shown in the key.
5. Follow these steps to change other parameters within the Annotation dialog.
• To set a background color select the desired color from the “Back”
pulldown menu in the Annotation dialog.
• To change the text font for the key, the size, and the thickness of the letters,
select from the options described in “Working with Text Annotation” on
page 226.
• To change class colors, see “Mapping Class Colors” on page 364 for
detailed instructions.
• To set the angle of the north arrows, enter the values in degrees in the
“True North,” “Grid North,” and “Magnetic North” text boxes.
The angles are not drawn to scale so that the arrows appear separated.
• To set the arrow length in pixels, use the “Length” parameter box.
• To change the color of the declination diagram, select from the “Color”
button menu.
• To set the background color, select from the “Back” menu.
• To change the text font for the key, the size, and the thickness of the letters,
select from the options described in “Working with Text Annotation” on
page 226.
• To change the line and text thickness, enter a value in the “Thick”
parameter box.
4. Press the right mouse button to fix the position and characteristics of the
declination diagram once it has been formatted.
3. When the Annotation Image Input Bands dialog appears, select an RGB or
grayscale file from the Available Bands List within the dialog.
The “R,” “G,” and “B” text boxes are filled.
• To select a grayscale image, click on the same file name for all three
bands.
• To select a spatial subset, click “Spatial Subset.”
• To perform spatial resampling of the data, enter a resize factor into the
“Resize Factor” text box.
• To clear the file names in the “R,” “G,” and “B” text boxes, click “Reset.”
4. Click “OK” to return to the Annotation dialog and position the image inset.
5. Click the left mouse button at the desired location to position the image.
• To delete the image, click the middle mouse button.
6. Click the right mouse button to fix the image at that location.
Note
The image appears, in the annotation, as a solid red box of the correct size with a
“Gray Image” or “RGB Image” label (see Figure 4-11), but will appear correct
upon output.
The annotation appears in the image as a red box of the correct size entitled
“Plot,” but will appear correct in the output file.
The plots remain as vectors when “burned in” to the image if you output it to
postscript or a printer.
Note
Plot objects will not appear in the image if output to an image file.
• To select multiple objects at once, press and drag a box around the objects with
the left mouse button.
When more than one object is selected the previously selected objects remain
active.
When many objects are selected, using a handle to move one moves them all;
changing attributes change all the selected objects’ attributes.
• To edit selected vector objects (rectangle, ellipse, polygon, polyline, arrow),
click the left mouse button on a vertex and drag it to the desired location.
• To deselect an object, click the middle mouse button on the handle of
the object.
• To deselect multiple objects, press and drag with the middle mouse button to
draw a box around the objects.
• To deselect all of the annotation objects within an image, click the right mouse
button within the image.
• To select only those objects and deselect any previously active objects, press
and drag with the right mouse button to draw a box around object(s).
Additional options are available for selected annotation objects under the Selected
menu (see “Annotation Options” on page 239).
Annotation Options
In the Annotation dialog, use the Selected or the Options menu to access annotation
options. Options available when working with annotation objects include “undoing”
the last action, joining polygons, swapping the positions of overlapping objects,
duplicating or deleting annotation objects, adding virtual borders to an image, turning
annotation mirroring on and off, and showing or hiding annotation object corners.
Joining Polygons
Use the Join option to join the overlapping parts of two polygons.
1. Select two polygons to be joined.
2. In the Annotation dialog, select Selected > Join.
The underlying polygon’s vertices are changed to match those of the overlying
polygon.
Tip
Better results are obtained for polygons that have many vertices (for example, those
drawn while holding down the left mouse button). Use the Swap option (see the
next section) to bring a polygon to the top.
Overlaying Classes
Use Classification to overlay classes on a gray scale or color image in a display
window, control which classes are displayed, collect statistics, edit the class colors
and names, merge classes, and edit classes by adding, deleting, or moving pixels
between classes.
Note
A classification image must be generated prior to using this function (see Chapter 6,
“Classification”).
1. In the display window of the image you want to overlay the classification
results on, select Overlay > Classification.
The Interactive Class Tool dialog appears. It lists all the classes and shows
their colors and names. The active class is displayed at the top of the dialog.
The active class is the class to which any operations (i.e., statistics, editing) are
applied.
2. Select from the following options to edit and apply classes to your image.
• To resize the dialog, click on a corner and drag.
• To change the active class, click on the colored box next to the class name.
• To display a class on the image click in the “On” check box next to the
class name.
Any number of classes can be displayed at once.
• To turn on and display a single class while turning all others off,
double-click with the left mouse button on the colored box next to
class to be displayed.
• To turn it off and display all the other classes, double-click with the left
mouse button on that class again.
• To turn all classes off, click the right mouse button on a colored box.
• To turn all the classes on, click again with the right mouse button on any
colored box.
Editing Classes
Use the Edit menu to edit classes by adding, deleting, or moving pixels between
classes and by drawing polygons, rectangles, or ellipses.
Tip
Save your changes often by selecting File > Save so if you make a mistake you
don’t have to recreate everything!
Saving Changes
• To save changes, select File > Save.
Class Options
Use the Options menu to obtain statistics for classes and to change class colors and
names.
3. Select the classes to merge into the base class by clicking on the desired class
names.
4. Click “OK.”
The next time you open the Class Distributions dialog, it will be updated.
Plotting Mean Spectra
• To plot a mean spectrum for the active class, select Options > Mean for active
class.
If the Input File Associated with Classification Image dialog appears, select
the input file to calculate the statistics from and click “OK.” The dialog
appears only if an input file hasn’t been set previously.
• To plot the mean spectrum for all classes, select Options > Mean for all
classes.
ENVI computes the statistics and displays the mean spectra in a Class Means
plot window.
Plotting Statistics
• To plot the statistics for the active class, select Options > Stats for active class.
If the Input File Associated with Classification Image dialog appears, select
the input file to calculate the statistics from. The dialog appears only if an input
file hasn’t been set previously.
• To plot the statistics for all classes, select Options > Stats for all classes.
ENVI computes the statistics and displays a plot window. The mean spectrum
is in white, the +/- one standard deviation is in green, and the minimum and
maximum spectra are in red.
Tip
To get a text report and more detailed statistics for your classes, select
Classification > Post Classification > Class Statistics.
The classification overlay will be listed in the “Graphics Overlay Selections” list of
the Change Graphics Overlay Options dialog as <Displayed Class Overlay>. For
more information, see “Setting Graphics Overlay Options” on page 406.
Once the contour source image has been defined, the #n Contour Plot dialog
appears (where “n” is the originating display number). Eight default contour
levels are listed under “Defined Contour Levels.” These levels are defined
using a minimum and maximum data value calculated using the Scroll window
and shown in the “Min” and “Max” text boxes.
3. Enter the desired minimum and maximum values in the appropriate text boxes.
Removing Levels
To remove a level from the “Defined Contours List:”
1. Click on a specific contour level to select it.
2. Click “Delete Level.”
3. Click “Apply” to replot the contours.
Clearing Levels
• To clear all the levels from the “Defined Contours List,” click “Clear Levels.”
5. Select from the following steps to set the attributes of the contour.
• To change the thickness, select from the “Thick” menu.
• To change the line style, select from the “Style” menu.
• To change the color, select from the “Color” menu.
• Click on the arrow toggle button to change the contour colors from “Use
same color for each level,” which plots all the contours in the same color,
to “Increment colors for each level,” which plots each contour level in a
different color. The different colors of contour levels will follow the list of
graphic colors.
6. Click “OK” to enter the new contours into the “Defined Contour Levels” list.
7. Click “Apply” to plot the contours.
Grid Lines
Use Grid Lines to overlay one or more grids on an image. Grids can be pixel-based or
map-coordinate and/or latitude/longitude based (for georeferenced images). Each
image display can have its own set of grids, which are displayed in the Main Image,
Scroll, and Zoom windows.
Tip
Use ENVI’s QuickMap feature to quickly overlay grid lines, titles, declination
diagrams, North arrows, and borders on georeferenced images. For details, see
“Creating QuickMaps” on page 289.
Grid Types
Pixel-Based Image Grids
Images that have not been referenced to map coordinates can only have pixel-based
grids. In this case, the grid spacing is specified in pixels (from (1, 1) in the upper left
corner) and the grid lines are labeled with the pixel coordinates (Figure 4-17).
Figure 4-19: Polygon, polyline, and rectangle regions of Interest (ROIs) drawn
on the Main Image window (and displayed in the Scroll and Zoom windows).
Note
ROIs are explicitly related to the spatial size of the image in which they are defined.
If you open, or have open, images of equal spatial size with their associated ROI
Tool dialogs, ROIs drawn in one image will be displayed in all other images of the
same spatial size. You can edit or delete shared ROIs from within any of the ROI
Tools dialogs.
Drawing ROIs
There are six ROI types: Polygon, Polyline, Point, Rectangle, Ellipse, and Multi-Part
(“donut”). A single region can contain any combination of the six ROI types. Each
type has a different set of mouse button assignments. The mouse assignments and
drawing options are explained in the following sections and summarized in Table 4-
3.
Note
If you have multiple images of the same size displayed and their associated ROI
Tools dialogs open at the same time, any ROIs drawn in one image display will also
be displayed in the others.
Drawing Polygons
The polygon mode is the default method for ROI definition. Use polygons to outline a
region of interest with connected line segments.
1. In the ROI Tool dialog, select ROI_Type > Polygon.
2. Click the left mouse button in the active window to establish an initial endpoint
for an outlining segment.
As the mouse is moved to select another endpoint, a line is shown to exactly
indicate the position of the current segment.
3. Click the left mouse button again to define the segment, which is drawn in the
selected color.
• For continuous drawing, hold the left mouse button down and move the
cursor.
4. Choose additional segments in the same manner until the entire region of
interest is outlined.
• To erase the last segment defined at any point during the segment selection
process, click the middle mouse button.
5. Click the right mouse button to draw the last segment and automatically close
the polygon.
6. Move the polygon to the desired location by clicking on the diamond-shaped
handle and dragging with the left mouse button.
7. Click the right mouse button to accept the polygon.
The total number of pixels contained in the ROI are listed along with the ROI
name in the “Available Regions of Interest” list as the polygon is completed.
You may draw multiple polygons for each ROI. Each successive polygon is
drawn as above and its pixels added to the total for the region. When
completed, the polygon is filled with a solid color by default.
• To change the polygon color and fill type, click “Edit” and make the
appropriate changes when the dialog appears.
• To delete entire polygons from the ROI at any time, click the middle mouse
button while the cursor is on the desired polygon.
8. When you are satisfied with the new ROI, select File > Cancel to dismiss the
ROI Tool dialog or click the “New Region” button to define another region of
interest.
Drawing Polylines
The polyline mode is similar to the polygon mode except that a multi-segment vector
is drawn rather than a closed polygon. The regions enclosed by the defined line
segments are not selected and filled upon completion. Only the pixels comprising the
line segments themselves are selected.
1. In the ROI Tool dialog, select ROI_Type > Polyline.
2. Click the left mouse button to define the endpoints of connected line segments.
• To remove the previous segment, click the middle mouse button.
• For continuous drawing hold down the left mouse button while drawing.
3. Click the right mouse button to end the process of defining a polyline.
4. Use the handle on the polyline to move the line.
• To erase the entire polyline, click the middle mouse button on any pixel of
a previously-defined polyline.
5. Click the right mouse button to accept the polyline.
6. When you are satisfied with the new ROI, select File > Cancel to dismiss the
ROI Tool dialog or click the “New Region” button to define another region of
interest.
Drawing Points
Use the point mode to select or delete individual pixels under the cursor.
Tip
For best results, add Point ROIs in the Zoom Window.
4. Draw any number of additional ROIs or “parts” within the first ROI to create
“holes.”
Note
The hole(s) cannot cross the path of any other polygon within its group.
Again, the ROIs do not become filled in when you click the right mouse button
the second time.
5. After adding parts to the ROI, click the right mouse button a third time to
accept the multi part ROI.
The base ROI becomes filled in, and the “parts” are removed to reveal “holes” in the
base ROI.
Mouse
ROI Mode Action Button Interaction
1. To start a new ROI, click “New Region” in the ROI Tool dialog.
A new name appears in the “Available Regions of Interest” list. The new region
uses the next color in the graphics colors list by default.
2. Select the ROI type and draw the ROI.
3. Edit the ROI as needed.
ROI Options
In the ROI Tool dialog, you have many options to choose from when working with
ROIs: inputting ASCII points into an ROI, creating multiple regions of interest,
reporting ROI statistics, measuring distances and area, reporting the areas of the
ROIs, loading, erasing, deleting, plotting means, merging regions, reconciling ROIs,
and performing band thresholds to ROIs.
Note
If the ROI is displayed in more than one image (of the same spatial size), any edits
will be reflected in all of those images.
Erasing ROIs
Erasing an ROI removes it from the display, but the region of interest is still defined
and remains listed in the ROI Tool dialog.
• To remove a selected ROI overlay from the selected image, click on an ROI
name and click “Erase.” To re-display the ROI image, click on the ROI name.
• To erase all ROI overlays from the current display select Options > Erase All
Regions. To re-display the ROIs, click again on each ROI name or select
Options > Load All Regions.
Deleting ROIs
Use the Tools menu in the Main Image display, the Options menu in the ROI Tool
dialog, or the Basic Tools menu on the ENVI main menu to delete ROIs.
Warning
If the ROI to be deleted is displayed in more than one image (for images of the same
spatial size), deleting it from one deletes it from all. Once the ROIs are deleted, they
cannot be recovered unless they have been saved to a file.
The unsaved ROIs are erased from the display(s) and deleted from the system. The
ROIs do not appear in the ROI Tool dialog(s) after being deleted.
Deleting Saved ROIs
To delete regions that are not currently displayed:
1. Select one of the following options:
• From the ENVI main menu, select Basic Tools > Region of Interest >
Delete ROIs.
• From the Display menu, select Tools > Region of Interest > Delete ROIs.
2. When the Delete Regions dialog appears, click on the names of the regions to
be deleted.
3. Click “OK” to permanently delete those ROIs.
Locating Defined ROIs
To center the zoom window over the first pixel defined in an ROI:
1. In the ROI Tool dialog, select an ROI name and click “Goto.”
2. Continue clicking on “Goto” to move the zoom window over each pixel
contained in that ROI.
Displaying Statistics for an ROI
1. In the ROI Tool dialog, click on an ROI name.
2. Click the “Stats” button.
The Average Spectrum and ROI Statistics windows appear.
The Average Spectrum plot window (Figure 4-21) displays the mean spectrum (mean
of every band for the selected ROI) in white for the file associated with the displayed
image. The standard deviation spectrum (standard deviation of every band) is plotted
both above and below the mean spectrum (+/- 1 std. deviation) in green. The
minimum and maximum spectra (minimum and maximum for every band) are
plotted above and below the standard deviation spectra in red. The plot window
containing the statistics is identical to the plot windows used for X, Y, and Z profiles,
and all interactions are the same.
The ROI Statistics window lists the file name, the region name and number of points,
and the band number, minimum, maximum, mean, and standard deviation for each
band.
Figure 4-21: The Average Spectrum and ROI Statistics Windows. These
windows are displayed by selecting “Stats” from the ROI Tool dialog.
Growing ROIs
You can “grown” regions of interest to neighboring pixels using a specified threshold.
The threshold is determined by specifying a number of standard deviations away
from the mean of the drawn region. You can use either 4 or 8 neighboring pixels to
determine the growth pattern. It is calculated using the displayed band for a gray
scale display, or the red band for a color display.
Note
All grown regions of interest are output as points, regardless of the starting ROI
type.
1. In the Available Regions of Interest list, click on the name of the ROI
to be grown.
Within the current image window, neighboring pixels that fall within the
standard deviation threshold will be included in the grown region. Adjacent
pixels outside the current image window, regardless of pixel value, will not be
included in the ROI.
2. Click the “Grow” button.
The new grown ROI is shown in the display window. A prompt asks if you
want to keep the resulting grown ROI.
3. Select “Yes” to grow the ROI with all of the points shown. Select “No” to
return the ROI to its original size.
If “No” is selected, the Region Growing dialog appears.
• In the Region Growing dialog, change the values of the standard deviation
multiplier and the number of neighbors, if desired, and click “OK” to grow
the ROI with the new parameters.
• Click on “Cancel” in the Region Growing dialog to exit the growing option
without changing the original ROI.
Inputting ASCII Data into ROIs
You can input ASCII data points into a new or an existing ROI, select the ROI type,
and select the associated map projection information if needed.
Tip
To input the ASCII data points into a new region, click “New Region” before
completing the following procedure.
1. In the ROI Tool dialog, select ROI_Type > Input Points from ASCII.
2. When the Enter ASCII Points Filename dialog appears, select an input ASCII
filename.
3. When the Input ASCII File dialog appears, enter the column numbers for the X
and Y point coordinates.
4. Select the type of ROI that the points define by clicking on the button menu
next to the “These points comprise” label.
For polygon and polyline ROIs, the ASCII points define the vertices of
the ROI.
5. Select whether the input coordinates are “Pixel Based” or “Map Based.”
• If you select “Map Based,” select the projection type and enter the zone
and datum information as necessary by clicking on the “Zone...” and
“Datum...” buttons.
6. Click “OK.”
Loading all Regions
• To load all regions currently defined for all images with the same spatial
dimensions as the currently selected display as shown in the “Display #” field,
select Options > Load All Regions.
Merging Regions
To merge multiple defined regions of interest into one:
1. Select Options > Merge Regions.
The Merge ROIs dialog appears with two lists of all defined regions.
2. Under “Choose Base ROI to Merge,” click on the name of a region.
3. Under the “Choose ROIs to Merge” list, select the names of the regions to
merge into the base region.
4. Click the arrow toggle button next to “Delete Merged ROIs?” label to select
whether or not you want the individual regions being merged to be deleted
after they are merged.
The color of the “other” ROIs change to that of the “base” ROI and the other
names are removed from the “Available Regions of Interest” list.
5. Click “OK.”
Intersecting Regions
Use Intersect Regions to create a point type region of interest that contains only the
points where two or more ROIs intersect in an image.
1. In the ROI Tool dialog, select Options > Intersect Regions.
Note
Selected regions must intersect.
2. In the ROI Intersection dialog, click on the names of the intersecting ROIs to
be included in the new ROI, then click “OK.”
The new ROI appears in the Available Regions of Interest list. It is a point type
ROI and is displayed under any overlying polygon ROIs.
Tip
If you can’t see the new point ROI in the image display, erase all other ROIs and re-
display the new ROI.
Note
You can calculate ROI intersections on-the-fly and use them when building a mask.
For more information, see “Including ROI Intersections” on page 462.
Reconciling ROIs
In the ROI Tool dialog, use Reconcile ROIs to apply ROIs defined in one image size
to different sized images.
Note
Using Reconcile ROIs, ROIs can only be reconciled to images with the same pixel
size as the original image. To reconcile ROIs to an image with a different pixel size,
use Reconcile ROIs via Map.
2. When the Reconcile ROIs Parameters dialog appears, choose the ROIs to be
reconciled by selecting from the following options:
• To manually designate the spatial dimensions for the new ROIs:
A. Enter the difference in pixels between the origin of the image where the
ROIs were drawn and the origin of the new image into the “xoffset” and
“yoffset” text boxes.
B. Enter the number of samples and lines in the new image into the
appropriate text boxes.
• To have ENVI calculate the x and y offsets and the number of samples and
lines automatically:
A. Click the “Set Values from Source/Destination Files.
B. When the file selection dialog appears, choose the file where the ROI was
originally drawn and click “OK.”
C. When the next file selection dialog appears, select a destination file for the
ROI(s) and click “OK.”
3. In the Reconcile ROIs Parameters dialog, click “OK.”
The ROIs are listed in the ROI Tool dialog and are automatically loaded onto the new
image.
Reconciling ROIs via Map
Use Reconcile ROIs via Map to use ROIs defined in one georeferenced image in
another overlapping georeferenced image, regardless of differences in image or pixel
sizes between the two images.
1. Select one of the following options:
• In the ROI Tool dialog, select Options > Reconcile ROIs via Map.
• From the Display menu, select Tools > Region of Interest > Reconcile
ROIs via Map.
• From the ENVI main menu, select Basic Tools > Region of Interest >
Reconcile ROIs via Map.
2. When the Reconcile ROIs via Map Parameters dialog appears, select the
desired ROIs by clicking on the names.
3. Click “OK.”
4. Select the georeferenced file that you want the ROIs reconciled to and click
“OK.”
The ROIs are listed in the ROI Tool dialog and automatically loaded onto the new
image.
Converting Band Values to ROIs
Use Band Threshold to ROI to convert specific image values and ranges of values to
Regions of Interest.
1. Select one of the following options:
• In the ROI Tool dialog, select Options > Band Threshold to ROI.
• From the Display menu, select Tools > Region of Interest > Band
Threshold to ROI.
• From the ENVI main menu, select Basic Tools > Region of Interest >
Band Threshold to ROI.
2. When the Band Threshold to ROI Input Band dialog appears, select a band to
be thresholded.
3. When the Band Threshold to ROI Parameters dialog appears, select from the
following options.
• To make an ROI using those pixels greater than or equal to the entered
minimum value, enter only the “Min Thresh Value.”
• To select those pixels less than or equal to the entered maximum value,
enter only the “Max Thresh Value.”
• To select pixels that fall within a specified range of values, enter both a
minimum and a maximum threshold value.
• To assign an ROI name, edit the “ROI Name” text entry.
• To change the color of the ROI, select the desired color from “ROI Color”
menu.
4. Click “OK” to extract the thresholded pixels.
A warning dialog appears and list the number of pixels that satisfy the
threshold criteria.
5. Click “OK” to accept and load the ROI.
The region is listed in the ROI Tool dialog as a “Thresh Bandname,” where
Bandname is the name of the band used to extract the ROI. The number of pixels in
the region are also listed.
• From the ENVI main menu, select Basic Tools > Region of Interest >
Create Class Image from ROIs.
The Classification Image from ROIs dialog appears.
2. In the list of ROIs, select the ROI(s) to use by clicking on the ROI name(s).
3. Click “OK.”
The Classification Image from ROIs Parameters dialog appears.
• To change the output classification image DN value of an ROI, click on the
ROI and use the arrow toggle buttons to enter a new DN value.
4. Enter an output filename and click “OK.”
The resulting classification image filename appears in the Available Bands List.
Computing ROI Separability
Use Compute ROI Separability to compute the spectral separability between selected
ROI pairs for a given input file. Both the Jeffries-Matusita and Transformed
Divergence separability measures are reported. These values range from 0 to 2.0 and
indicate how well the selected ROI pairs are statistically separate. Values greater than
1.9 indicate that the ROI pairs have good separability. For ROI pairs with lower
separability values, you should attempt to improve the separability by editing the
ROIs or by selecting new ROIs. For ROI pairs with very low separability values (less
than 1), you might want to combine them into a single ROI. For more information,
see the following reference:
J.A. Richards, 1999, Remote Sensing Digital Image Analysis, Springer-Verlag,
Berlin, p. 240.
1. Select one of the following options:
• In the ROI Tools dialog, select Options > Compute ROI Separability.
• From the Display menu, select Tools > Regions of Interest > Compute ROI
Separability.
• From the ENVI main menu, select Basic Tools > Region of Interest >
Compute ROI Separability.
2. When the file selection dialog appears, select the input file and perform any
spectral subsetting.
The ROI Separability Calculation dialog appears.
3. In the dialog, select ROIs for the separability calculation.
4. Click “OK.”
The separabilities are calculated and reported in a report dialog. Both the
Jeffries-Matusita and Transformed Divergence values are reported for every
ROI pair. The bottom of the report shows the ROI pair separability values
listed from the least separable pair to the most separable.
• To save the report to an ASCII file, select File > Save Text to ASCII.
3. Enter or choose an output filename (with the extension .roi for consistency).
4. Click “OK” to save the ROI file.
• From the ENVI main menu, select Basic Tools > Region of Interest >
Restore Saved ROI File.
2. When the file selection dialog appears, select the ROI file.
The ROI is loaded into the display group and ROI Tool dialog of every image of the
same spatial size.
Subsetting Data via ROIs
To subset an image file based on the bounding box (i.e., the area encompassing) an
ROI or group of ROIs currently drawn on an image, follow these steps:
1. In the ROI Tool dialog, select File > Subset Data via ROIs.
2. When the Input File selection dialog appears, select the file to be subset.
• To apply spectral subsetting to the input file, click “Spectral Subset” and
use standard ENVI methods.
The Spatial Subset via ROI Parameters dialog appears.
Figure 4-24: In the Spatial Subset via ROI dialog, select the ROI(s) to use as the
area of a spatial subset.
4. Use the arrow toggle button to select whether or not to mask pixels that do not
fall within the ROI.
• If you select “Yes,” enter a background value.
5. Select output to “File” or “Memory.”
6. Click “OK.”
The resulting subsetted file is listed in the Available Bands List.
2. When the Select Input Data File dialog appears, select the input file that the
ROIs are associated with and click “OK.”
The n-D Visualizer Input ROIs dialog appears.
3. Select a ROI to export by clicking on the ROI name.
• To select all of the ROIs, click “Select All Items.”
4. Click “OK.”
An n-D Visualizer window and n-D Controls dialog appear.
5. Click on the band numbers to select those bands for rotation.
6. Click “Start.”
The pixels for the selected ROIs appear in the n-D Visualizer window in the
same colors as the ROIs.
Note
For good classification results using these ROIs, the groups of pixels for the
different ROIs should be separate from each other and should not overlap.
• If the pixels overlap, edit the groups of pixels by selecting the appropriate
colors from the Class menu to add pixels to an ROI or by selecting White
to remove pixels from an ROI.
7. Select Options > Export Class or Export All to export the colored pixels back
to the ROI Tool dialog so they can be imported into classifications.
For more information and detailed instructions for the n-D Visualizer, see “The n-
Dimensional Visualizer” on page 636.
• From the ENVI main menu, select Basic Tools > Region of Interest >
Output ROIs to ASCII.
2. When the file selection dialog appears, select the input file and perform any
spectral subsetting.
3. Click “OK.”
4. Select the ROIs to output.
• To select which parameters to output, see the following section.
5. Enter or choose an output filename and click “OK.”
Editing ASCII Output Format
You can specify which parameters are included in the ASCII output.
1. In the Output ROIs to ASCII Parameters dialog, click the “Edit Output ASCII
Form” button.
The Output ROI Values to ASCII dialog appears. By default, all parameters are
selected for output.
2. Set parameters by selecting/deselecting the corresponding check box:
• To include a label with the output, leave the “Point #” check box selected.
• To include the ROI location information in the output, leave the “ROI
Location” check box selected. Use the ROI Location arrow toggle button
to select whether the ROI location is output by one-dimensional locations
or by sample/line.
Pointers to each of the pixels contained in the selected ROIs are output to
the ASCII file. The pointers are the one-dimensional addresses to the pixel
locations in the file where a 1-D address = line number x number of
samples + sample number.
• To include geographic location information for georeferenced data, leave
the “Map Location” check box selected. Use the Map Location arrow
toggle button to designate output of the geographic locations in normal or
scientific notation. Use the arrow increment buttons to set the number of
significant digits.
• To include geographic (lat/lon) location information for georeferenced
data, leave the “Geo Location” check box selected. Use the Geo Location
arrow toggle button to designate output of the geographic locations in
normal or scientific notation. Use the arrow increment buttons to set the
number of significant digits.
Creating QuickMaps
Use the QuickMap feature to simplify the process of creating a map product in ENVI.
You can quickly add grid lines, scale bars, titles, north arrows, declination diagrams,
and logos to your image to make a quick output map. Once you have set all of your
parameters, you can save the settings as a QuickMap template that you can use on
other images. After the output map is created, you can make additional changes with
the Main Image interactive overlay capabilities (e.g, annotation) and you can output
the map to Postscript or to a standard printer.
Note
To use the QuickMap feature, you must have a georeferenced image displayed.
If you use extremely small images for your QuickMap, the resulting QuickMap
image may not be large enough to accommodate multiple annotation objects.
6. Click “OK.”
The #N QuickMap Parameters dialog appears, where “N” is the number of the
associated display group.
Figure 4-26: In the QuickMap Parameters dialog, add and edit the elements of
your map and save or restore QuickMap templates.
1. When the QuickMap Parameters dialog appears, select from the following
options:
• To add a title to the top of the map, type the text in the “Main Title” text
box.
• To add text to the lower left or lower right corners of the map, type the text
into the corresponding text boxes.
• To automatically load the map projection information from the ENVI
header into either the “Lower Left” or “Lower Right” text boxes, right-
click in the text box and select “Load Projection Info.”
• To change the font used for any title, select a new font from the
corresponding button menu and enter or select the point size.
• To set the justification for any title, select from the corresponding button
menu.
“Center” is the default.
• To add scale bars and grid lines, leave the corresponding check boxes
selected and edit the parameters as needed.
• To add a logo and adjust its placement, click the “Edit Logo Files and
Placements” button. Locate the file containing the logo (the file must
contain three bands of byte data: red, green, and blue). Use the QuickMap
Logo File Parameters dialog to change the logo size and position. Click
“OK.” to return to the QuickMap Parameters dialog.
• To add a North arrow, leave the corresponding check box selected and
select an arrow type from the “North Arrow Type” button menu.
• To add a declination diagram, click the “Declination Values” button. In the
Declination Diagram Values dialog, enter the values and click “OK.”
• To return to the QuickMap Image Selection window and edit the image
subset or map scale, click the “Change Mapping Parameters” button.
2. In the QuickMap Parameters dialog, click “Apply.”
ENVI automatically adds a virtual border to your QuickMap image, places
your selected titles and annotation onto your image, and produces a map,
which is displayed as a new standard ENVI Display Group. The QuickMap
Parameters dialog remains open.
Note
If you added a logo, it will appear as a red box with an “RGB” label on the map, but
will appear correctly when printed.
3. Use the QuickMap Parameters dialog to edit the map. Click “Apply” to view
the changes.
• To edit the borders, add more annotation or overlay elements, or edit the
existing map elements, use standard ENVI interactive display functions as
described in this chapter.
Printing QuickMaps
To print the QuickMap:
1. In the QuickMap Main Image window, select File > Print.
2. Select the “Output QuickMap to Printer” or “Standard Printing” check boxes.
The Output QuickMap printing will scale the output correctly for the
parameters that you entered at the start of QuickMap. Standard printing does
not take into consideration the page size and map scale you entered when you
created the QuickMap.
Tip
If you selected a large page size during QuickMap setup, you might first test the
output on a small scale by using the standard printing option, then use the
QuickMap printing option to print to a larger page.
3. Click “OK.”
Additional QuickMap Output Options
To output the map directly to an image or Postscript file, select the corresponding
command from the File menu in the map Main Image window as described later in
this chapter.
QuickMap Templates
After creating a QuickMap, you can save the parameters in a template file to be used
on other georeferenced images of the same dimension and pixel size.
1. In the QuickMap Parameters dialog, click “Save Template.”
2. Enter a filename (ENVI will add a .qm extension). Click “OK.”
Restoring QuickMap Templates
To open and apply an existing map template, follow these steps:
Note
Use QuickMap templates only on images of the same dimension and pixel size of
the image from which the template was created.
Overlaying Vectors
Use ENVI Vector Windows to view vector data such as USGS Digital Line Graphs
(DLG), USGS DLGs in Spatial Data Transfer Standard (SDTS) format, DXF files,
ARC/INFO Interchange files, and ArcView Shape files. ENVI Vector Windows
consist of a vector display window or image window and a Vector Parameters #N
dialog where N is the vector or image display number.
Use Vector Layers to overlay vector layers on an image, to control the appearance of
the vectors, and to interact with the vector attributes. Also use ENVI’s interactive
vector functions to edit and query attributes associated with ArcView Shape files and
to create your own vector files and attributes.
Note
You can also access vector functions from the Vector menu on the ENVI main
menu. For more information, see Chapter 11, “Vector Tools”.
• To read vector data from disk files, see “Opening Vector Files” on page 89.
• To read USGS DLG files from tape, see “Reading USGS DLG Tapes” on
page 137.
• To open vector layers from the Available Vectors List, see “The Available
Vectors List” on page 196.
Figure 4-27: A Vector Window (left) and its associated Vector Window
Parameters dialog.
4. Select left, middle, or right alignment, font type, text size and orientation using
the appropriate parameters.
5. Click “OK” to return to the Edit Vector Layers dialog.
Note
For more information about attributes, see “Vector Attributes” on page 309.
Selecting Vectors
To use the cursor to select a vector and to see the corresponding vector attribute
information:
1. In the Available Vector Layers list, click on the vector layer.
2. Select Options > Vector Information or Options > View/Edit Attributes.
3. Select Mode > Cursor Query.
4. Click with the left mouse button on the desired vectors in the Vector Window
or image display.
The associated attributes are displayed in the Vector Information dialog or
highlighted in the vector attributes table.
Editing Existing Vectors
1. In the Available Vector Layers list, click on the vector layer to be edited.
2. Select Mode > Edit Existing Vectors.
3. Click on a vector with the left mouse button.
It is highlighted (see “Setting the Current Highlight Color” on page 298).
4. Click and drag the diamond shaped handles using the left mouse button to edit
the vectors.
• To undo all changes, click with the middle mouse button.
• To snap the selected vector handle to the nearest point of in that layer,
double-click with the left mouse button.
5. Click the right mouse button to end the editing and to make the changes fixed.
4. Click the right mouse button to get a diamond shaped handle which can be
used to move the vector position.
• Click with the middle mouse button to delete the vector.
• Double click with the left mouse button to snap the selected vector handle
to the nearest point in that layer.
5. Click the right mouse button to “fix” the new vector.
2. When the Import Vector Layers dialog appears, select the vector files to be
imported by clicking in the boxes next to filename(s).
• To cancel the selection process, click “Cancel.”
3. Click the “OK” button to return to the Vector Parameters dialog.
The selected files appear in the Available Vector Layers list of the Vector Parameters
dialog and are available for display.
1. In the Vector Parameters dialog, select Options > Calculate Buffer Zone.
• If your vector layer(s) is/are not overlaid on a displayed image, the Select
Associated Data File dialog appears. Select the input image file and click
“OK.”
• If you have more than one vector layer open, the Buffer Zone Input Layers
dialog appears. Click on the names of the layers to be included in the
buffer zone image and click “OK.”
Note
If you select more than one layer, the distance will be calculated from the pixel to
the nearest selected layer.
3. Click “Apply” to apply the new data range to the vector window.
Vector Attributes
Vector layers may have attributes associated with them. ENVI reads ArcView Shape
file and MapInfo Interchange file attributes. The attributes are stored in a dBASE II
table (.dbf) for ArcView and in a .mid file for MapInfo.
Use the ENVI attributes table to view, edit, sort, and save vector attribute data. Use
the Vector Attribute functions to create new vector layers based on attribute values, to
add new attributes to vectors, to plot point attribute names in vector windows, and to
associate point symbol sizes with attribute values (see “Editing Vector Layers” on
page 299).
The value can be a string (case sensitive) or numeric value depending on the
attribute type.
7. Click “OK.”
The query expression is added to the list in the Layer Attribute Query dialog.
8. To make a more complicated query expression using logical operators, choose
from the following options:
• Click “AND” and follow steps 4-7 to do a query that must satisfy both
entered mathematical expressions.
• Click “OR” and follow steps 4-7 to do a query that must satisfy one of the
entered mathematical expressions.
• Click “Clear” to clear the query expression.
9. Enter a query layer name in the appropriate text box.
10. Select output to “File” or “Memory.”
11. Click “OK.”
The new layer appears in the Available Vector Layers list.
Adding Attributes to Vectors
To add attributes to a vector layer that does not have any:
1. In the Available Vector Layers list, click on a vector layer.
2. Select Options > Add Attributes.
The Attribute Initialization dialog appears with one field defined.
3. Select from the following options to edit, add, or delete field parameters.
• Change the field name using the “Name” text box.
• Select the field type from the “Type” pulldown menu.
Available types include character, numeric, logical, and date. The logical
field contains a single character, either a Y or N, T or F, or ?.
• Enter the width of the field in the table in the “Width” box.
• Enter the number of digits to the right of the decimal in the “Decimal
Count” box for a numeric field.
• Click on “Add Field” to add a new field to the Defined Attribute Fields list.
• Select a field name from the Defined Attribute Fields list and click “Delete
Field” to remove the field from the list.
4. Click “OK.”
An attribute table is started (see “The Attributes Table” on page 312).
The Attributes Table
Use the ENVI attributes table to view, edit, sort, and save vector attribute data. The
attributes table shows the attribute names at the top of each column and the attribute
record number at the left of each row. The attributes table has two pulldown menus,
File and Options.
Highlighting Attribute Data
To select attribute data in the attributes table:
1. In the Available Vector Layers list, click on a vector layer.
2. Select Options > View/Edit Attributes.
The ENVI Attributes table appears.
3. Click with the left mouse button on the desired vectors in the Vector Window.
The associated attributes are highlighted in the ENVI Attributes table.
Highlighting Vectors
• To highlight the vector that corresponds to a selected attribute record, click on
the attribute record number.
The Vector Window centers on the corresponding vector and the vector is
highlighted in the “Current Highlight” color.
Editing Single Attribute Values
• To edit a single attribute value, double click in the desired attribute field and
enter the new value.
2. Select Options > Sort by selected column forward, Sort by selected column
reverse, or Sort by original order.
Replacing Attributes with a Single Value
To replace cells in the same column with a single value:
1. Select one of the following options:
• To replace the entire column, click on the column name.
• To replace selected cells, click and drag with the cursor to highlight the
cells.
2. Select Options > Replace selected cells with value.
3. When the Replace Table Cells with Value dialog appears, enter the desired
string or numeric value and click “OK.”
Replacing Attributes with ASCII Data
To replace cells in the same column with values from an ASCII file:
1. Select one of the following options:
• To replace the entire column, click on the column name.
• To replace selected cells, click and drag with the cursor to highlight the
cells.
2. Select Options > Replace selected cells with ASCII values.
3. Select the desired input ASCII filename.
4. When the Input ASCII File dialog appears, select the desired column number
(strings can only have one column), and starting and ending row numbers.
5. Click “OK” to enter the data into the attribute table.
Saving Changes
• To save changes made to the attribute table, select File > Save Changes.
Warning
This writes over the existing attribute file.
Figure 4-31: Access interactive stretching and filtering options from the
Enhance Menu.
Display Filtering
Use Filter to choose sharpening, smoothing, and median filters. These filters are
applied to the displayed data only and used to quickly enhance the displayed data.
The enhanced displayed image can be output to a file or printer (see “Display Output
Options” on page 398).
Sharpening Filters
The sharpening filters perform a high pass convolution on the data in the image
displays windows (image, scroll, and zoom). Three types of sharpening filters are
available, each one with a differing amount of data add back. The number in brackets
next to the word “Sharpen” is the kernel center value. Therefore, the sharpening
filters with higher numbers in the brackets have a larger amount of the original data
added back to the filtered image.
Note
When using the Sharpen filters with unsigned integer data, the result may not be
properly displayed due to the underflow of negative numbers. To avoid this, use File
> Convolutions from the ENVI main menu instead.
Smoothing Filters
Two smoothing filters are available. The “Smooth [3x3]” filter uses a 3x3 kernel size
and the “Smooth [5x5]” filter uses a 5x5 kernel size. The larger kernel size results in
more smoothing.
Median Filters
Two median filters are available, with kernel sizes of 3x3 and 5x5. The median filters
replace the center pixel value with the median value in the kernel. These filters can
help reduce salt and pepper type noise or speckle.
Applying Filters
• To apply a filter to your displayed data, select Enhance > Filter > filter type.
For more filtering functions and information, see Chapter 8, “Filters”.
Quick Linear
The Quick Linear stretch uses the data minimum and maximum to perform a linear
contrast stretch (no clipping). This is particularly useful for displaying images with
only a few data values, where clipping might saturate all of the values.
Quick 2%
The Quick 2% option applies a linear stretch with a 2% clip on both ends of the
displayed data.
Quick Guassian
The Quick Gaussian applies a Gaussian stretch with a mean of DN 127 and the data
values at ± 3 standard deviations set to 0 and 255.
Quick Equalization
The Quick Equalization stretch applies a histogram equalization stretch of the
displayed data.
Matching Histograms
Use Histogram Matching to automatically match the histogram of one displayed
image to another to make the brightness distribution of the two images as close as
possible. With this function, the output histogram of the window where the function
was started is changed to match the current output histogram of the selected image
display window. You can use this feature on both grayscale and color images and can
select the histogram source for the input histogram.
Note
To perform Histogram Matching you must have at least two images displayed.
1. From the image display of the histogram that you want to change, select
Enhance > Histogram Matching.
The Histogram Matching Input parameters dialog appears.
2. In the “Match To” list, select the display number of the image with the
histogram you want to match to.
3. Under “Input Histogram,” select the source of the input histogram by selecting
the appropriate toggle button: “Image,” “Scroll” (subsampled data), “Zoom,”
“Band” (all pixels), or a “ROI” (region of interest).
4. Click “OK.”
5. The display stretch changes to match the selected histogram.
• To see how the histogram matched, select Enhance > Interactive Stretching in
the image where you applied the histogram match.
The resulting dialog shows two histograms in the Output Histogram plot: the
imported histogram in red and the matched output histogram in white.
Tip
When specifying the minimum and maximum parameters in the text boxes, enter
either the actual values desired (e.g., 37 for the minimum and 68 for the maximum)
or a percentage of the data (e.g., “2%” for the minimum and “98%” for the
maximum). You can set the histogram values outside the data range but the stretch
values can only fall within the values shown on the input histogram.
When the values are entered, the output histogram updates to reflect the changes
made to the input histogram and shows the distribution of the data with the new
stretch applied.
Stretch Types
Use the Stretch_Type menu in the Interactive Contrast Stretching dialog to select
from a list of all available types of interactive stretches, including the quick default
stretches that are also accessible from the Display Enhance menu.
Matching Histograms
Also use the Arbitrary Contrast Stretching function to match a histogram from one
image to the histogram of another.
1. Grab either the input or output histogram from one plot by clicking on the
“Input Histogram” or “Output Histogram” text label at the top of the plot using
the left mouse button.
2. Drag the name into the other arbitrary output histogram and release the button.
The imported histogram will be plotted in red and the output histogram will be
stretched to match the imported histogram.
3. Click “Apply” to apply the stretch to the displayed data.
Defining Look-Up-Tables
A user defined look-up-table stretches each input DN to an output value. It can be
restored (see “Restoring Stretch LUTs” on page 331) or defined interactively.
1. Select Stretch_Type > User Defined LUT.
2. Select Options > Edit User Defined LUT (see Figure 4-33).
When the edit dialog appears, a list of the input DN values and their
corresponding output stretch values is shown under the “Edit User Defined
LUT” label. These values reflect the current stretch.
3. Click on the value to be edited.
4. When it appears in the “Edit Selected Item:” text box, enter the desired value
and press the “Return” key.
• To reset the look-up-table to the values it had when the function was
initiated, click “Reset.”
5. Click “OK.”
6. Click “Apply” to apply the stretch to the displayed data.
Resetting Stretches
• To reset the stretch to what it was initially, select Options > Reset Stretch.
Applying Stretches
• If you selected Options > Auto Apply:Off, click “Apply” to apply the stretch
parameters.
Note
You can also set the auto apply option in the ENVI main preferences file. For
information, see the description of “Misc” preferences under “Setting ENVI
Preferences” on page 160.
2. Grab the “Input Histogram” or “Output Histogram” text label at the top of the
plot with the left mouse button and drag the name into the new plot window.
Outputting Histograms
Standard ENVI output options include Image, PostScript, BMP, HDF, JPEG, PICT,
SRF, TIFF, and XWD formats.
• Select File > Save Plot As > Postscript or Image File.
• To print the histogram window, select File > Print.
The interaction is similar to that for outputting plots, but no annotation is allowed.
For instructions, see “Display Output Options” on page 398.
Saving Stretch LUTs
Stretch Look-up-Tables (LUTs) can be saved to either an ASCII format file or an
ENVI format file.
• To save a LUT, select File > Save Stretch to LUT > ASCII LUT or ENVI
Default LUT in the Interactive Contrast Stretching dialog.
Choosing ASCII LUT saves the look-up-table to a file as a single column of
ASCII data with the parameters “Binsize” and “Data Min” at the top of the file.
The first value in the data column corresponds to the LUT value for the input
data minimum. The next value is the LUT value for the input data minimum
plus the binsize and the remaining values in the column are saved in the same
manner up to the input data maximum value.
Choosing ENVI Default LUT saves the LUT to an ENVI binary format file.
This file is automatically named with the input filename and a .lut extension
and saved in the same directory as the input file (or in the alternate header
directory). When the data band is displayed in ENVI, this LUT will be
automatically used as the default stretch.
Figure 4-34: Access interactive analysis tools from the Tools menu.
Linking Images
Use Link to link and unlink images. When images are linked, actions such as moving
the zoom box, the scroll box, changing the zoom factor, or resizing one image
window are mirrored in all other linked image windows. Ideally, link images only
when they are the same size or when one image is a subset of the other image.
However, ENVI allows you to specify the link pixel regardless of the relationship
between images.
1. From the Display menu, select Tools > Link > Link Displays.
Note
To use the link function, you must have at least two image windows open. The Link
option is not available when only one image is displayed.
2. When a Link Displays dialog appears, select from the list of available displays
by using the arrow toggle button for each available display to select “Yes” or
“No.”
3. Specify the link pixel for each image by specifying the Link “xoff” (x offset)
and “yoff” (y offset) parameters in pixels measured from the upper left (1,1)
corner of each image.
4. Select the base image for the link by choosing the appropriate display from the
“Link Size/Position” menu.
5. Click “OK” to execute the link.
All other images are sized and positioned to correspond to the base image.
• If you already have images linked and want to link another image, open the
Link Displays dialog and select “Yes” for that display using the arrow toggle
button.
• To remove a single display window from the link, select
Tools > Link > Unlink Display in that image window.
The other windows remain linked.
1. From the Display menu, select Tools > Link > Dynamic Overlay.
The Link Displays dialog appears.
2. Select from the following options and see Table 4-4 for a summary of mouse
button functions when dynamic overlays are on and Table 4-5 for a summary
of mouse button functions when two images are linked but dynamic overlays
are turned off.
Note
If you do not have a three button mouse, you must have some way of emulating the
multiple mouse clicks. See “Emulating a Three-Button Mouse” on page 33 for
instructions.
• To show a small portion of a second linked image (the overlay) in the first
image (the base), click the left mouse button in any of the linked images.
• To cause the multiple overlays to cycle, successively displaying each
linked image as an overlay on the base image, hold down the left mouse
button and simultaneously click the middle mouse button.
• To move the overlays around inside a specific image and compare the two
images, click and hold the left mouse button and move the cursor in the
image (Table 4-4).
• To change the size of the overlay, press the middle mouse button and drag
the corner of the overlay and release the button.
• After resizing, use the left mouse button to reposition the overlay.
• To do a quick comparison of the images, repeatedly click and release the
left mouse button to activate the overlay effect.
• For multiple images, cycle through the overlays using the left and middle
buttons together as described above.
• Select Tools > Link > Dynamic Overlay Off to turn off the “flickering”
feature (see Table 4-4).
• When displays are linked, the zoom window can still be repositioned by
clicking and dragging using the left mouse button when the cursor is
within the zoom box outline in the Main Image window (see Table 4-5).
Left Click and drag the overlay (exception - the zoom box
functions as shown in Table 4-5 below).
Middle Resize the overlay.
Right Click to display the shortcut menu.
Left + Middle Cycle multiple overlays.
Table 4-4: Mouse Button Functions for Linked Images When Dynamic
Overlays Option is On.
Table 4-5: Mouse Button Functions For Linked Images when Dynamic
Overlays Option is Off.
1. Select Tools > Link > Geographic Link from the Main Image Display menu.
2. In the Geographic Link dialog, select the displays to link together by clicking
the arrow buttons to select “On” next to the display name(s).
3. Click “OK.”
When you move the cursor in one georeferenced image or vector window, the
cursor in all other georeferenced images and vector windows will move to the
same map location.
• To turn the geographic link off, select Tools > Link > Geographic Link and
click the arrow buttons to select “Off” next to the display name(s).
3. Once the X or Y profile has been extracted, press and hold the left mouse
button in the profile plot and move the cursor to mark the current position on
the profile with cross-hair cursor in the image.
The zoom box cross hair concurrently tracks the location in the profile on the
Scroll, Main and Zoom window and the Main and Zoom images are updated to
match the position of the cursor along the profile.
Extracting Z Profiles
Use ENVI’s “Z” profiles to interactively plot the spectrum (all bands) for the pixel
under the cursor. Spectra can be extracted from any multispectral data set including
MSS, TM, and higher spectral dimension data such as GEOSCAN (24 bands),
GERIS (63 bands), and AVIRIS (224 bands).
Vertical Plot bars in the Z Profile window show which band or RGB bands are
currently displayed in the display window. The band(s) shown in the display window
can be interactively changed by moving the plot bars to new band positions.
For data sets with fewer than approximately 50 spectral bands, the extraction and
plotting of spectra are fast enough that a BSQ data file can be used. For higher
spectral dimension data sets such as hyperspectral data, use of a BIL or BIP file
allows real-time extraction of spectra (see “Converting Data (BSQ, BIL, BIP)” on
page 423).
Note
Use of the BIL data format is recommended for hyperspectral data sets because it
produces a response similar to the BIP data for spectral plotting and browsing and
yet is much faster than BIP format for image display.
1. From the Display menu, select Tools > Profiles > Z Profile (Spectrum).
2. Select a pixel in either the Main Image window or the Zoom window to plot
the corresponding spectrum in the plot window.
A vertical line (plot bar) on the plot marks the wavelength position of the
currently displayed band. If a color composite image is displayed, three
colored lines appear, one for each displayed band in the band’s respective
color (RGB).
Browsing Spectra
• To perform spectral browsing, click on the zoom box using the middle mouse
button, hold it, and drag the box across the image.
be plotted. The two plot windows will appear with one on top of the other so you
will have to move one window.
• To define another arbitrary profile, click the left mouse button in the image
again to define the new vertices.
The new profile will be drawn and plotted in a new color in a new plot window.
Saving Transects to an Annotation Files
Use this procedure to save arbitrary profile lines drawn on the image to an
annotation file.
1. In the Spatial Profiler dialog, select File > Save Annotation.
2. When the file selection dialog appears, enter a filename.
Activating the Measurement Tool
1. In the Spatial Profiler dialog, select Options > Measurement Report.
The Profile Measurement Report dialog appears with a list of the distances
between the vertices and the total distance when the profile is completed.
2. Choose from options under the four pulldown menus to save the measurement
information to a file, change the units used to report the distances, and select
whether to report the segment distances or the point coordinates. See
“Reporting ROI Measurements” on page 275 for more details.
Figure 4-39: The Input ASCII File and Input Spectral Library dialogs.
• To change the color of the plotted line, select from the “Colors” menu.
• To select the style of the line (e.g., dotted, dashed, solid), choose from
“Line Style” menu.
• To set the thickness of the line, use the “Thick” parameter box to adjust the
value or enter a new value.
• To set the number of points to average in the X direction (smoothing) when
plotting the data, enter the value in the text box labeled “Nsum” and press
the “Return” key.
• To select the symbol type, select from the “Symbol” menu.
• To control the size of the displayed symbols, use the “SymSize”
text box.
• To display the line along with the selected symbols or display only the
symbols, use the arrow toggle buttons “Symbol & Line” or “Symbol
Only.”
3. Click the “X-Axis” and “Y-Axis” toggle buttons to select the axis being acted
upon.
4. Enter the title in the “Axis Title” text box and press the “Return” key.
5. Change the axis parameters by selecting from the following steps:
• To change the thickness, enter a new value (“1” is normal thickness) in the
“Thick” text box.
• To position the minimum and maximum values of the full data range
exactly at the ends of the axis, click the Style “Exact” check box.
• To offset the values slightly offset from the ends of the axis, click the Style
“Extend” checkbox.
• To turn off the selected axis entirely, click the Style “Off” checkbox.
• To turn off the top X axis or the right Y axis, depending on which axis is
selected, click the Style “No Box” checkbox.
• To change the axis data range to be displayed, type in the respective
minimum and maximum into the text boxes labeled “Range” and “To” and
press the “Return” key. (For spectral plots, the plot range for the Y axis can
also be set in the .hdr file by entering the values for the “Z Plot Range”
parameter. See “ENVI Header Format” on page 879).
• To plot the tick marks on the inside or outside of the axis, click the “Tick
Style” “In” or “Out” toggle button.
• To plot a continuous line across the entire plot at the location of each major
tick mark click the “Tick Style” “Grid” toggle button.
• To turn off the tick marks entirely, click Tick Style “Off.”
• To change the length of the major tick marks when they are present, enter a
value between 0 and 0.5 in the parameter box labeled “Len,” and the
number of minor tick marks in the “Minor” textbox.
Lengths are measured as a ratio of the axis length normalized to 1.0. For
example, a length of 0.02 results in ticks that are 2% of the length of the
entire axis. A length of 0.5 results in lines drawn across 50% of the plot
that meet in the middle (the equivalent of the grid option).
• To control the size of the margins around the plot axes, enter the margin
size (in characters) in the two parameter boxes next to the “Margin” label.
For the X axis, the first box is the left margin, the second box the right
margin. For the Y axis, the first box is the bottom margin, the second box
the top margin.
• Select either “Auto” or “Fixed” next to the label “Tick Marks.”
The “Auto” option places a predetermined number of major and minor
ticks on the axis. Major tick marks are labeled. The “Fixed” option allows
you to enter the axis parameters. This includes the starting and ending
major ticks, the tick increment between the major ticks, and the number of
minor ticks between major ticks.
6. Click “Apply” and “Cancel” to close the plot window when all parameters
have been set to the desired values.
Annotating Plots
Use Annotate Plot to annotate the X, Y, and Z profiles and other plots. The annotation
function is the same as that for images but without the image-specific annotation
objects, and is described in detail elsewhere (“Annotating Images” on page 222).
Tip
Resize both plot and image windows to their final desired size prior to annotation.
If the plot window is resized after starting annotation, then the annotated objects
will be offset from their correct positions.
Note
If auto scaling is off and a plot is added outside the y-axis range set, then that plot
will not be visible until the y-axis is rescaled.
Clearing Plots
The Clear Plot selection appears under the Options menu in plot windows if they
were created using ENVI spectral library functions or using New Window.
• To clear all of the displayed plots within one of these windows, select
Options > Clear Plot.
Note
Profiles can not be cleared because they contain the profile for the current pixel.
3. Click the arrow increment buttons to set the numeric precision for the X and Y
output ASCII variables.
4. Click the arrow toggle button to select whether to output floating point data
in “Scientific” or “Normal” format.
5. Enter the output name in the text box labeled “Enter Output Filename” or click
the “Choose” button to select a filename.
6. Click “OK” to save the selected spectra to the ASCII file.
Outputting Plot Data to Spectral Libraries
Use this procedure to build a standard ENVI spectral library file (spectral library
image) from profiles and spectral plots.
1. Select File > Save Plot As > Spectral Library.
2. When the Output Plots to Spectral Library dialog appears, choose the desired
spectra by clicking on the spectrum name.
3. Select “File” or “Memory” output.
4. Click “OK” to save the selected spectra to the Spectral Library.
Exporting Plot Data to the IDL Command Line
Note
If the ENVI command line is not visible in the IDL window, select Window >
Command Input in the IDL window.
1. From the plot window select File > Save Plot As > IDL Variable.
The Export Plots to IDL Variable dialog appears.
2. Select the Plots to Export by clicking on the plot names.
3. Select one of the following options:
• If previous variables have been defined, click on the name of the variable
in the displayed list.
• In the “New Variable Name” dialog, enter the name of an undefined IDL
variable.
4. Press the ENTER key on your keyboard.
The exported data will be available to use at the ENVI command line. If data
from more than one plot were exported to a single variable the data will be
exported into a two-dimensional array that contains the x and y values for each
plot. The first row, array [∗,0], contains the x values for the first plot, the
second row, array [∗,1], contains the y values for the first plot, the third row,
array [∗,2], contains the x values for the second plot, etc.
To extract and display polarization signatures from the current pixel for quad-
polarized radar data (AIRSAR and SIR-C):
1. From the Display menu, select Tools > Polarization Signatures > AIRSAR or
SIR-C.
The radar data does not have to be displayed. Any co-registered image data set
can be used for pixel location.
2. When the Input Stokes Matrix Files dialog or the Input Scattering Matrix Files
dialog appears, click “Open File” to select and open the appropriate radar data
file.
3. Click “OK.”
4. When the Polarization Signature Viewer appears, select Options > Extract
Current Pixel to plot the polarization signature for the current pixel.
For details about the Polarization Signature Viewer, see “Extracting
Polarization Signatures from Single Pixels” on page 842 and “Using the
Polarization Signature Viewer” on page 845.
Color Mapping
Use Color Mapping to apply color tables to images, create interactive density sliced
images, control the RGB image planes and to change classification color mapping.
Note
A color image displayed using one of the methods outlined in this section can be
saved to an RGB color image. For instructions, see “Outputting to Image Files” on
page 402.
1. From the Display menu, select Tools > Color Mapping > ENVI Color Tables.
The ENVI Color Tables dialog appears, where you may adjust the screen color
tables using the default color tables (see Figure 4-42). The dialog contains a
grayscale wedge (or color wedge if a color table is applied) and two sliders to
control the contrast stretch. It also has two pulldown menus, File and Options.
2. Select one of the following options:
• To have any color table changes applied to your images automatically,
select Options > Auto Apply: On.
• To have changes applied manually, select Options > Auto Apply: Off. After
making changes, select Options > Apply.
Note
The Auto Apply option is automatically set in 8-bit mode.
3. Move the sliders labeled “Stretch Bottom” and “Stretch Top” respectively to
control the minimum and maximum values to be displayed.
Moving the Stretch Bottom slider to the right causes bright areas of the image
to become darker, while moving the Stretch Top slider to the left causes dark
areas of the image to become brighter.
The stretch can be “inverted” by setting the stretch bottom to the maximum
value and the stretch top to the minimum value.
If Auto Apply is on, the new contrast stretch is applied to the image
immediately.
4. Apply a selected color table automatically to the current image by clicking on
the desired color table name.
ENVI provides a number of pre-saved color tables. The “B-W linear” table
provides a grayscale image. The “RAINBOW” color table provides a “cool” to
“hot” density slice. Other color table options allow you to apply their preferred
color scheme.
• To reset the original color tables and stretch, select Options > Reset Color
Table.
• To return you to the main screen and retain the selected color table, select
File > Cancel.
Saving Color Tables to ASCII Files
1. In the ENVI Color Tables dialog, select File > Save Color Table to ASCII.
2. Enter a filename and click “OK.”
3. Enter the desired minimum and maximum values in the appropriate text boxes
to change the density slice range.
• To reset the data range to the initial values, click “Reset.”
4. Select whether the density slice colors are applied to the image window, scroll
window, or both windows by selecting the desired check boxes next to
“Windows” at the bottom of the dialog.
5. Click “Apply” to apply the default ranges and colors to the image.
• To remove a range from the list, select the data range and click “Delete
Range.”
• To clear the list of density slice ranges, click “Clear Ranges.”
Editing Data Ranges
To change the range values or color of a density slice:
1. In the Density Slice dialog, highlight a data range and click “Edit Range.”
The Edit Density Slice Range dialog appears. The dialog choices are different
depending on whether you are using a 24-bit or 8-bit display.
2. Select one of the following options:
• If you have an 8-bit display, enter the desired minimum and maximum
values and select a color from the “Colors” menu.
• If you have a 24-bit display, select RGB, HLS, or HSV as your color
system from the “System” button menu. Use the slider bars or the arrow
increment buttons to set you own color definitions.
3. Click “OK” to make the changes to the range in the “Defined Density Slice
Ranges” list.
4. Click “Apply” to apply the new ranges and colors to the image.
Figure 4-42: ENVI Color Tables and Interactive Density Slicing dialogs.
6. Select one of the following options to set the values of the class colors:
• Select a color from the "V" menu.
• Move the three sliders (0-255 for the three colors in RGB).
• Click the arrow increment buttons to change the values or enter new values
into the text boxes and press “Enter.” See Figure 4-44.
7. Select Options > Save Changes to save the changed classification names and
colors to the classified image header file.
• To reset the original class colors and names, select Options > Reset Color
Mapping.
Note
Color changes on 24-bit color displays, are not automatically applied. Instead,
select Options > Apply.
Figure 4-45: The Pixel Locator dialog for pixel-based images and for
georeferenced images.
Collecting Points
Use Point Collection to collects points (both pixel locations and map locations) from
display windows. The points are displayed in a table in the ENVI Point Collection
window. You can save points from various display windows in a single table and
export them to the Ground Control Points (GCP) List, save them to ASCII or ENVI
Vector Files (EVFs), and restore them from ASCII files.
1. Select one of the following options to begin:
• From the Display menu, select Tools > Point Collection.
• From the ENVI main menu, select Window > Point Collection.
The ENVI Point Collection window appears (see Figure 4-46).
2. Click the middle mouse button in a main image window or zoom window to
collect the point under the cursor.
The pixel locations appear in the table. If the data is georeferenced, map and
geographic locations are also listed.
Click on
a column
heading
to resort
the table.
Measurement Tool
Use Measurement Tool to get a report on the distance between points in a polygon or
polyline, and to get perimeter and area measurements for polygons, rectangles, and
ellipses. For detailed instructions, see “Using the Measurement Tool” on page 437.
Note
To measure ROIs while using the ROI function, see “Reporting ROI
Measurements” on page 275.
2. In Zoom window, click on a pixel or enter the sample and line coordinates of
the pixel for which you want the line of sight calculated.
• To select a different pixel, use the solid black arrow buttons to move the
Zoom window cross-hairs in single pixel increments in the corresponding
direction.
• To designate whether or not to apply X and Y offsets for data that has
offsets, select Options > Use Image Offset:Yes or No.
• To select pixels for georeferenced images, see “Selecting Pixels for
Georeferenced Images” on page 373).
3. Click the “Apply” button.
The Select Line of Sight Input DEM Band dialog appears.
4. Select the file that contains the DEM that is associated with the displayed
image and click “OK.”
The Line of Sight Parameters dialog appears (Figure 4-48).
5. Enter the maximum distance (in meters) for the line of sight calculation.
• To designate an elevation above the pixel, enter the value in the same units
as the DEM.
6. Click “OK.”
An ROI is created that shows which pixels can be seen from the designated pixel. The
ROI is labeled LOS in the ROI Tool dialog and is overlaid on your image.
• From the Display menu, select Tools > Spatial Pixel Editor.
The Spatial Pixel Editor dialog appears with the pixel values for the Zoom
window shown in a table. The sample and line numbers are shown around the
top and side of the table. The location of the pixel highlighted in the table is
shown by a green box in the zoom window.
Selecting Pixels
To select pixels and display their values in the Spatial Pixel Editor table:
• In the Main Image window, move the zoom window by clicking and dragging
with the left mouse button or click the middle mouse button on a pixel to place
it in the center of the zoom window.
Creating Animations
Use Animation to create a “movie” out of images from one or more open files.
• To select additional bands from files of the same size, click on the bands
with the left mouse button while holding the CTRL key on your keyboard.
• To clear individual bands from the list if they are already selected, click on
the desired band with the left mouse button while holding the CTRL key
on your keyboard.
• To use standard ENVI subsetting procedures to reduce the size of the
image to be animated, click “Spatial Subset.”
3. Set the desired size of the animation display window by entering values in the
boxes next to the “Window Size” text label.
Note
Note that the selected images are automatically resized to the selected window size.
Reducing either the spatial subset to be animated and/or the size of the animation
window enhances the speed of the animation.
When the animation is activated, the individual selected bands are automatically
subset, resampled, and loaded into the Animation widow. A status bar appears as
each image is processed.
After all of the selected images have been loaded, the animation starts automatically.
Each selected band is displayed sequentially.
Figure 4-51: The Animation window with menu bar and controls.
Saving Animations
You can save an animation as an MPEG (Moving Picture Experts Group) file.
1. Select File > Save Animation as MPEG.
2. From the “MPEG Frame Rate” button menu, select a frame rate in frames per
second.
3. In the “MPEG Quality” text box, enter a compression quality value between 0
and 100, or use the arrow buttons to set the value.
The compression is a lossy compression where 0 is lowest quality and 100 is
highest quality (no compression). Entering a compression quality factor less
than 100 decreases the amount of disk space used to store the MPEG output.
• To duplicate frames in the MPEG output, enter or select a duplication
factor.
A duplication factor helps to make the MPEG output appear smoother.
4. Enter or choose an output filename and click “OK.”
Cancelling Animations
• To cancel the animation at any time, select File > Cancel from the menu in the
Animation window.
Depending upon the size of the image, there may be a brief delay while the DN
values are extracted and tabulated. As soon as the scatter plot appears, the interactive
scatter plot function is available for use.
• To reset the window to the default size, select Options > Reset Size.
3. Press and hold the left mouse button while moving the cursor in the Main
Image window to highlight the pixels in the scatter plot in real time as Dancing
Pixels (Figure 4-54).
Figure 4-54: Selecting Pixels to Highlight in the Image Window (left) and
“Dancing Pixels” as Displayed in the Plot Window (right).
Note
If a Z profile is associated with the scatter plot, the density distribution is shown by
clicking the right mouse button outside the plot axes.
Editing Classes
To remove pixels from an existing class:
1. In the Scatter Plot window, select Class > White.
2. Draw a polygon around the pixels to remove them.
The deleted pixels return to white.
Changing Class Colors
Use the Class menu to change the color of the scatter plot highlighting. Multiple
ROIs or classes can be defined by selecting a new color for each class. The currently
selected class corresponds with the color selected under the Class pulldown menu.
Deleting Classes
• To completely delete the selected class polygon, click the middle mouse button
outside the scatter plot axes.
Clearing Classes
• To remove the ROIs and associated image window highlighted pixels from the
scatter plot and image window for the selected class color, select Options >
Clear Class.
• To remove all the ROIs and associated image window highlighted pixels from
the scatter plot and image window for all the classes, select Options > Clear
All.
Exporting Classes
Use Exporting Classes to export the highlighted image window pixels for the
selected class color or for all of the classes to a standard ENVI ROI. You can use the
exported ROI in other ENVI functions.
• To export a selected class, select Options > Export Class.
If the ROI Controls window is on the screen, the region is listed as a “Scatter
Plot Import.” The class color and number of pixels in the region is also listed.
The ROIs are retained in memory even when the ROI Controls window is not
on screen. The Scatter Plot Import region will be listed in the ROI window the
next time it is started.
• To export the highlighted image window pixels for all of the classes, select
Options > Export All.
Calculating Mean Spectra
To calculate the mean spectrum for the selected class or for all the defined classes:
1. Select Options > Mean Class or Options > Mean All.
2. When the Input File Associated with 2-D Scatter Plot dialog appears, select the
corresponding input file.
The mean spectra are calculated and displayed in a plot window. If a Z Profile
window associated with the scatter plot is open, the same data is automatically used
to calculate the mean spectra.
Attaching Z Profiles
To associate a Z Profile window (spectral plot) with the scatter plot:
1. Select Options > Z Profile.
2. When the Input File Associated with 2-D Scatter Plot dialog appears, select the
corresponding input file.
3. Click the right mouse button inside the scatter plot to display the spectrum for
the point nearest the cursor.
See “Extracting Z Profiles” on page 338 for details on using Z Profiles.
Setting “Patch Sizes”
The “patch size” is the size of the box used for the “Dancing Pixels” options.
1. Select Options > Set Patch Size.
2. When the Scatter Plot Patch Size dialog appears, enter the number of pixels to
use for the size of the patch (a square box) or use the increment arrows to set
the desired size.
For example, a patch size of “10” refers to a 10 x 10 pixel box in either the image or
the scatter plot.
Changing Bands
Use Change Bands to change the bands used in the scatter plot and to plot previously
defined classes on the new scatter plot. The corresponding image window pixels will
be highlighted.
1. Select Options > Change Bands.
2. When the Scatter Plot Band Choice dialog appears, choose new X and Y axes
for the scatter plot by clicking on the desired bands as described in “Selecting
Bands for Scatter Plots” on page 382.
Managing Displays
Use the Display Window menu to open, close, resize, and rearrange displays, and to
extract information from the open displays.
Figure 4-56: Access display management options from the Window menu.
The same Cursor Location/Value window is used for all open displays. Both the
“Scrn:” (stretched image) and the “Data:” (raw data) values are listed. If an RGB
image is displayed, then the values for all three bands are listed. If an image is
georeferenced, then the appropriate projection name and the map coordinates and
latitude and longitude are also listed. If a Classification image is displayed, the class
names will be reported along with the cursor location and value. When display
windows are linked, the Cursor Location/Value dialog will display the data values for
the current pixel for all the display windows included in the link.
Select one of the following options to open the Cursor Location/Value window:
• In the Main Image window, double-click with the left mouse button.
• From the Display menu, select Tools > Cursor Location/Value.
• From the Display menu or from the ENVI main menu, select Window >
Cursor Location/Value.
Figure 4-57: Cursor Location/Value dialogs. The dialog on the right shows the
cursor location for a georeferenced image. UTM coordinates are listed in
Easting, Northing. UTM zone is 12.
Select one of the following options to open the Mouse Button Descriptions window:
• From the Display menu or from the ENVI main menu, select Window > Mouse
Button Descriptions.
• From the ENVI main menu select Help > Mouse Button Descriptions.
1. In the Output Display to Postscript File dialog, set the page size by entering the
desired dimensions in the text boxes labeled “Page.”
2. Set the output image size on the page by entering the desired values into the
“xsize” and “ysize” labeled text boxes.
• To maintain the relative aspect between X and Y when one dimension is
changed, select the “Aspect” check box.
3. Set the position of the image origin on the page (with respect to the lower left
corner) using the “xoff” and “yoff” parameters.
An outline of the image showing its relative size and position on the page
appears within the draw window in the upper right of the dialog.
• To position the image on the output page using your mouse, click and hold
the left mouse button inside the image outline in the draw window and
drag the image to a new position.
• To center the image outline on the page using your mouse, click the right
mouse button anywhere on the output page.
4. Click on the arrow toggle button to select “Landscape” or “Portrait” as the
page orientation.
5. Select from the following options.
• To scale an image to a specified map scale, enter the desired scale in the
“Map Scale 1:” text box.
The “xsize” and “ysize” values will change automatically based on the
image pixel size (a default size of 30 meters is assumed if no pixel size is
present in the header).
• To toggle color on or off, select or de-select the “Color” check box.
• To select encapsulated postscript output, click the “Encapsulate” check
box.
• To select the number of output bits for the postscript image use the “Bits”
pulldown menu.
Setting Graphics Overlay Options
Graphics options (annotations, grid lines, regions of interest, vectors, etc.) can be
“burned into” (permanently incorporated in) the saved PostScript file. All currently
displayed valid ENVI graphics objects are automatically selected when the Output to
PostScript File dialog is started. A border is automatically placed on the output image
if grid lines are selected. The grid text-labels are placed exterior to the image.
Note
The grid must have been previously displayed and configured on the image by
selecting using the Grid Lines overlay option (see “Grid Lines” on page 256 for
further information).
1. In the Output Display to Postscript File dialog, click on the “Change Graphic
Overlay Selections” button.
The Change Graphics Overlay Options dialog appears with a list of the
currently displayed graphics objects.
2. Change the graphic overlay selections using the following options:
• To remove a graphics overlay, click on its name in the Currently Selected
Options list.
• To add graphics overlays, select the desired overlay using the “Add
Graphics Option” pulldown menu (with the exception of annotation, these
overlays must be displayed on your image or plot).
• To add an annotation file that is not currently displayed to the graphics
overlay, select “Additional Annotation File” from the “Add Graphics
Option” pulldown menu and select the desired annotation filename.
3. Click “OK” to return to the Output to Postscript File dialog.
• To clip all graphics at the edge of the page when multiple pages of output
are generated, select the “Clip Graphics” check box.
Subsetting and Resizing Output Images
• To select a spatial subset of the image to be output, click on the “Spatial
Subset” button (see “Selecting a Spatial Subset” on page 45).
• To resize the image, enter a resize factor (less than 1 for subsampling) in the
“Input Image Resize Factor” text box.
Applying Masks
In the Output Display to Postscript File dialog, you have the option of applying a
predefined mask to your output image. This means that if you want to apply a mask to
the image, you do not need to do it before selecting the output options.
1. In the Output Display to Postscript File dialog, click the “Select Mask” button.
2. Select the input band for the mask.
3. In the “Background” “R,” “G,” and “B” boxes, enter desired color values that
you want to use where the mask is turned off.
4. Click “OK.”
• To clear the selected mask and output a complete image, click the “Clear
Mask” button.
Saving Output Files
1. Enter the output filename or use the “Choose” button to select the output
filename.
2. Click “OK” when all options are correctly set.
If the parameters you have chosen result in multiple page output, the filename is used
as a root filename, and numbers designating the position of the multiple pages in the
composite image are appended to the filename. For example, an image with 6 pages
(3 columns by 2 rows), using the file root name “test” creates the output files
test_11, test_12, test_21, test_22, test_31, and test_32, where the first
appended number indicates the column, and the second appended number indicates
the row.
(resolutions) include 8-bit gray scale, 8-bit with an associated color table, and 24-bit
BSQ (band sequential), BIL (band interleaved by line), and BIP (band interleaved by
pixel) formats.
• To select the desired output file type, use the “Output File Type” button menu.
Note
When you output a georeferenced image to a JPEG file, an associated .jgw file is
also created to contain the TIFF World File information. When you open a JPEG
file (using File > Open External File > Generic File Formats > JPEG) that has a
.jgw file associated with it, ENVI reads the map information from .jgw file.
• Select the desired output format and resolution using the “Resolution” button
menu.
Printing
ENVI allows output of the image display, plot, and vector windows directly to
system printers. You should be able to output to any of your system printers or
plotters through your native system printer dialog.
1. Select one of the following options:
• To output a displayed image to a system printer, select File > Print from
the Display menu.
• To output a plot or vector window to a system printer, select File > Print
in the plot or vector window.
2. When the Print setup dialog appears, set any options specific to your system
and click “OK.”
3. When the Output Display to Printer dialog appears, you will have several
options for setting the output display parameters. See the following
subsections for detailed instructions.
4. After setting the parameters, click “OK” in the Output Display to Printer
dialog to print the image or plot.
Selecting Output Print Sizes
You can set the output X or Y print size or set the desired output map scale if a
georeferenced image is displayed. When a size is set, the other size parameters will
change to preserve the aspect ratio of your image.
1. In the Output Display to Image File dialog, set the output image size on the
page by entering the desired values into the “xsize” and “ysize” labeled text
boxes.
• To maintain the relative aspect between X and Y when one dimension is
changed, select the “Aspect” check box.
2. Set the position of the image origin on the page (with respect to the lower left
corner) using the “xoff” and “yoff” parameters.
An outline of the image showing its relative size and position on the page
appears within the draw window in the upper right of the dialog.
• To position the image on the output page using your mouse, click and hold
the left mouse button inside the image outline in the draw window and
drag the image to a new position.
• To center the image outline on the page using your mouse, click the right
mouse button anywhere on the output page.
3. Click on the arrow toggle button to select “Landscape” or “Portrait” as the
page orientation.
4. Select from the following options.
• To scale an image to a specified map scale, enter the desired scale in the
“Map Scale 1:” text box.
The “xsize” and “ysize” values change automatically based on the image
pixel size (a default size of 30 meters is assumed if no pixel size is present
in the header).
Subsetting and Resizing Output Images
• To select a spatial subset of the image to be output, click on the “Spatial
Subset” button to perform typical ENVI subsetting (see “Selecting a Spatial
Subset” on page 45).
• To resize the image, enter a resize factor (less than 1 for subsampling) in the
“Input Image Resize Factor” text box.
Setting Graphics Overlay Options
Graphics options (annotations, grid lines, regions of interest, vectors, etc.) can be
“burned-into” (permanently incorporated in) the print. All currently displayed valid
ENVI graphics objects are automatically selected when the Output Display to Printer
dialog is started. A border is automatically placed on the output image if grid lines are
selected. The grid text-labels are placed exterior to the image. Note the grid must
have been previously displayed and configured on the image using the “Grid Lines”
option on the Display Menu (see “Grid Lines” on page 256).
1. In the Output Display to Printer dialog, click on the “Change Graphic Overlay
Selections” button.
The Change Graphics Overlay Options dialog appears with a list of the
currently displayed graphics objects.
2. Change the graphic overlay selections using the following options:
• To remove a graphics overlay, click on its name in the Currently Selected
Options list.
• To add graphics overlays, select the desired overlay using the “Add
Graphics Option” pulldown menu (with the exception of annotation, these
overlays must be displayed on your image or plot).
• To add an annotation file that is not currently displayed to the graphics
overlay, select “Additional Annotation File” from the “Add Graphics
Option” pulldown menu and select the desired annotation filename.
3. Click “OK” to return to the Output Display to Printer dialog.
Applying Masks
In the Output Display to Printer dialog, you have the option of applying a predefined
mask to your output image. This means that if you want to apply a mask to the image,
you do not need to do it before selecting the output options.
1. Click the “Select Mask” button.
2. Select the input band for the mask.
3. In the “Background” “R,” “G,” and “B” boxes, enter desired color values that
you want to use where the mask is turned off.
4. Click “OK.”
• To clear the selected mask and output a complete image, click the “Clear
Mask” button.
Spatially Subsetting
You can select a spatial subset by entering the numbers of samples/lines, by selecting
the subset directly from the image, by using another file’s subset, by selecting
map coordinates (for georeferenced images only), or by using the bounding box
around a Regions of Interest(s).
Selecting by Samples/Lines
1. In the File Subset Input File dialog, click “Spatial Subset.”
The Spatial Subset dialog appears with the file information listed at the top of
the window.
• To use the same spatial subset previously entered for a file with the same
spatial size, click the “Previous” button.
2. Change the number of samples and/or lines for the output image by entering
the starting and ending values into the text boxes labeled “Sample” and/or
“lines” respectively or by entering the desired number of lines or pixels in the
boxes labeled “NS” or “NL” respectively.
The size of the original data set (in bytes) and the size of the subset are shown
below the data entry text boxes.
3. Click “OK.”
4. After selecting and subsetting an input file, click “OK” in the File Subset Input
File dialog.
The File Resize Parameters dialog appears with information about the input file listed
at the top of the dialog. The output file dimensions specified by the subsetting
procedure are also displayed.
• To move the box around the image, click on the box and drag it to the
desired location. Or, click with the middle mouse button to center the box
on the cursor.
4. Click “OK.”
5. After selecting and subsetting an input file, click “OK” in the File Subset Input
File dialog.
The File Resize Parameters dialog appears.
Subsetting by Map Coordinates
If your image is geo-referenced, you may select the subset by map coordinates or
latitude/longitude coordinates:
1. In the File Subset Input File dialog, click “Spatial Subset.”
2. In the Spatial Subset dialog, click on the “Subset By Map” button.
The Spatial Subset By Map Coordinates dialog appears.
3. Enter the upper left coordinate and lower right coordinate in the appropriate
text boxes.
4. Use the arrow toggle buttons next to the map projection label to select the
subset by map coordinates.
• For the UTM projection, indicate if the selected latitude is north (N) or
south (S) of the equator by selecting the appropriate button (the zone is
calculated automatically).
• For other map projections, enter latitude and longitude. Negative (-)
latitude indicates the Southern Hemisphere and negative (-) longitude
indicates the Western Hemisphere. (Entering the UTM zone assigns the
appropriate sign to the longitude.)
5. Click “OK.”
6. In the Spatial Subset dialog, click “OK.”
7. After selecting and subsetting an input file, click “OK” in the File Subset Input
File dialog.
The File Resize Parameters dialog appears.
Subsetting Using Another File’s Subset
There are two options for subsetting a file based on the subset area of a previously
subset image: use the first option to subset your image based on a subset of an image
that was originally the same size as the one you are subsetting; use the second to
subset your image based on an image of the same or smaller size that was previously
subset by map or pixel values.
Using the Subset of an Image of the Same Size
• To use the same spatial subset previously entered for a file with the same
spatial size, click the “Previous” button.
Using the Subset of an Image of the Same or Smaller Size
1. In the Select Spatial Subset dialog, click the “File” button.
2. In the file selection dialog, select the previously subsetted file (which must
have originally been the same size as or smaller than the file you are currently
subsetting).
The input file will be subset based on the subset parameters of the file you
select.
Subsetting Using ROIs
To subset a file using the bounding box (i.e., the area encompassing) an ROI or group
of ROIs, follow these steps:
1. In the Select Spatial Subset dialog, click the “ROI” button.
Tip
To make previously saved ROIs available for selection in the Subset Image by ROI
Extent dialog, click the “Restore ROIs” button in the Select Spatial Subset dialog
and select the ROI file in the subsequent file selection dialog.
Figure 5-3: In the Subset Image by ROI Extent dialog, select the ROI(s) to use
as the area of a spatial subset.
2. In the Subset Image by ROI Extent dialog, select the ROI(s) and click “OK.”
The file will be subset to the area encompassing the selected ROI(s).
Spectrally Subsetting
1. In the File Subset Input File dialog, click the “Spectral Subset” button.
The standard File Spectral Subset dialog appears with the file information
listed at the top o f the window.
2. Select specific bands to include in the subset by clicking on the band names or
by selecting ranges of bands.
• To select the same spectral subset used in a previous subsetting of a
different file with the same number of spectral bands, click the “Previous”
button.
3. Click “OK.”
4. After selecting and subsetting an input file, click “OK” in the File Subset Input
File dialog.
The File Resize Parameters dialog appears with information about the input file listed
at the top of the dialog. The output file dimensions specified by the subsetting
procedure are also displayed.
• If you enter xfac and yfac values greater than or equal to 1, select “Nearest
Neighbor,” “Bilinear,” or “Cubic Convolution,” from the “Resampling”
button menu (see “Warping and Resampling” on page 714).
• If you enter xfac and yfac values less than 1, select from “Nearest
Neighbor” or “Pixel Aggregate” resampling only.
Nearest neighbor resampling uses the nearest pixel value as the output pixel
value and pixel aggregate averages all of the pixel values that contribute to the
output pixel (e.g., if you enter .5 for both xfac and yfac, the output pixel values
are calculated by averaging the four input pixel values).
2. Select either “File” or “Memory” output.
3. Click “OK” to start the operation.
The File Resize status window appears with the output filename listed and the
percent completed displayed.
Rotating Images
Use Rotate/Flip Images to perform several “standard” image rotations. These include
0, 90, 180, and 270 degrees with or without transposition. (Here, transpose means
that the dimensions of the array are swapped.) Alternatively, you can specify the
exact angle of the desired rotation. Rotating images is useful for orienting images
prior to registration.
Tip
To flip an image vertically, where the pivot line is a horizontal running through the
middle of the image, choose 270 degrees with transpose. To flip an image
horizontally, where the pivot line is a vertical running through the middle of the
image, choose 90 degrees with transpose.
Figure 5-5: The Rotation Parameters Dialog. Left - Standard IDL rotations and
transposes. Right - Arbitrary angle rotations.
Layer Stacking
Use Layer Stacking to build a new multiband file from georeferenced images of
various pixel sizes, extents, and projections. The input bands will be resampled and
re-projected to a common user-selected output projection and pixel size. The output
file will have a geographic extent that either encompasses all of the input file extents
or encompasses only the data extent where all of the files overlap.
1. Select one of the following options:
• From the ENVI main menu, select Basic Tools > Layer Stacking.
• From the ENVI main menu, select Map > Layer Stacking.
The Layer Stacking Parameters dialog appears.
3. Select input files and perform any spatial or spectral subsetting using standard
ENVI procedures.
4. Repeat the file selection using the “Import File” button for each input file to be
included in the new output file. Input files are listed in the “Selected Files for
Layer Stacking” list.
5. Click the “Inclusive” or “Exclusive” button to select the output file range.
The “Inclusive” range will create an output file with a geographic extent that
encompasses all the input file extents. The “Exclusive” range will create an
output file that contains only the data extent where all the files overlap.
6. Select an output map projection from the list.
7. From the “Resampling” button menu, select a resampling method.
8. Enter the desired x and y pixel sizes in the corresponding text boxes.
Note
The pixel sizes should be entered in the units selected under the map projection
section.
• To have the converted file written to a separate output file, select “No.”
5. Enter the output file name.
Stretching Data
Use Stretch Data to perform file-to-file contrast stretching. The data stretching
function is a flexible method for changing the data range of a given input file. You
have full control over both the input and output histograms and the output data type
(byte, integer, floating-point, etc.). For more information, see “Using Interactive
Stretching” on page 321.
1. Select Basic Tools > Stretch Data.
The Data Stretching Input File dialog appears.
2. In the list labeled “Select Input File,” select a filename.
Details of the file characteristics are shown in the text widget labeled “File
Information.”
3. Select spatial or spectral subsetting by clicking on the “Spatial Subset” or
“Spectral Subset” button, respectively.
4. Click “OK.”
The Data Stretching dialog appears.
• To calculate the statistics based on a spatial subset or the area under an
ROI, click the “Stats Subset” button. For instructions, see “Using Statistics
Subsetting” on page 428.
5. Select the values by percent or by value using the buttons at the top of the
window.
6. Enter the desired minimum and maximum values in the text boxes labeled
“Min” and “Max,” respectively, to control the input data range.
7. Select the stretch types (“Linear,” “Equalize” (histogram equalized),
“Gaussian,” and “Square Root”) by choosing the appropriate toggle button.
8. Set the output data range in the text widgets labeled “Min” and “Max”
under the “Output Data” label.
The values entered here must match the ranges of the data type selected from
the “Data Type” menu. If out-of-range values are entered, low values are
automatically corrected to the minimum and high values are automatically
corrected to the maximum of the selected data type.
• From the “Data Type” menu, select the appropriate data type (byte,
integer, unsigned integer, long integer, unsigned long integer, 64-bit
Statistics
Use Statistics on the Basic Tools menu to generate statistical reports for image files
and output plots of histograms, mean spectra, eigenvalues, and other statistic
information.
Computing Statistics
Basic statistics and/or tabulated histogram information (frequency distributions) can
be calculated for single-band or multi-band images. The minimum, maximum, and
mean spectra can only be calculated for multi-band images. Similarly, covariance
statistics, which include eigenvectors and a correlation matrix, can only be calculated
for multi-band images. The statistics are calculated in double precision.
1. Select Basic Tools > Statistics > Compute Statistics.
The Calculate Statistics Input File dialog appears.
2. In the “Select Input File” list, select the input file by clicking on the file name.
Details of the file characteristics are shown under “File Information.”
3. Select spatial or spectral subsetting by clicking on the “Stats Subset” or
“Spectral Subset” button, respectively. (For details about “Stats” subsetting,
see “Using Statistics Subsetting”, next.)
• To apply a mask to the data before calculating the statistics, click
“Mask Band” and select the desired mask image.
4. After the file has been selected, subsetted, and masked as desired, click “OK.”
The Calculate Statistics Parameters dialog appears.
5. Use the dialog to set report parameters as described in the following sections.
• To select a ROI as the subset, click the “Calculate Stats On” “ROI” button
to display a list of ROIs, then click on the ROI name to select it.
Tip
To add a previously saved ROI to the list of ROIs, click the “Restore ROIs” button
in the subset dialog, select the ROI file, then select the ROI.
Figure 5-9: The Select Statistics Subset dialog for “Image Subset” calculation
(left), or “ROI” calculation (right).
The report shows the covariance and correlation matrices along with the eigenvectors
for each band. If all three options are selected, all of the statistics are shown in one
“File Statistics Report.”
• To display the statistics report on-screen, click the “Screen” check box next to
the “Report” label in the Calculate Statistics Parameters dialog.
The output of all statistics selected appear in an all-text report displayed in a
separate window.
Tip
The report can be lengthy, so it may be better to de-select the “Text Report” check
box under the “Calculate Histogram Statistics” label to reduce the size of the report.
• To save the on-screen report, select File > Save Text to ASCII.
Selecting Text File Output
To output the statistics report to a text file:
1. In the Calculate Statistics Parameters dialog, select “File” output.
2. Enter or choose a filename for the report.
Producing Statistics Reports
After setting the report parameters in the Calculate Statistics Parameters dialog,
calculate the statistics report:
• In the dialog, click “OK” to start the statistics calculations.
A small window appears showing the percent of processing complete as a
slider from 0 to 100%.
Once the statistics have been calculated, the File Statistics Report window
appears.
Note
If the output data falls outside the data type range, the output data will be clipped to
the highest or lowest data type value (i.e., byte output will have values only
between 0-255 and all negative values will clip to 0).
N N
Sum = åx j Sum =
2
åx j
2
j=1 j=1
N N
1
Mean = x = ----
N å xj
1
Variance = -------------
N–1 å (x – x) j
2
j=1 j=1
N 3 N 4
å å
1 æ xj – x ö 1 æ xj – x ö
Skewness = ---- ç ----------------------------÷ Kurtosis = ---- ç ----------------------------÷ –3
N è Varianceø N è Varianceø
j=1 j=1
N
1
Mean Absolute Deviation = ----
N å x –x j Standard Deviation = Variance
j=1
• To draw a square or circle, click and drag while holding the middle mouse
button in Rectangle or Ellipse mode.
7. Close the polygon or complete the line by clicking the right mouse button.
• To erase the shape, click again with the right mouse button.
For Polygon mode, the distance between the vertices are listed and the
perimeter and total area are reported when the polygon is closed.
For Polylines, the distance between the vertices are listed and the total distance
is given when the polyline is completed.
In Rectangle mode, the lengths of the side segments, the perimeter, and the
total area are reported.
In Ellipse mode, the circumference and total area are reported.
If the pixel size of the image is not stored in the header, and you select any unit
except “pixel,” complete these steps when the Input Display Pixel Size dialog
box appears.
A. In the “X Pixel Size” and “Y Pixel Size” text boxes, type the size of the
pixels in your image.
B. From the “Units” button menu, select the unit type. Click “OK.”
Measuring Area
In the Display Measurement Tool dialog, use the Area menu to measure the area in
units 2 (e.g., meters2), acres, or hectares.
• Select Area > Acres or Hectares.
Measurement Options
In the Display Measurement Tool dialog, use the Options menu to select whether the
measurement information is reported as line segments (the default) or as point
coordinates.
• To get a listing of the vertices coordinates, select Options > Report as Points.
The coordinates are reported as a pixel location (“Pixel (x,y)”).
• To get a listing of the line segment distances, select Options > Report as
Segments.
• For images that are georeferenced, you may list the coordinates as map
coordinates or as latitude and longitude coordinates by selecting Options >
Georef Map (x,y) or Georef (Lat/Lon).
• To output the list of point coordinates to a file, select File > Save Points to
ASCII.
Band Math
Use Band MathTM to process complex expressions and produce single band output.
Use “File Math” to apply the math expressions to all of the bands in a multiband file.
See Band Math Basics in the ENVI Programmer’s Guide for more information about
using Band Math.
could be entered into the text box. Three variables are used in this
expression—“b1” is one variable, “b2” a second variable, and “b3” a third
variable. Note that, in this example, the IDL float function is used to prevent
byte overflow errors during calculation.
3. After a valid expression is entered, click “OK.”
The Variable/Band Name Pairings dialog appears.
Using Previous Expressions
To reuse any previously applied math expressions:
1. In the Band Math dialog, click on any expression shown in the “Previous
Expression:” list to load that expression into the “Enter an expression:” field.
2. Once loaded, click “OK” to apply the expression to a new set of bands.
The Variable/Band Name Pairings dialog appears. Please see below for
detailed instructions.
Saving Expressions
To save an expression to an output file:
1. In the Band Math dialog, click “Save.”
2. When the Enter Output Filename dialog appears, enter an output filename with
the file extension .exp for consistency.
Restoring Saved Expressions
To restore previously-saved expressions:
1. In the Band Math dialog, click “Restore.”
2. Select the appropriate filename.
The expressions are displayed in the “Previous Expression” list.
Clearing Expressions
• To clear all expressions from the “Previous Band Math Expressions” list, click
the “Clear” button.
Data sets appear an “unfolded” state by default. The names of unfolded data
sets appear in this format:
-<filename>
Band
Band
• To fold a data set, click on the name of the data set.
All of the bands of the data set are compressed and the data set appears in
the list in this format:
+<filename>[number of bands]
• To “unfold” a data set and make it available for processing, simply click
the folded filename.
Note
Once the first band is selected, only those bands with the same spatial dimensions
are shown in the band list.
A multiband output image is produced for file math modified by the math
expression.
Spatially Subsetting Input Images
• To spatially subset the input image, click the “Spatial Subset” button and refer
to “Selecting a Spatial Subset” on page 45 for detailed instructions.
• Compile this function by selecting File > Compile IDL Module and selecting
the filename.
• To call this function from the Band Math “Enter an expression” box, use the
syntax:
user_bm1(b1,b2)
Example:
FUNCTION user_bm2, b1
lut = 255 - BINDGEN(256)
b1 = BYTSCL(b1)
b1 = lut(b1)
RETURN, b1
END
• Compile this function by selecting File > Compile IDL Module and selecting
the filename.
• To call this function from the Band Math “Enter an expression” box, use the
syntax:
user_bm2(b1)
• Compile this function by selecting File > Compile IDL Module and selecting
the filename.
• To call this function from the Band Math “Enter an expression” box, use the
syntax:
user_bm3(b1,b2)
An infrared image band near 0.8 µm should be used for the b1 variable while a “red”
band near 0.6 µm should be used for the b2 variable. The following program text can
be entered into a text editor and saved with the filename user_bm4.pro
Example:
FUNCTION user_bm4, b1,b2
b1=bytscl ((float(b1) - b2) / (float(b1)+b2), min=-1.0,max=1.0)
RETURN, b1
END
• Compile this function by selecting File > Compile IDL Module and selecting
the filename.
• To call this function from the Band Math “Enter an expression” box, use the
syntax:
user_bm4(b1,b2)
Spectral Math
Use Spectral Math TM to apply mathematical expressions or IDL procedures to spectra
(and also to selected multiband images). The spectra can be either from a multiband
image (i.e., a Z profile), a spectral library, or an ASCII file. For more information and
detailed instructions, see “Spectral Math” on page 679.
Segmenting Images
Use Segmentation Image to segment an image into areas of connected pixels based
on the pixel DN value. You can enter a single DN or a range of DN values to use in
the segmentation. Either four or eight adjacent pixels are considered for the
connectivity and you can specify the minimum number of pixels that must be
contained in a region. Each connected region, or segment, is given a unique DN value
in the output image.
• To use a single DN value, enter that value in both the “Min Thresh Value”
and “Max Thresh Value” threshold text boxes.
Only pixels that fall within the entered DN range will be considered in making
the segmentation image. All other pixels will have an output value of 0.
4. In the “Population Minimum” text box, enter the minimum number of pixels in
a segment.
5. Use the arrow toggle button to select either 4 or 8 neighbors to be considered
for the connectivity.
6. Select “File” or “Memory” output.
7. Click “OK.”
The resulting segmentation image filename appears in the Available Bands List.
Regions of Interest
Use Region of Interest to access common ROI functions such as defining, saving,
restoring, deleting, exporting, and reconciling ROIs. Also use it to create
classification images from ROIs or to convert image values to ROIs.
Note
Each function described in this section can also be accessed from within the ROI
Tool dialog or from the Display Tools menu. For detailed instructions, see
“Defining Regions of Interest” on page 261.
Deleting ROIs
1. Select Basic Tools > Region of Interest > Delete ROIs.
2. When the Delete Regions dialog appears, click on the names of the regions to
be deleted.
3. Click “OK” to permanently delete those ROIs.
Reconciling ROIs
Use Reconcile ROIs to apply ROIs defined in one image size to images of different
sizes.
1. Select Basic Tools > Region of Interest > Reconcile ROIs.
2. When the Reconcile ROIs Parameters dialog appears, click on the ROIs to
select them.
For detailed instructions, see “Reconciling ROIs” on page 277.
Mosaicking Images
Use Mosaicking to mosaic both pixel-based and georeferenced images.
Note
You may also access this function from the Register menu. For details about using
this function, see “Image Mosaicking” on page 731.
Masking
Use masking to create image masks. A mask is a binary image that consists of values
of 0 and 1. When a mask is used in a processing function, the areas with values of 1
are processed and the masked 0 values are not included in the calculations.
Masking is available for selected ENVI functions including statistics, classification,
unmixing, matched filtering, continuum removal and spectral feature fitting.
Figure 5-16: An example mask image created using a data range and imported
ROI.
Building Masks
Use Build Mask to build image masks from specific data values, ranges of values,
finite or infinite values, Regions of Interests (ROIs), ENVI vector files (EVFs), and
annotation files. You can use any combination of input to define a mask and you can
permanently apply a mask to an image.
Note
Masks can be applied on-the-fly when using specific ENVI functions. These
functions include statistics, classification, unmixing, matched filtering, continuum
removal, and Spectral Feature Fitting.
Masking Options
Options in the Mask Definition dialog include importing data values, importing
annotations, masking finite values, masking non-numbers and infinite data values,
using ROIs and EVFs with the mask, and selecting areas for masking.
3. Click “OK” to enter the range into the mask definition list.
If you enter only a minimum or maximum value and click “OK,” the data’s
actual maximum or minimum, respectively, will be used as the other end
value.
Including Annotations
• To include an annotation file in the mask, select Options > Import Annotation
and select the desired input file.
• To include the currently displayed annotation shapes in the mask, select
Options > Import Displayed Annotation.
Note
Only rectangles, ellipses, and polygons are imported into the mask definition.
Note
All imported ROIs are treated as a single mask layer.
• To use all the defined areas to make the mask, select Options > Selected
Attributes [Logical OR].
Deleting Attributes
To delete an item from the “Select Attributes” list in the Mask Definition dialog,
highlight the item and click “Delete Item.”
Clearing the Attribute List
To remove all items from the “Select Attributes” list in the Mask Definition dialog,
click the “Clear All Items” button.
Saving Masks
1. In the Mask Definition dialog, select output to “File” or “Memory.”
2. Click “Apply.”
Closing the Masking Dialog
To close the Mask Definition dialog, click “Cancel.”
Applying Masks
Use Apply Mask to permanently apply a mask to an image, giving the pixels that are
“masked out” a value of zero.
1. Select Basic Tools > Masking > Apply Mask.
2. When the Apply Mask Input File dialog appears, select the desired input file
and any spatial or spectral subsets.
3. Click the “Select Mask Band” button.
4. Select the desired mask from the list of available bands.
Only mask images that are the same size as the input band are available.
To clear the selected mask band, select Options > Clear Mask Band.
5. When the desired input is selected, click “OK.”
6. When the “Apply Mask Parameters” dialog appears, enter the desired value in
the “Mask Value” text box.
All areas in the input image(s) where the mask equals zero are set to this
mask value.
7. Enter an output filename or select output to memory.
1. Select Basic Tools > General Purpose Utilities > Replace Bad Lines.
The Bad Lines Input File dialog appears.
2. Select an input file and perform any subsetting.
3. Click “OK.”
The Bad Lines Parameters dialog appears.
4. In the “Enter Bad Line” text box, specify which bad lines to replace and press
the <Return> or <Enter> key.
5. The line appears in the “Selected Lines” list.
• To remove that line from the list, click on the line.
• To save the line coordinates to a file, click “Save.”
• To restore the coordinates from a previously saved file, click “Restore.”
• To clear the list of lines to be replaced, click “Clear.”
6. In the “Half Width to Average” text box, enter the number of adjacent lines to
be used as an average for calculation of the replacement line.
The value is symmetrical around the line to be replaced. For example, the
value “2” means that two lines on either side of the selected line will be
averaged to calculate the replacement.
7. Click “OK.”
8. When the Bad Lines Output dialog appears, select output to “File” or
“Memory.”
9. Click “OK.”
6. In the “Edit Selected Item” text box, edit the offset value of the item.
7. Repeat this selection and assignment of values for each band to be processed.
• To reset all of the bands to their original values, click “Reset.”
• To return to the main menu, click “Cancel.”
8. Select output to “File” or “Memory.”
9. Click “OK.”
A status window displays the status of the operation. The resulting bands are listed in
the Available Bands List.
Destriping Data
Use Destripe Data to remove periodic scan line striping in image data. This type of
striping is often seen in Landsat MSS data (every 6th line) and less commonly, in
Landsat TM data (every 16th line). When destriping the data, ENVI calculates the
mean of every nth line and normalizes each line to its respective mean. In order for
destriping to function properly, the data must be in the acquired format (horizontal
strips) and cannot be rotated or georeferenced.
1. Select Basic Tools > General Purpose Utilities > Destripe.
2. When the Destriping Data Input File appears, select the input file and perform
any subsetting.
3. Click “OK.”
4. When the Destriping Parameters dialog appears, enter the number of detectors
in the box labeled “Number of Detectors.”
The number of detectors is the periodicity of the striping (e.g., for Landsat
MSS, the value would be “6”).
If the file type has been set in the header, the default is set automatically.
5. Select either “File” or “Memory” output.
• To return to the main menu at any time, click “Cancel.”
6. Click “OK” to start the operation.
Along-track mean values are calculated and you can plot them to show the mean
variation in the cross-track direction. A polynomial function, with the order defined
by you, is fit to the means and used to remove the variation.
1. Select Basic Tools > General Purpose Utilities > Cross-Track Illumination
Correction.
2. When the Cross Track Illumination Input File dialog appears, select the input
file and perform any spatial or spectral subsetting or masking.
The Cross Track Illumination Correction Parameters dialog appears.
3. Select the cross track direction by clicking in the check box next to either
“Samples” or “Lines.”
4. Select either an “Additive” or “Multiplicative” correction method.
The Additive method will subtract the fitted polynomial from the data and the
Multiplicative method will divide the data by the fitted polynomial.
5. Enter the desired polynomial order and click “Plot Polynomial.”
A plot of the mean data values are displayed in red with the selected
polynomial fit overlaid in white. It is best to use a low order polynomial so as
not to remove the local variation in the data.
Tip
You can change the polynomial order and plot it again.
Data-Specific Utilities
Use Data-Specific Utilities to apply data-specific functions that work specifically on
your data type.
AVHRR Utilities
Use AVHRR Utilities to read and display information from the AVHRR header,
calibrate AVHRR data to percent reflectance and brightness temperature, compute
sea surface temperatures, and to use information in the data for georeferencing. For
details, see the following references:
Di, L. and D. C. Rundquist, 1994. A one-step algorithm for correction and calibration
of AVHRR Level 1b data, Photogrammetric Engineering & Remote Sensing, Vol.
60, No. 2, pp. 165-171.
The NOAA Satellite Information System web page at:
http://psbsgi1.nesdis.noaa.gov:8080/EBB/ml/nic00.html
Note
The calibration and sea surface temperatures should be calculated before
georeferencing.
3. When the AVHRR Calibrate Parameters dialog appears, select the satellite
number from the “Satellite” button menu.
4. Select either “File” or “Memory” output.
5. Click “OK” to start the calibration.
Bands 1 and 2 are output in % reflectance, and bands 3, 4, and 5 are output in
brightness temperature, in degrees Kelvin.
4. When the Aspect Correction Parameters dialog appears, select output to “File”
or “Memory.”
5. Click “OK” to start the function.
No other interaction is required. The status window appears with the output filename
listed and the percent completed displayed.
Landsat MSS Data Calibration
Use Landsat MSS Calibration to convert Landsat MSS digital numbers to radiance or
exoatmospheric reflectance (reflectance above the atmosphere) using published post-
launch gains and offsets. For detailed instructions, see “Calibrating Landsat MSS
Data” on page 480.
Landsat TM Utilities
Use Landsat TM Calibration to convert Landsat TM digital numbers to radiance or
exoatmospheric reflectance (reflectance above the atmosphere) using published post-
launch gains and offsets. For detailed instructions, see “Calibrating Landsat TM
Data” on page 481.
SeaWiFS Utilities
Use SeaWiFS Utilities to calculate geometry information for and to georeference
HDF and CEOS format SeaWiFS data. Geometry information includes latitude,
longitude, sensor azimuth, sensor zenith, solar azimuth, solar zenith, and UTC time.
The georeferencing function produces a full precision geocoding based on a complete
geometry model of the earth and satellite orbits.
Thermal IR Utilities
Use Thermal IR utilities to convert data sets from radiance to emissivity and
temperature. There are three Thermal IR utilities: Reference Channel, Emissivity
Normalization, and Alpha Residuals.
The radiation emitted from a surface in the thermal infrared wavelengths is a function
of both the surface temperature and emissivity. The emissivity relates to the
composition of the surface and is often used for surface constituent mapping.
ENVI has three techniques that are used to separate the emissivity and temperature
information in radiance data measured with thermal infrared sensors. Both the
Reference Channel and Emissivity Normalization techniques assume a fixed
emissivity value and produce emissivity and temperature outputs. The Alpha
Residuals technique does not provide temperature information.
Planck function is used so the equation can be linearized with logarithms. The
temperature and emissivity terms are separated and means are used to subtract the
temperature term out.
The alpha residual spectra are a function of emissivity only and have a similar shape
as emissivity spectra but have a zero mean. Therefore emissivity spectra must be
scaled for direct comparison to alpha residual spectra. Emissivity spectra can be
calculated from alpha residual spectra using empirical data as described in the Kealy,
1993 reference mentioned in the introduction to Thermal IR Utilities on page 477.
1. Select Basic Tools > Data-Specific Utilities > Thermal IR > Alpha Residuals
or Basic Tools > Calibration Utilities > Calculate Emissivity > Alpha
Residuals.
2. Select the input radiance data file and perform any subsetting.
The Calculate Emissivity parameters dialog appears.
3. Enter a data scale factor, if needed, to scale the radiance values into the units of
W/m2/µm/sr (for example, if your data is in microflicks (µW/cm2/µm/sr) enter
a scale factor of .01).
4. Enter a wavelength scale factor, if needed, to scale the wavelengths (read from
the header) into units of µm.
5. Enter an output filename and click “OK.”
The alpha residual data cube (same number of bands as input radiance data) filename
is listed in the Available Bands List.
Calibration Utilities
Use Calibration Utilities to apply calibration factors to AVHRR, MSS and TM data,
and to use Flat Field, Internal Average Relative Reflectance, and Empirical Line
calibration techniques.
Calibrating AVHRR
Use AVHRR calibration to calibrate AVHRR data from the NOAA 12, 14, and 15
satellites. Bands 1 and 2 are calibrated to percent reflectance and bands 3, 4, and 5
are calibrated to brightness temperature, in degrees Kelvin. For detailed
instructions, see “Calibrating AVHRR Data” on page 472.
TM band 6, if present, is converted to temperature. If 7 bands are input, the 6th band
is assumed to be the thermal infrared band. If only 6 bands are input, then it is
assumed that there is no thermal infrared band.
1. Select Basic Tools > Calibration Utilities > Landsat TM.
2. When the TM Calibration Input File dialog appears, select the input file and
perform any subsetting using the standard ENVI file selection procedures.
3. Click “OK.”
The TM Calibration Parameters dialog appears.
To change any of the information, use the corresponding buttons and text
boxes.
Note
For Landsat 7 files, the data acquisition date, gains and bias factors, and sun
elevation and azimuth are automatically read from the header. If the data
acquisition date is not found in the file header, you will be prompted to enter it.
The Earth-Sun distance used in the calibration is based on the data acquisition date
and calculated from a table in the Landsat 7 User’s Guide dated 5/1/2001.
4. Select the desired output type using the “Radiance” and “Reflectance” toggle
buttons.
5. Choose either “File” or “Memory” output.
6. Click “OK” to start the function.
The TM Calibration Status window appears with the output filename listed and the
percent completed displayed.
from ATREM is automatically opened in ENVI and it appears in the Available Bands
list upon completion.
Supplying Wavelengths
Wavelengths are required to run ATREM. If your input data does not include
wavelengths in the ENVI header, a prompt appears asking you to supply the
wavelengths from an ASCII file:
• Select the column that contains the wavelengths and the column that contains
full width half maximum (FWHM) values, if included.
The wavelengths and FWHM values must be in units of micrometers.
• For the iron-rich example, enter the same wavelengths that are in the 1.14
text boxes into the 0.94 text boxes.
• To use default channel ratio parameters, select from the “Apply Defaults”
button menu. For more information, see the ATREM User’s Guide.
8. Select which of the seven atmospheric gases should be modeled and removed
during the reflectance calculation by clicking in the check box next to the gas
name.
By default, all the gases are selected.
9. Select an aerosol model using the pulldown selections.
10. Enter a visibility for the conditions during the overflight or click the arrow
toggle button to enter an aerosol optical depth measured at the time of the
overflight.
11. Select a standard atmospheric model from the pulldown selections and enter a
vertical column ozone amount in atm-cm units. Enter the average surface
elevation of the data scene in kilometers.
12. Set the output parameters as described in the next section.
Setting ATREM Output Parameters
Use the ATREM Output Parameters dialog to change the output filenames, scale
factor, output spectral resolution, and execution path string. The output ATREM
parameters file contains the defined parameters in the necessary ATREM input
format. ENVI automatically executes ATREM using this file as input. The output
image file contains the output apparent reflectance data scaled by the output data
scale factor into two-byte integers.
1. In the ATREM Input Parameters dialog, click the “Edit Output Parameters”
button.
The ATREM Output Parameters dialog appears.
2. Select from the following options:
• To change any of the default output filenames, enter the new filenames.
The output ATREM parameters file contains the defined parameters in the
necessary ATREM input format. ENVI automatically executes ATREM
using this file as input. The output image file contains the output apparent
reflectance data scaled by the output data scale factor into two-byte
integers. The output water vapor image contains the total column water
vapor amount for every pixel in cm * 1000 so it is two-byte integer data.
5. When the Flat Field Calibration Parameters dialog appears, select the average
spectrum to use for the flat field calibration by clicking on the desired ROI
name in the column labeled “Select Calibration from Regions.”
The selected ROI name appears at the bottom of the window in the text box
labeled “Selected Item.”
6. Choose “File” or “Memory” output.
7. Click “OK” to start the calibration.
1. Select Basic Tools > Calibration Utilities > Empirical Line > Compute
Factors and Calibrate.
2. When the Empirical Line Input File dialog appears, select the input file and
perform any subsetting.
3. Click “OK.”
The Empirical Line Spectra dialog appears.
4. Collect image spectra and reference spectra, and pair spectra using the
procedures described in the following sections.
Calculating Emissivity
ENVI has three techniques that are used to separate the emissivity and temperature
information in radiance data measured with thermal infrared sensors. Both the
Reference Channel and Emissivity Normalization techniques assume a fixed
emissivity value and produce emissivity and temperature outputs. The Alpha
Residuals technique does not provide temperature information.
Emissivity Normalization
Use Emissivity Normalization to calculate emissivity and temperature values from
thermal infrared radiance data. For detailed instructions, see “Using Emissivity
Normalization” on page 478.
Alpha Residuals
Use Alpha Residuals to produce alpha residual spectra that approximate the shape of
emissivity spectra from thermal infrared radiance data. For detailed instructions, see
“Using Alpha Residuals” on page 478.
Drag-and-Drop
Window
Figure 6-2: The Endmember Collection Dialog. The area below the menu bar is
the drag-and-drop window, which is used to collect endmember spectra.
3. Enter the column number that contains the X axis data in the “X Axis Column”
text box.
4. Select endmember spectra by clicking on the desired column name(s).
• If desired, enter multiplicative scaling factors in the “X Data Multiplier”
and “Y Data Multiplier” text boxes to be applied to both the X and Y
values to match the image data.
5. Click “OK” to enter the selected endmember spectra into the list on the
Endmember Collection dialog.
Importing Additional ASCII Files
To select another ASCII file and read the data using the parameters defined in the
previous Input ASCII File dialog:
1. Select Import > from ASCII file (previous template).
2. Select the filename of an ASCII file.
This option reads the data directly into the Endmember Collection dialog
without the intermediate parameter dialog.
Importing Spectra from Spectral Libraries
1. Select Import > from Spectral Library.
2. When the Spectral Library Input File dialog appears, choose the spectral
library name and click “OK” to open the library.
• If the desired spectral library has not been previously opened, select File>
Open Spectral Library in the Library Input File dialog.
3. When the Input Spectral Library dialog appears, select endmember spectra by
clicking on the desired spectrum name(s).
4. Enter an X and/or Y data multiplication factor to change the scale of the data.
5. Click “OK” to enter the selected spectra into the Endmember Spectra list.
Figure 6-3: The Input ASCII File and Input Spectral Library Dialogs. Both of
these dialogs are accessed from the “Import Spectra” menu on the Endmember
Collection dialog.
Endmember Options
Use the Options menu in the Endmember Collection dialog to edit the endmember
names, plot the endmembers, and clear the endmembers.
2. When the Endmember Name Editing dialog appears, select the endmember to
edit by clicking on the name in the “Current Endmember Names” list.
3. Select from the following options:
• To manually change the name, click on it, make the desired changes in the
“Edit Selected Item” text box, and press the return key.
• To import endmember names from an ASCII file, click “Import ASCII”
and select the input ASCII file.
The ASCII file must contain the same number of names as there are
endmember spectra in the dialog—with each name on a single line in the
ASCII file.
• To reset the endmember names to their original names, click “Reset.”
4. Click “OK.”
2. Click “Apply.”
3. When the Algorithm Parameters dialog appears, enter the selected algorithm’s
needed parameters.
The parameters displayed are specific to the selected classification algorithm. For
details about the different classification techniques, see the following topics:
“Applying Parallelepiped Classification” on page 505
“Applying Minimum Distance Classification” on page 507
“Applying Mahalanobis Distance Classification” on page 509
“Applying Maximum Likelihood Classification” on page 510
“Applying Spectral Angle Mapper Classification” on page 511
“Applying Binary Encoding Classification” on page 513
For details about the advanced processing techniques, see the following topics:
“Using Linear Spectral Unmixing” on page 651
“Using Matched Filtering” on page 655
“Using Mixture Tuned Matched Filtering” on page 657
“Using Spectral Feature Fitting” on page 661
Supervised Classification
Use Supervised classification to cluster pixels in a data set into classes corresponding
to user-defined training classes.
Training classes are groups of pixels (ROIs) or individual spectra. Select them as
representative areas or materials that you want mapped in the output. You should try
to select ROIs that are homogenous. You can examine the separability of your ROIs
by exporting them to a n-D Visualizer and looking at the distribution of the points
within each ROI (they should cluster tightly together) and looking for overlap
between the classes (they should not overlap). For detailed instructions, see
“Exporting ROIs to the n-D Visualizer” on page 284. You can also get a report of the
separability values between ROI pairs. For detailed instructions, see “Computing
ROI Separability” on page 281.
Supervised classification techniques include Parallelepiped, Minimum Distance,
Mahalanobis Distance, Maximum Likelihood, Spectral Angle Mapper (SAM), and
Binary Encoding.
Note
You must define training classes prior to performing supervised classification. You
can define training classes in two ways: using the Endmember Collection dialog to
select spectra (see “Collecting Endmember Spectra” on page 495) or by defining
regions of interest (ROIs) (see “Defining Regions of Interest” on page 261). The
training sites can be defined as multiple irregular polygons, vectors, and/or
individual pixels.
Using the Endmember Collection option allows you to use the same training classes
or endmembers for several classifications without reloading, thus simplifying
comparison of classification results.
For all supervised classification methods, you have an option to output “rule” images.
This is highly recommended. Rule images show the classification results before final
assignment of classes. For example, the pixel values in the rule images (one per class)
for a minimum distance classification are the distance between the class and each
unknown pixel. These rule images can be used in the rule classifier to adjust
thresholds and generate new classification images (see “Classifying from Rule
Images” on page 525).
Selecting ROIs
• To select regions of interest as training classes, click on the desired ROI names
in the “Select Classes from Regions:” list of available ROIs.
Note
Maximum Likelihood and Minimum Distance both require at least two regions.
Note
The rule images will not be saved if the Output Rule Images toggle button is set to
“No.”
The images will appear in the Available Bands List at the end of the classification,
and can be displayed and/or linked/overlaid in any display window and queried using
ENVI’s Pixel Location/Value function.
Rule images can also be used later in the Rule Classifier to create a new
classification image without actually having to recalculate the entire classification
(see “Classifying from Rule Images” on page 525).
A. In the list of classes, click on the class or classes to which you want to
assign different threshold values.
B. Click the “Multiple Values” button to select it.
C. Click the “Assign Multiple Values” button.
D. In the dialog that appears, click on a class to select it, then enter a threshold
value in the text box at the bottom of the dialog. Repeat for each class.
Note
Undefined thresholds are not allowed.
A status window displays the progress of the operation. The pixel values of the
resulting rule images range from 0 to n (where n is the number of bands) and
represent the number of bands that satisfied the parallelepiped criteria. There is one
rule image for each selected class. Areas that match all bands for a particular class are
carried over as classified areas into the classified image. If more than one match
occurs, the first class to be evaluated (the first ROI from the selected list) carries over
into the classified image.
Note
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 will
be classified. If you select “None” for both parameters, then all pixels will be
classified.
distance from the class mean. Areas that satisfied the minimum distance criteria are
carried over as classified areas into the classified image.
1. Select Classification > Supervised > Spectral Angle Mapper; or, in the
Endmember Collection dialog, select Algorithm > Spectral Angle Mapper
(see “Collecting Endmember Spectra” on page 495).
2. When the Classification Input File dialog appears, perform standard file
selection and any subsetting and masking of the input file.
The Endmember Collection: SAM dialog appears.
Spectra can be imported from ASCII files, spectral libraries, ROI means, or statistics
files.
3. From the Import_Spectra menu, select endmember spectra from the variety of
sources (see “Collecting Endmember Spectra” on page 495).
• If desired, change the names of the spectra and plot the spectra.
4. After all endmember spectra are selected, click “Apply.”
The Spectral Angle Mapper Parameters dialog appears.
5. Enter the general classification parameters as described in “Entering
Classification Parameters” on page 504.
6. Set a threshold based on the spectral angle by selecting one of the following
options:
• To use no threshold, click the “None” button.
• To use a single threshold for all classes, click the “Single Value” button
and enter a value, in radians, in the “Maximum Angle” text box.
This is the maximum acceptable “angle” between the endmember
spectrum vector and the pixel vector (in “# of bands” dimensional space).
The default is 0.1 radians. Pixels with an angle larger than this value will
not be classified.
• To enter a different threshold for each class:
A. In the list of classes, click on the class or classes to which you want to
assign different threshold values.
B. Click the “Multiple Values” button to select it.
C. Click the “Assign Multiple Values” button.
D. In the dialog that appears, click on a class to select it, then enter a threshold
value in the text box at the bottom of the dialog. Repeat for each class.
Undefined thresholds are not allowed.
7. Click “OK” to begin the SAM classification.
A status window displays the progress of the operation. The pixel values of the rule
images represent the spectral angle in radians from the reference spectrum for each
class. Lower spectral angles represent better match to the endmember spectra. Areas
that satisfied the selected radian threshold criteria are carried over as classified areas
into the classified image.
4. Set a threshold based on the percentage of bands that match by selecting one of
the following options:
• To use no threshold, click the “None” button.
• To use a single threshold for all classes, click the “Single Value” button
and enter decimal percentage value, between 0 and 1, in the “Minimum
Encoding Threshold” text box.
The percentage value represents the number of bands that must match.
• To enter a different threshold for each class:
A. In the list of classes, click on the class or classes to which you want to
assign different threshold values.
B. Click the “Multiple Values” button to select it.
C. Click the “Assign Multiple Values” button.
D. In the dialog that appears, click on a class to select it, then enter a threshold
value, between 0 and, in the text box at the bottom of the dialog. Repeat
for each class.
Undefined thresholds are not allowed.
If a minimum value is not entered, all pixels will be classified.
5. Click “OK” to begin the classification.
A status window displays the progress of the operation. If a rule image was selected,
one is created for each class with the pixel values equal to the percentage (0-100%) of
bands that matched that class. Areas that satisfied the minimum threshold are carried
over as classified areas into the classified image.
Note
For a linear classification, enter a value of 0. You can perform non-linear
classification using 1 or 2 hidden layers.
10. In the “Number of Training Iterations” text box, enter the number of iterations
for training.
• To enter a minimum output activation threshold, enter a value in the “Min
Output Activation Threshold” text box.
If the activation value of the pixel being classified is less than this
threshold value, then that pixel will be labeled unclassified in the output.
11. Select output to “File” or “Memory.”
12. Select whether or not to output rule images by clicking the “Output Rule
Images” toggle button to select “Yes” or “No.”
If you output rule images, there is a rule image for every class. The rule image
is the output activation value for every pixel in that class.
• If you select “Yes,” select output to “File” or “Memory” for the rule
images.
A status window displays the progress of the operation. During the training, a plot
window appears showing the RMS error at each iteration. The error should decrease
and approach a steady low value if proper training occurs. If the errors are oscillating
and not converging, try using a lower training rate value or different ROIs. The
resulting neural net classification image, and rule images if output, appear in the
Available Bands List when processing is complete.
Unsupervised Classification
Use Unsupervised classification to cluster pixels in a data set based on statistics only,
without any user-defined training classes. The unsupervised classification techniques
available are Isodata and K-Means.
If the distance between class means is less than the minimum value entered,
then the classes will be merged. The maximum number of class pairs to be
merged is set by the maximum number of merge pairs parameter.
• To set the optional standard deviation to use around the class mean and/or
the maximum allowable distance error (in DN), enter the values in the
“Maximum Stdev From Mean:” or “Maximum Distance Error:” text
boxes, respectively.
If both of these optional parameters are entered, the classification uses the
smaller of the two to determine which pixels will be classified. If neither
parameter is entered, then all pixels will be classified.
8. Select output to “File” or “Memory.”
9. Click “OK” to start the Isodata classification.
Statistics are calculated for each band of the image, and a status window displays the
progress of the operation. The status bar cycles from 0 to 100% for each iteration of
the classifier.
Note
The statistics for the initial class seeds are computed with a skip factor of 2.5 for
both the sample and line directions.
5. To select either disk file or memory output, select the “File” or “Memory”
toggle button.
• If output to “File” is selected, enter an output filename.
6. Click “OK” to start the K-Means classification.
Statistics are calculated for each band of the image, and a status displays the progress
of the operation. The status bar cycles from 0 to 100% for each iteration of the
classifier.
Note
The statistics for the initial class seeds are computed with a skip factor of 2.5 for
both the sample and line directions.
Post Classification
Use Post Classification to classify rule images, to calculate class statistics and
confusion matrices, to apply majority or minority analysis to a classification images,
to clump, sieve, and combine classes, to overlay classes on an image, to calculate
buffer zone images, to calculate segmentation images, and to output classes to vector
layers.
Figure 6-10: Selecting Class Color Mapping from the Display menu.
1. Select Tools > Color Mapping > Class Color Mapping from the Display menu
in the Main Image window.
2. When the Classification Mapping dialog appears, select from the following
options to change the class colors and/or names.
• To change the color system, select “RGB,” “HLS,” or “HSV” from the
“System” button menu.
• To modify the class color, click on a class name in the “Selected Classes”
list and either type new values into the text boxes and press “Enter,” or
move the color adjustment slider bars, or click the arrow increment buttons
to set the color values.
• To change the name of the selected class, edit it in the “Class Name:” text
box.
• To reset the colors and names to their original values, select Options >
Reset Color Mapping.
3. When you are finished with your color modifications, select File > Save
Changes to retain the new colors.
4. Select File > Cancel to close the dialog.
For more information, see “Mapping Class Colors” on page 364 and “Editing
Classification Info” on page 108.
Tip
You can plot a histogram of a rule band to help you determine threshold values. For
details, see “Plotting Histograms” on page 526.
6. Click the “Quick Apply” button to see how any of your changes affect the
classification image.
Plotting Histograms
You can plot a histogram of a rule band to help you determine threshold values:
• Click the “Hist” button for that class.
A plot window is displayed with the histogram of the selected band.
For details about working with ENVI plots, see “Using Interactive Plot Functions” on
page 343.
7. Next to the “Report Accuracy Assessment” label, select the “Yes” or “No”
toggle button.
8. Next to “Output Error Images” label, click the arrow toggle button to select
“Yes” or “No.”
The output error images are mask images, one for each class, where all
correctly classified pixels have a value of 0 and incorrectly classified pixels
have a value of 1. The last error image band shows all the incorrectly classified
pixels for all the classes combined.
9. Choose output to “File” or “Memory.”
10. Click “OK.”
The report shows the overall accuracy, kappa coefficient, confusion matrix, errors of
commission (percentage of extra pixels in class), errors of omission (percentage of
pixels left out of class), producer accuracy, and user accuracy for each class.
Producer accuracy is the probability that a pixel in the classification image is put into
class X given the ground truth class is X. User Accuracy is the probability that the
ground truth class is X given a pixel is put into class X in the classification image.
The confusion matrix output shows how each of these accuracy assessments is
calculated. For details, see Figure 6-13 and “Confusion Matrix Example” on
page 533.
3. When the Match Classes Parameters dialog appears, match the ground truth
ROIs with the classification result classes by clicking on the matching names
in the two lists and clicking “Add Combination.”
The class combinations are shown in a list at the bottom of the dialog. If the
ground truth and classification classes have the same names, they are
automatically matched.
• To remove a class match from the list, click on the combination name. The
two class names reappear in the lists at the top of the dialog.
4. After all of your class combinations are made, click “OK.”
The Confusion Matrix Parameters dialog appears.
5. Next to the “Output Confusion Matrix in” label, select the “Pixels” and/or the
“Percent” check boxes.
6. Next to the “Report Accuracy Assessment” label, click the “Yes” or “No”
toggle button.
7. Click “OK.”
The report shows the overall accuracy, kappa coefficient, confusion matrix, errors of
commission (percentage of extra pixels in class), errors of omission (percentage of
pixels left out of class), producer accuracy, and user accuracy for each class.
Producer accuracy is the probability that a pixel in the classification image is put into
class X given the ground truth class is X. User Accuracy is the probability that the
ground truth class is X given a pixel is put into class X in the classification image.
The confusion matrix output shows how each of these accuracy assessments is
calculated. See the following example for details.
Ground Truth
(Pixels)
Class Unclassified Grass Forest Swamp Total
Unclassified 43689 26949 40 18001 88679
Grass 32835 64516 1741 3329 102421
Forest 8202 7277 4096 654 20229
Swamp 15227 10742 0 18702 44671
Total 99953 109484 5877 40686 256000
Ground Truth
(Percent)
Class Unclassified Grass Forest Swamp Total
Unclassified 43.71 24.61 0.68 44.24 34.64
Grass 32.85 58.93 29.62 8.18 40.01
Forest 8.21 6.65 69.70 1.61 7.90
Swamp 15.23 9.81 0.00 45.97 17.45
Total 100.00 100.00 100.00 100.00 100.00
Prod.
Class User Acc. Prod. Acc. User Acc.
Acc.
Overall Accuracy
The overall accuracy is calculated by summing the number of pixels classified
correctly and dividing by the total number of pixels. The ground truth image or
ground truth ROIs define the true class of the pixels. The pixels classified correctly
are found along the diagonal of the confusion matrix table which lists the number of
pixels that were classified into the correct ground truth class. The total number of
pixels is the sum of all the pixels in all the ground truth classes.
Kappa Coefficient
The kappa coefficient (κ) is another measure of the accuracy of the classification. It is
calculated by multiplying the total number of pixels in all the ground truth classes (N)
by the sum of the confusion matrix diagonals (xkk), subtracting the sum of the ground
truth pixels in a class times the sum of the classified pixels in that class summed over
all classes (xkΣxΣk), and dividing by the total number of pixels squared minus the sum
of the ground truth pixels in that class times the sum of the classified pixels in that
class summed over all classes.
å x – åx x
N kk kΣ Σk
κ = ---------------------------------------------------
k k
N – åx x
2
kΣ Σk
k
Commission
Errors of commission represent pixels that belong to another class that are labelled
as belonging to the class of interest. The errors of commission are shown in the rows
of the confusion matrix. In the confusion matrix example, the Grass class has a total
of 102,421 pixels where 64,516 pixels are classified correctly and 37,905 other
pixels are classified incorrectly as Grass (37,905 is the sum of all the other classes in
the Grass row of the confusion matrix). The ratio of the number of pixels classified
incorrectly by the total number of pixels in the ground truth class forms an error of
commission. For the Grass class the error of commission is 37,905/102,421 which
equals 37%.
Omission
Errors of omission represent pixels that belong to the ground truth class but the
classification technique has failed to classify them into the proper class. The errors of
omission are shown in the columns of the confusion matrix. In the confusion matrix
example, the Grass class has a total of 109,484 ground truth pixels where 64,516
pixels are classified correctly and 44,968 Grass ground truth pixels are classified
incorrectly (44,968 is the sum of all the other classes in the Grass column of the confusion
matrix). The ratio of the number of pixels classified incorrectly by the total number of
pixels in the ground truth class forms an error of omission. For the Grass class the
error of omission is 44,968/109,484 which equals 41.1%.
Producer Accuracy
The producer accuracy is a measure indicating the probability that the classifier has
labelled an image pixel into Class A given that the ground truth is Class A. In the
confusion matrix example, the Grass class has a total of 109,484 ground truth pixels
where 64,516 pixels are classified correctly. The producer accuracy is the ratio
64,516/109,484 or 58.9%.
User Accuracy
The user accuracy is a measure indicating the probability that a pixel is Class A given
that the classifier has labelled the pixel into Class A. In the confusion matrix
example, the classifier has labelled 102,421 pixels as the Grass class and a total of
64,516 pixels are classified correctly. The user accuracy is the ratio 64,516/102,421 or
63.0%.
6. Click the “Classify by” toggle button to select whether to classify the rule
image by minimum value or maximum value.
For example, if your rule images are from the Minimum distance or SAM
classifier, classify by minimum value. If your rule images are from the
Maximum Likelihood classifier, classify by maximum value.
7. In the “Min” and “Max” parameters text boxes, type minimum and maximum
values for the ROC curve threshold range.
Rule images are classified at N (specified by “Points per ROC curve”) evenly
spaced thresholds between (and including) the Min and Max values. Each of
these classifications is compared to the ground truth and becomes a single
point on a ROC curve. For example, if your rule images are from the
maximum likelihood classifier, the best choice is to enter a min value of 0 and
max value of 1.
8. In the “Points per ROC Curve” text box, enter the number of points in the ROC
curves.
9. In the “ROC curve plots per window” text box, enter the number of plots per
window.
10. Select whether to output probability of detection verses threshold plot by
selecting the “Yes” or “No” check box.
11. Click “OK.”
The ROC curves and probability of detection curves appear in plot windows
(see Figure 6-15).
3. When the Match Classes Parameters dialog appears, match the ground truth
classes with the rule image classes by clicking on the matching names in the
two lists and clicking “Add Combination”.
The class combinations are displayed in a list at the bottom of the dialog. If the
ground truth and classification classes have the same names, they are matched
automatically.
• To remove a class match from the list, click on the combination name. The
two class names reappear in the lists at the top of the dialog.
4. After all of your class combinations are made, click “OK.”
The ROC Curve Parameters dialog appears.
5. Click the “Classify by” toggle button to select whether to classify the rule
image by minimum value or maximum value.
For example, if your rule images are from the Minimum distance or SAM
classifier, classify by minimum value. If your rule images are from the
Maximum Likelihood classifier, classify by maximum value.
6. In the “Min” and “Max” parameters text boxes, type minimum and maximum
values for the ROC curve threshold range.
Rule images are classified at N (specified by “Points per ROC curve”) evenly
spaced thresholds between (and including) the Min and Max values. Each of
Majority/Minority Analysis
Use Majority/Minority Analysis to apply majority or minority analysis to a
classification image. Use majority analysis to change spurious pixels within a large
single class to that class. You enter a kernel size and the center pixel in the kernel will
be replaced with the class value that the majority of the pixels in the kernel has. If you
select Minority analysis, then the center pixel in the kernel will be replaced with the
class value that the minority of the pixels in the kernel has.
1. Select Classification > Post Classification > Majority/Minority Analysis.
2. When the file selection dialog appears, select the classification input file and
any subsetting.
The Majority/Minority Parameters dialog appears.
3. In the list of classes, click on the classes that you want to apply the analysis to.
Note
If the center pixel is from a class that was not selected in the “Select Classes” list,
that pixel will not be changed. However, center pixels of selected classes can be
changed into a class that is not selected if the unselected class is the majority class
in the kernel.
Clumping Classes
Use Clump Classes to clump adjacent similar classified areas together using
morphological operators. Classified images often suffer from a lack of spatial
coherency (speckle or holes in classified areas). Low pass filtering could be used to
smooth these images, but the class information would be contaminated by adjacent
class codes. Clumping classes solves this problem. The selected classes are clumped
together by first performing a dilate operation and then an erode operation on the
classified image using a kernel of the size specified in the parameters dialog.
1. Select Classification > Post Classification > Clump Classes.
2. When the Classification Input File dialog appears, select a classified image and
perform any spatial subsetting.
Note
Only classified images can be selected (based upon the file type described in the
image’s header).
3. Click “OK.”
The Clump Parameters dialog appears with all of the available classes in the
image in the “Select Classes” list.
4. Select the classes on which to perform clumping by clicking on the class
names in the list.
Note
Any classes not selected for clumping will be passed to the output image
unchanged.
5. Enter the desired morphological operator size in the “Rows” and “Cols” text
boxes.
6. Select output to “File” or “Memory.”
7. Click “OK” to start the processing.
Sieving Classes
Use Sieve Classes to solve the problem of isolated pixels occurring in classification
images. Sieving classes removes isolated classified pixels using blob grouping.
Again, low pass or other types of filtering could be used to remove these areas, but
the class information would be contaminated by adjacent class codes. The sieve
classes method looks at the neighboring 4 or 8 pixels to determine if a pixel is
grouped with pixels of the same class. If the number of pixels in a class that are
grouped is less than the value that you enter, those pixels will be removed from the
class. When pixels are removed from a class using sieving, black pixels (unclassified)
will be left.
Tip
Use the Clump Classes function (see “Clumping Classes” on page 541) after
sieving to replace the black pixels.
Note
Only classified images can be selected (based upon the file type described in the
image’s header).
3. Click “OK.”
The Sieve Parameters dialog appears with all of the available classes in the
image listed in the “Select Classes” list.
4. Select the classes on which to perform sieving by clicking on the class names
in the list.
Note
Any classes not selected for sieving will be passed to the output image unchanged.
5. Enter the minimum number of pixels contained in a class group in the “Group
Min Threshold” text box.
Any groups of pixels smaller than this value will be removed from the class.
6. Use the arrow toggle button to select the number of neighboring pixels (4 or 8)
to look at when determining the number of pixels in a class group.
The four-neighbor region around a pixel consists of the two adjacent
horizontal and two adjacent vertical neighbors. The eight-neighbor region
around a pixel consists of all the immediately adjacent pixels.
7. Select output to “File” or “Memory.”
8. Click “OK” to start the processing.
Combining Classes
Use Combine Classes to selectively combine classes in classified images. You can
also merge classes using Overlay > Classification from the Display menu in the Main
Image window (see “Merging Classes” on page 246 for details).
Note
Combining classes or removing the “unclassified” class effectively deletes those
individual classes.
3. After the input classification data has been selected, click “OK.”
The Combine Classes Parameters dialog appears.
4. In the Combine Classes Parameters dialog, select a class for input by clicking
on a name in the “Input Classes” list.
The selected class name appears in the “Input Class” text box.
5. Select an output class by clicking on a class name in the “Output Classes” list.
6. When both the input and output classes have been selected, click “Add
Combination” to finalize the selection.
The new, combined class to be created are shown in the “Combined
Classes” list at the bottom of the dialog. For example, selecting region 1 as
the input and region 3 as the output causes the string region 1 ->
region 3 to appear in the “Combined Classes” list.
8. When the Combine Classes Output dialog appears, select output to “File” or
“Memory.”
A status window appears while the classes are processed. The new classified image
name is added to the Available Bands List where it can be displayed using standard
ENVI procedures.
Overlaying Classes
Use Overlay Classes to produce an image map with a color composite or grayscale
background image and the classes overlaid in color. It outputs a three-band RGB
image that can be displayed using standard ENVI procedures.
You can also overlay classes using the Overlay menu in the Main Image window. For
details, see “Overlaying Classes” on page 243.
Note
Due to the nature of the classification overlay, the background image should be
stretched and saved to byte output images prior to overlay.
Note
If your display is set to 8-bit color, the class overlay image may appear incorrect
when displayed due to the color quantization. However, on output, it will be correct.
2. When the file selection dialog appears, select the input classification file and
any spatial subsetting.
The Buffer Zone Image Parameters dialog appears.
3. In the list of classes, click on the class names to select which class(es) to
measure the distance to.
Note
If more than one class is selected, the distance will be from the pixel to the nearest
class.
4. Click the “Maximum Distance” arrow increment buttons to set the maximum
distance to measure, or type the value (in pixels) into the corresponding text
box.
Any pixels with a distance larger than this value will be set to the maximum
distance value.
5. From the Distance Kernel button menu, select “Floating Point” or “Integer”
output.
6. Select output to “File” or “Memory.”
7. Click “OK.”
4. In the “Population Minimum” text box, enter the minimum number of pixels
that must be contained in a region for it to become a segment.
5. Use the arrow toggle button to designate whether to consider eight or four
neighboring pixels for the connectivity.
Image Sharpening
Use Image Sharpening tools to automatically merge a low-resolution color image
with a high-resolution grayscale image (with resampling to the high-resolution pixel
size). ENVI has two image sharpening techniques, using an HSV transform, and
using a color normalization (Brovey) transform. The images must either be
georeferenced or have the same image dimensions. The RGB input bands for the
sharpening should be stretched byte data or selected from an open color display.
Tip
Create as many ratio combinations as needed by entering additional band pairs. All
ratios in the “Selected Ratio Pairs” list will be output as multiple bands in a single
file.
4. Click “OK.”
The Band Ratios Parameters dialog appears.
5. Select from the following options.
• To select a spatial subset, click “Spatial Subset” and use the standard
ENVI spatial subsetting procedures.
• To output the ratio values as byte data (instead of the default floating-point
type), select “Byte” from the “Output Data Type” button menu.
ENVI will stretch the output ratio values by mapping the values entered in
the “Min” and “Max” text boxes to 0 to 255.
• To change the byte stretching ratio data range, enter new “Min” and
“Max” values.
6. Select “File” or “Memory” output.
7. Click “OK.”
As the ratios are calculated, a status message is displayed.
When the ratio calculations have concluded, the ratio band names appear in the
Available Bands List and are available for display.
Tip
Click the “Stats Subset” button to calculate the statistics based on a spatial
subset or the area under an ROI. The calculated statistics are applied to the entire
file or to a spatial subset of the file. For instructions, see “Using Statistics
Subsetting” on page 558.
3. Enter resize factors less than 1 in the “Stats X/Y Resize Factor” text boxes
to sub-sample the data when calculating the statistics.
Tip
Enter a resize factor of less than 1 to increase the speed of the statistics calculations.
For example, using a resize factor of 0.1 will use every 10th pixel in the statistics
calculations.
2. In the Select Statistics Subset dialog, select one of the following options:
• To select a standard image spatial subset, click the “Calculate Stats On”
“Image Subset” button and subset using standard ENVI methods.
• To select a ROI as the subset, click the “Calculate Stats On” “ROI” button
to display a list of ROIs, then click on the ROI name to select it.
Tip
To add a previously saved ROI to the list of ROIs, click the “Restore ROIs” button
in the subset dialog, select the ROI file, then select the ROI.
Figure 7-4: The Select Statistics Subset dialog for “Image Subset” calculation
(left), or “ROI” calculation (right).
Tip
If you need to prevent certain pixels from being used when computing the statistics
for the Principal Components Analysis rotation, first make a mask of the bad pixels,
then use Basic Tools > Statistics to compute the covariance statistics on the masked
image. You can then use this statistics file to do the Principal Components
Analysis.
more noise. Sometimes only those bands with large eigenvalues are output
to save disk space.
C. In the Select Output PC Bands dialog, click “OK.”
The output PC rotation will contain only the number of bands that you
selected. For example, if you chose “4” as the number of output bands,
only the first four PC bands will appear in your output file.
7. In the Forward PC Rotation Parameters dialog, click “OK.”
When ENVI has finished processing, the PC EigenValues plot window appears and
the PC bands are loaded into the Available Bands List where you may access them
for display. For information on editing and other options in the eigenvalue plot
window, see “Using Interactive Plot Functions” on page 343.
Inversing PC Rotations
Use Inverse PC Rotation to transform principal component images back into their
original data space.
1. Select Transforms > Principal Components > Inverse PC Rotation.
2. When the standard ENVI file selection and subsetting dialogs appear, select
and subset your input file using the standard ENVI file selection procedures.
Another file selection dialog appears with all of the existing statistics files in
the current input data directory listed. The statistics files appear with the
default file extension .sta.
3. Select the statistics file saved from the forward PC rotation.
Note
The statistics file must already exist prior to selecting the inverse PC rotation.
When ENVI has finished processing, the bands are loaded into the Available Bands
List where they may be displayed using standard gray-scale or RGB color composite
methods.
For more information about MNF transforms, see the following references:
Green, A. A., Berman, M., Switzer, P., and Craig, M. D., 1988, A transformation for
ordering multispectral data in terms of image quality with implications for noise
removal: IEEE Transactions on Geoscience and Remote Sensing, v. 26, no. 1,
p. 65-74.
Boardman, J. W., and Kruse, F. A., 1994, Automated spectral analysis: a geological
example using AVIRIS data, north Grapevine Mountains, Nevada: in Proceedings,
ERIM Tenth Thematic Conference on Geologic Remote Sensing, Environmental
Research Institute of Michigan, Ann Arbor, MI, pp. I-407 - I-418.
3. In the “Enter Output Noise Stats Filename [.sta]” text box, enter a filename
for the noise statistics.
• To select a homogeneous area for calculating the noise statistics, click the
“Spatial Subset” button and use ENVI’s standard spatial subset procedures
to either manually enter a subset or to graphically indicate the area for
statistics extraction (see “Selecting a Spatial Subset” on page 45).
4. In the “Enter Output MNF Stats Filename [.sta]” text box, enter an output file
for the MNF statistics.
Warning
Be sure that the MNF and noise statistics files have different names.
D. Click “OK” in the Select Output MNF Bands dialog to complete the
rotation.
• To limit the number of output MNF bands without selecting a subset from
eigenvalues, enter the desired number of output bands or use the arrow
increment buttons next to the “Number of Output MNF Bands” label.
7. Click “OK” to start the processing.
When ENVI has finished processing, it loads the MNF bands into the Available
Bands List and displays the MNF EigenValues Plot Window. The output only
contains the number of bands you selected for output. For example, if your input data
contained 224 bands, but you selected only 50 bands for output, your output will only
contain the first 50 calculated MNF bands from you input file.
Bands with large eigenvalues (greater than one) contain data, and bands with
eigenvalues near one contain noise. Display the EigenImages (MNF bands) from the
Available Bands List and compare with the MNF EigenValue plot to determine
which bands contain data and which bands contain predominantly noise. In
subsequent processing of this data, spectrally subset the MNF bands to only include
those bands where the images appear spatially coherent and the eigenvalues are
above the break in slope of the MNF EigenValue plot. In the example shown in
Figure 7-6, you should only include the first ten to twelve MNF bands.
Note
The MNF statistics file does not contain normal data statistics. Only the needed
statistics are stored in MNF statistics file and the statistics labeled Covariance really
contain the transpose of the composite transformation array. This produces
incorrect values in the correlation matrix that should be ignored. The eigenvalues
and eigenvectors are those for the noise-whitened data (e.g., the second Principal
Components rotation) Statistics from the file that are missing are reported as cell
zeros).
Figure 7-5: In the Forward MNF Transform Parameters dialog, click the “Shift
Diff Subset” button to access standard ENVI Spatial Subset dialog.
those bands where the images appear spatially coherent and the eigenvalues are
above the break in slope of the MNF EigenValue plot. In the example shown in
Figure 7-6, you should only include the first ten to twelve MNF bands.
Note
The MNF statistics file does not contain normal data statistics. Only the needed
statistics are stored in MNF statistics file and the statistics labeled Covariance really
contain the transpose of the composite transformation array. This produces
incorrect values in the correlation matrix that should be ignored. The eigenvalues
and eigenvectors are those for the noise-whitened data.
2. When the standard ENVI file selection and subsetting dialogs appear, select
and subset your input file using the standard ENVI file selection procedures.
3. When the Dark Current Input File dialog appears, select the dark current file
and perform spatial subsetting as required.
The noise statistics are calculated using the dark current input file.
The Forward MNF Transform Parameters dialog appears.
4. In the “Enter Output Noise Stats Filename [.sta]” text box, enter an output file
for the noise statistics.
5. In the “Enter Output MNF Stats Filename [.sta]” text box, enter an output file
for the MNF statistics.
Warning
Be sure that the MNF and noise statistics files have different names.
1. Select Transforms > MNF Rotation > Inverse MNF Transform or Spectral >
MNF Rotation> Inverse MNF Transform.
2. When the standard ENVI file selection and subsetting dialogs appear, select
and subset a previously calculated MNF transform image using the standard
ENVI file selection procedures.
3. When the Enter Forward MNF Stats Filename dialog appears, enter the name
of the forward MNF statistics file and click “OK.”
4. When the Inverse MNF Transform Parameters dialog appears, select “File” or
“Memory” output.
5. From the “Output Data Type” menu, select the data type (byte, integer,
unsigned integer, long integer, unsigned long integer, floating point, double
precision).
6. Click “OK” to start the processing.
The inverse MNF results are loaded into the Available Bands List when the
processing is complete.
4. To delete a spectrum from the dialog, click on the spectrum and click “Delete
Spectrum.”
5. Click “Apply.”
The transformed spectra appear in the Forward MNF Spectra plot window and
can be input into the Mixture Tuned Matched Filtering Endmember Collection
dialog.
Color Transforms
Use Color Transforms to convert 3-band red, green, blue (RGB) images to one of
several specific color spaces and from the selected color space back to RGB.
Adjusting the contrast stretch between the two transforms, you can produce a color-
enhanced color composite image. Additionally, the value or lightness band can be
replaced by another band (usually of higher spatial resolution) to produce an image
that merges the color characteristics of one image with the spatial characteristics of
another image.
Note
This is done automatically in HSV Sharpening (see “Image Sharpening” on
page 551).
The color spaces supported by ENVI include the “Hue, Saturation, Value (HSV),”
the “Hue, Lightness, Saturation (HLS)” and the “USGS Munsell.”
The Munsell color system is used by soil scientists and geologists to characterize the
color of soils and rocks. This color system has been modified by the U. S. Geological
Survey to describe color in digital images. The transform converts RGB coordinates
into the color coordinates Hue, Saturation, and Value (HSV). Hue ranges from 0-360,
where 0 and 360 = blue, 120 = green, and 240 = red. Saturation ranges from 0 to 208
with higher numbers representing more pure colors. Value ranges from
approximately 0 to 512 with higher numbers representing brighter colors. For more
details, see the following reference:
Kruse and Raines, A technique for enhancing digital color images by contrast
stretching in Munsell color space, in Proceedings of the ERIM Third Thematic
Conference, Environmental Research Institute of Michigan, Ann Arbor, MI, 1994:
pp. 755-760.
The Munsell color transforms were written as an ENVI User Function, and the code
is included as an example (see munsell.pro in the ENVI lib directory).
Note
Color transforms require three bands for input. These bands should be stretched
byte data or selected from an open color display.
input file with at least 3 bands or a color display must be open to execute this
function. The stretch that is applied in the color display is applied to the input data.
The hues produced are in the range of 0 to 360 degrees (where red is 0 degrees, green
is 120 degrees, and blue is 240 degrees) and saturation and value in the range 0 to 1
(floating-point).
1. Select Transforms > Color Transforms > RGB to HSV.
2. When the RGB to HSV Input dialog appears, select the three bands to
transform from either a displayed color image or from the Available Bands
List (for detailed instructions, see “Selecting Bands from Color Displays”).
The RGB to HSV Parameters dialog appears.
3. Select “File” or “Memory” output.
4. Click “OK” to start the processing.
A status window appears. When the forward transform is completed, the HSV names
are entered into the Available Bands List where they can be displayed using standard
ENVI gray-scale or RGB color composite methods.
Selecting Bands from Color Displays
• To select your bands from a color display and use the displayed stretch
number, select a display number, such as “Display #1,” from the Input list.
• To select a spatial subset, click the “Spatial Subset” button.
When the Parameters dialog appears, ENVI automatically uses the RGB bands from
the selected window and lists them in the “Input RGB Bands” list.
Selecting Bands from the Available Bands List
Note
If you select bands from the Available Bands List, no stretching will be applied and
all data will be clipped to byte type.
3. Click “OK.”
The Parameters dialog appears.
Transforming RGB to HLS
Use RGB to HLS to transform an RGB image into the HLS (hue, lightness,
saturation) color space. The hues produced are in the range of 0 to 360 degrees
(where red is 0 degrees, green is 120 degrees, and blue is 240 degrees) and lightness
and saturation in the range 0 to 1 (floating-point). An input file with at least 3 bands
or a color display must be open to execute this function. The input RGB values must
be byte data in the range 0 to 255.
1. Select Transforms > Color Transforms > RGB to HLS.
2. When the RGB to HLS Input dialog appears, select the three bands to
transform from either a displayed color image or from the Available Bands
List (for detailed instructions, see “Selecting Bands from Color Displays” on
page 576).
3. Select “File” or “Memory” output.
4. Click “OK” to start the processing.
A status window displays the progress of the operation. When the forward transform
is complete, the HLS names are entered into the Available Bands List where they can
be displayed using standard ENVI gray-scale or RGB color composite methods.
The transform process is reported in the Synthetic Color Processing dialog and the
resulting synthetic color image bands are available for display from the Available
Bands List.
Using NDVI
Use the NDVI (Vegetation Index) to transform multispectral data into a single image
band representing vegetation distribution. The NDVI (Normalized Difference
Vegetation Index) values indicate the amount of green vegetation present in the
pixel—higher NDVI values indicate more green vegetation. ENVI’s NDVI uses the
standard algorithm:
NIR – Red ö
æ ---------------------------
NDVI =
è NIR + Redø
Valid results fall between -1 and +1. ENVI has pre-set bands for AVHRR, Landsat
MSS, Landsat TM, SPOT, or AVIRIS data or you can enter the bands to use for other
data types. For more information, see the following reference:
Jensen, J. R., 1986. Introductory Digital Image Processing, Prentice-Hall, New
Jersey, p. 379.
1. Select Transforms > NDVI (Vegetation Index).
2. When the NDVI Calculation Input File window appears, select the input file
and perform any subsetting.
3. Click “OK.”
4. In the NDVI Calculation Parameters dialog, specify the input file type (TM,
MSS, AVHRR, etc.) from the “Input File Type” pulldown menu.
The bands used to calculate the NDVI are automatically entered into the
“Red” and “Near IR” text boxes.
• To calculate the NDVI for a sensor type not listed in the pulldown
menu, enter the desired band numbers in the “Red” and “Near IR” text
boxes.
5. From the “Output Data Type” button menu, select either byte or floating-
point output.
• If you select byte output, enter the minimum NDVI value. This value
will be set to zero.
• If you select floating-point output, enter the maximum value. This value
will be set to 255.
6. Select “File” or “Memory” output.
7. Click “OK.”
A status message appears while the transform is calculated. When complete, ENVI
enters the NDVI band name into the Available Bands List.
Convolution Filters
Use Convolutions to apply convolution filters to image data. Convolution filter types
in ENVI include the following: high pass, low pass, Laplacian, directional, Gaussian
High Pass, Gaussian Low Pass, median, Sobel, Roberts, and user-defined. Each filter
type is described in this section. For detailed instructions, see “Using Convolution
Filters” on page 591.
Laplacian Filters
A Laplacian filter is a second derivative edge enhancement filter that operates
without regard to edge direction. Laplacian filtering emphasizes maximum values
within the image by using a kernel with a high central value typically surrounded by
negative weights in the north-south and east-west directions and zero values at the
kernel corners. ENVI’s default Laplacian filter uses a 3 x 3 kernel with a value of “4”
for the center pixel and values of “-1” for the north-south and east-west pixels. All
Laplacian filters must have odd kernel sizes.
Directional Filters
A directional filter is a first derivative edge enhancement filter that selectively
enhances image features having specific direction components (gradients). The sum
of the directional filter kernel elements is zero. The result is that areas with uniform
pixel values are zeroed in the output image, while those that are variable are
presented as bright edges.
Gaussian Filters
A Gaussian filter passes a Gaussian convolution function of specified size over the
image. The default is a 3 x 3 kernel and kernel dimensions must be odd.
Median Filters
Median filtering smooths an image, while preserving edges larger than the kernel
dimensions (good for removing salt and pepper noise or speckle). ENVI’s Median
filter replaces each center pixel with the median value (not to be confused with the
average) within the neighborhood specified by the filter size. The default is a 3 x 3
kernel.
Sobel Filters
The Sobel filter is a non-linear edge enhancement, special case filter that uses an
approximation of the true Sobel function, and is a preset 3 x 3, non-linear edge
enhancement operator. The size of the filter cannot be changed and no kernel editing
is possible.
Roberts Filters
The Roberts filter is a non-linear edge detector filter similar to the Sobel. It is a
special case filter that uses a preset 2 x 2 approximation of the true Roberts function,
a simple, two dimensional differencing method for edge-sharpening and isolation.
The size of the filter cannot be changed and no kernel editing is possible.
The kernel sizes are in odd-number increments. Clicking with the left mouse
button increases/decreases the value by 2, clicking with the middle mouse
button increases/decreases value by 10, and clicking with the right mouse
button sets the kernel size back to 3 x 3.
By default, the kernel size is set to a square kernel.
• To change to a non-square kernel, select Options > Square kernel:No.
Note
The Median filter is always a square.
4. Enter an add back value in the “Image Add Back (0-100%)” text box.
“Adding back” part of the original image to the convolution filter results helps
preserve the spatial context and is typically done to “sharpen” an image. The
Image Add Back value is the percentage of the original image that is included
in the final output image. For example, if you enter 40%, then 40% of the
original image is added to 60% of the convolution filter image to produce the
final result.
5. Select an “apply” method as described in “Applying Convolution and
Morphology Filters” on page 596.
Figure 8-2: The Convolution and Morphology Tool dialog with a convolution filter
type selected.
Editing Kernels
To edit the selected kernel and change any of the weight values:
1. In the Convolutions and Morphology Tool, double-click within the text box of
the value to be edited.
The line cursor appears.
2. Highlight the value, enter a new value, and press the “Return” key.
Morphology Filters
Use Morphology to apply morphological filters to image data. Morphology filter
types in ENVI include the following: Erode, Dilate, Opening, and Closing. Each
filter type is described in this section. For detailed instructions, see “Using
Morphology Filters” on page 595.
Dilate Filters
Dilate filters, commonly known as “fill,” “expand,” or “grow,” fills holes smaller
than the structural element (kernel) in a binary or grayscale image.
Erode Filters
The Erode filter, commonly known as “shrink” or “reduce,” removes islands of
pixels smaller than the structural element (kernel) in a binary or grayscale image.
Opening Filters
Opening filters smooth the contours, break narrow isthmuses, and eliminate small
islands and sharp peaks or capes in an image. The “opening” of an image is defined
as the erosion of the image followed by subsequent dilation using the same structural
element.
Tip
Using the Erode filter followed by using the Dilate filter produces the same result as
using an Opening filter.
Closing Filters
Closing filters smooth the contours, fuse narrow breaks and long thin gulfs, eliminate
small holes, and fill gaps in the contours of an image. The “closing” of an image is
defined as the dilation of the image followed by subsequent erosion using the same
structural element.
Tip
Using the Dilate filter followed by using the Erode filter produces the same result as
using the Closing filter.
Figure 8-3: The Convolutions and Morphology Tool dialog with a morphology
filter type selected.
A status message appears. If no image tiling is required, the status message does not
advance gradually. It goes abruptly from 0 to 100% after a short wait because the
operation is being performed on the entire image array. When completed, the filtered
image is added to the top of the Available Bands List and can be displayed using
standard ENVI procedures.
Note
If you select a band for input, spectral subsetting is not available.
3. Click “OK.”
The resulting file appears in a display window. The file displayed is a
temporary file placed in the default temporary ENVI directory (see “Setting
ENVI Preferences” on page 160). The display window and the file are
automatically deleted when the Convolutions and Morphology Tool dialog is
closed.
• If you change any parameters in the Convolutions and Morphology Tool
dialog, click the “Quick Apply” button again.
The new parameters overwrite the existing results.
Changing the Quick Apply Input Band
To change the band used for the Quick Apply output:
1. In the Convolutions and Morphology Tool dialog, select Options > Change
Quick-Apply Input Band.
2. In the file selection dialog, select the input band and any subsetting.
Note
If you select a band for input, spectral subsetting is not available.
3. Click “OK.”
Saving Quick Apply Results
To save the Quick Apply image result to a file:
1. Select File > Save Quick Result to File.
2. When the Output Convolution Filename dialog appears, enter an output
filename.
3. Click “OK.”
5. Enter the size of the processing window in the “Rows” (Y) and “Cols” (X) text
boxes to set the area to be considered for the texture evaluation.
6. Select output to “File” or “Memory.”
7. Click “OK” to start the processing.
The texture images selected are calculated and placed in the Available Bands List.
are used to create the co-occurrence matrix. See the following references for more
information.
Haralick, R. M., Shanmugan, K., and Dinstein, I., 1973, “Textural Features for Image
Classification,” IEEE Transactions on Systems, Man, and Cybernetics, Vol. 3, No. 6,
pp. 610-621.
Anys, H., A. Bannari, D. C. He, and D. Morin, 1994. Texture analysis for the
mapping of urban areas using airborne MEIS-II images, in Proceedings of the First
International Airborne Remote Sensing Conference and Exhibition, Strasbourg,
France, Vol. 3, pp. 231-245.
4. Select the texture images to be created by clicking on the check boxes next to
the texture types in the “Textures to Compute” portion of the dialog.
5. Enter the size of the processing window in the “Rows” (Y) and “Cols” (X) text
boxes.
6. Enter the X and Y shift values used to calculate the co-occurrence matrix (see
above for example).
7. Select output to “File” or “Memory.”
8. Click “OK” to start the processing.
The texture images selected are calculated and placed in the Available Bands List.
3. Click “OK.”
4. When the Lee Filter Parameters dialog appears, enter the desired filter size in
the “Filter Size” text box.
5. Select the desired noise model by clicking the toggle buttons next to the labels
“Additive,” “Multiplicative,” or “Both.”
Typically, speckle in radar images is multiplicative.
6. Select from the following options:
• To change the “Additive Noise Mean” and “Multiplicative Noise Mean”
default values of 0.0 and 1.0, respectively (the typical noise means), enter
values in the appropriate text boxes.
Larger noise mean values will produce less smoothing.
• To change the “Noise Variance” value, enter a new value in the text box.
The “Noise Variance” parameter is set to the additive noise variance when
“Additive” and “Both” noise models are chosen. It is set to the
multiplicative noise when the “Multiplicative” noise model is chosen.
Tip
An estimate of the noise variance can be obtained by calculating the data variance
over a flat area, such as a lake or smooth playa, in the image. For multiplicative
noise in radar data, the noise variance can be estimated by 1/(number of looks).
3. Click “OK.”
4. When the Frost Filter Parameters dialog appears, enter the desired filter size in
the “Filter Size” text box.
5. Enter the desired value in the “Damping Factor” text box.
The “Damping Factor” determines the amount of exponential damping and the
default value of 1 is sufficient for most radar images. Larger damping values
preserve edges better but smooth less, and smaller values smooth more. A
damping value of 0 results in the same output as a low pass filter.
6. Select output to “File” or “Memory.”
7. Click “OK” to execute the filter.
A status window displays the progress of the operation.
3. Click “OK.”
4. When the Kuan Filter Parameters dialog appears, enter the filter size in the
“Filter Size” text box.
5. Enter the number of looks in the appropriate text box.
The “Number of Looks” parameter is used to calculate the noise variance by
1/(number of looks).
6. Select output to “File” or “Memory.”
7. Click “OK” to execute the filter.
A status window displays the progress of the operation.
3. Click “OK.”
4. When the Localized Sigma Filter Parameters dialog appears, enter the filter
size in pixels.
5. Enter the number of standard deviations to consider valid in the “Sigma
Factor” text box.
The “Sigma Factor” is used to determine which pixels are valid by calculating
a minimum and maximum pixel value based on the number of standard
deviations (sigma) entered and the local statistics.
The pixel being filtered will be replaced by the average of surrounding valid
pixels
6. Select output to “File” or “Memory.”
7. Click “OK” to execute the filter.
A status window displays the progress of the operation.
3. Click “OK.”
4. When the Bit Error Removal Parameters dialog appears, enter the filter size in
pixels.
5. Enter a “Sigma Factor” for the number of standard deviations to be used for
determining valid pixels.
6. Enter a tolerance (in data values).
Pixels are only considered “bad” if they have a value greater than the
tolerance. A pixel is classified as a bit error when the pixel value minus the
filter box mean is greater than the Sigma Factor times the localized standard
deviation and greater than the tolerance. The “bad” pixels will be replaced by
the average of surrounding valid pixels by default.
7. To set bad pixels to zero instead of replacing them with an average, click
“Yes” next to the “Zero Bit Errors?” text label.
8. Optionally, enter the minimum and maximum values to be considered as valid
data for the mean determination in the “Valid Data Min” and “Valid Data
Max” text boxes.
9. Select “File” or “Memory” output.
10. Click “OK” to execute the filter.
A status window displays the progress of the operation.
3. Click “OK.”
• For Band Pass or Band Cut filters, enter values, in pixels, in the “Inner
Radius” and “Outer Radius” text boxes.
• For User Defined Pass and User Defined Cut filters, you can load ENVI
annotation (polygons and shapes only) into the filter (see “Loading
Annotation into User-Defined Filters” on page 615).
5. Click the arrow buttons to select the “Number of Border Pixels” used to taper
the filter (smooth the edges of the filter).
A value of zero indicates no smoothing.
Figure 8-10: From left to right: Circular Pass (low pass), Circular Cut (high pass),
Band Pass, Band Cut, and User Defined Filters. The diagonal lines in the first
four images and the grid lines in the fifth image represent the area that
will be filtered out.
3. Click “OK.”
4. When the Inverse FFT Filter File dialog appears, select the filter image
to apply.
Note
The filter image must have been generated previously using the filter definition
procedures described in “Defining FFT Filters” on page 612.
5. Click “OK.”
6. When the Inverse FFT Parameters window appears, with the input file
characteristics listed, select either output to “File” or “Memory.”
7. Select the output data type (byte, integer, floating point, etc.) from the
appropriate pulldown menu.
8. Click “OK” to process the image.
The FFT-filtered image can be displayed using standard ENVI procedures.
Spectral Libraries
Use Spectral Libraries to access several included public domain spectral libraries
that are included with ENVI. Spectral libraries developed at Jet Propulsion
Laboratory contain spectra for three different grain sizes of approximately 160 “pure”
minerals from 0.4 to 2.5 µm. The public domain U. S. Geological Survey Spectral
library contains nearly 500 spectra of well-characterized minerals and a few
vegetation spectra. These data are provided in ENVI for the 0.4 to 2.5 µm range.
Spectral libraries from Johns Hopkins University contain spectra for materials from
0.4 to 14 µm. The IGCP 264 spectral libraries were collected as part of IGCP Project
264 during 1990. They consist of five libraries measured on five different
spectrometers for 26 well-characterized samples. Spectral libraries of vegetation
spectra were provided by Chris Elvidge, DRI measured from 0.4 to 2.5 µm. See
Appendix C, “ENVI Spectral Libraries” for more information and references
regarding the spectral libraries available in ENVI.
ENVI spectral libraries are stored in ENVI “image” format, with each line of the
image corresponding to an individual spectrum and each sample of the image
corresponding to an individual spectral measurement at a specific wavelength (see
“ENVI Spectral Library Files” on page 890). The ENVI spectral libraries can be
displayed and/or enhanced using the standard ENVI image display and analysis
routines.
2. Click and hold the left mouse button on the plot name and drag the plot name
to the Spectral Library Viewer plot window and release the left mouse button
(see “Moving Plots to Another Plot Window” on page 343).
Figure 9-2: The Spectral Library Viewer Dialog (left). Each name in the list is an
individual spectrum. The Spectral Library Viewer Plot Window is shown at right.
The user-defined filter function must take the form of an ENVI spectral library with
each sample of the image representing a wavelength value and each line of the image
representing an individual filter function. The value at each wavelength must be a
weight between 0 and 1, which is used as a multiplicative factor when applied to the
library being resampled. For an example of a filter function file, open the Landsat
TM file, tm_fsli (in the ENVI Spectral Library directory), as a spectral library file
and plot the filter functions.
1. In the Input Filter Function Spectral Library dialog, select the desired filter
function.
2. Click “OK.”
The resulting library appears in the Available Bands List.
Warning
It is not recommended to resample from a low resolution to a high resolution
spectrum. If you do this, the results may be spurious.
3. When the File Containing Output Wavelength dialog appears, select the input
file containing the wavelengths and optional FWHM values using standard
selection procedures.
• If you select “Input Data File,” the wavelengths and FWHM values (if
present) are read from the ENVI header file.
• If you select “Input ASCII File,” the column that contains the wavelength
values and FWHM (if present) must be selected.
4. Click “OK.”
The Spectral Library Builder dialog appears.
Drag-and-Drop
Window
Collecting Spectra
Use the Spectral Library Builder dialog (Figure 9-3) to collect endmember spectra
from a variety of sources. All spectra are automatically resampled to the selected
wavelength space
The methods for collecting spectra in the Spectral Library Builder dialog are exactly
the same as those for collecting spectra in the Endmember Collection dialog. For
detailed instructions, see “Using the Drag-and-Drop Window” on page 495,
“Importing Endmember Spectra” on page 496, “Endmember Options” on page 499
and “Managing Endmember Spectra” on page 502).
Spectral Slices
Use Spectral Slices to extract a combined spatial/spectral profile from a multiband
image. Slices in ENVI are saved as grayscale images, with the line direction (Y)
corresponding to the spatial dimension of the image being sliced (“horizontal,”
“vertical,” or “arbitrary”), the sample direction (X) corresponding to the spectral
dimension (the number of bands in the sliced image), and the grayscale (DN level)
showing the spectral intensity (reflectance, radiance, etc.) depending on the
calibration of the data.
You can slice images in either the horizontal direction (all of the bands for a single
line of the image), along the vertical direction (all of the bands for a singe pixel
column of the image), or in an arbitrary direction that you define using ROI polyline
selection (see “Drawing ROIs” on page 263). The resulting slice is an ENVI image
with the number of samples equal to the number of spectral bands and the number of
lines equal to the number of samples (for a horizontal slice), number of lines (for a
vertical slice), or total number of pixels along the ROI polyline (for an arbitrary
slice).
procedures prior to executing the arbitrary slice function. Typically, the arbitrary
slice is defined using the “Polyline” option for defining ROIs (see “Drawing
Polylines” on page 265), however, polygons or points can also be used. All the pixels
included in the ROI are used to make the spectral slice.
1. Select Spectral > Spectral Slice > Arbitrary Slice.
2. When the Spectral Slice Input File dialog appears, select an input file and any
spectral subsetting.
The Spectral Slice Parameters dialog appears with the file characteristics and
processing options listed.
• If only one ROI is currently defined, it is automatically used for the arbitrary
slice.
• If more than one ROI exists, you can select the ROI to be used for the slice by
clicking on the name of the desired region in the “Select Region for Spectral
Slice” list.
3. Select either “File” or “Memory” output.
4. Once all of the parameters have been entered, click “OK” to continue.
The arbitrary spectral slice image is added to the Available Bands List and can be
viewed and processed using standard ENVI functions.
MNF Rotations
Use the MNF Rotation (minimum noise fraction) transforms to determine the
inherent dimensionality of image data, to segregate noise in the data, and to reduce
the computational requirements for subsequent processing. For a detailed explanation
and instructions, see “Minimum Noise Fraction Transform” on page 563.
and used as input into ENVI’s n-D visualizer (see “The n-Dimensional Visualizer”
on page 636).
1. Select Spectral > Pixel Purity Index > New Output Band or [FAST] New
Output Band.
2. When the Pixel Purity Index Input File dialog appears, select an input file and
any subsetting using standard ENVI procedures.
Tip
Typically, run the PPI on an MNF transform result, and use spectral subsetting to
exclude noise bands based on the eigenimages and eigenvalue plot (see
“Calculating Forward MNF Transforms” on page 564).
The more iterations run, the better job ENVI does of finding the extreme
pixels. Balance the number of iterations against the time available, as each
iteration can take some time depending on the CPU and system load. Typically
thousands of iterations are required for imaging hyperspectral data. The
number of iterations run is listed in the description line of the image header
file.
4. When the Pixel Purity Index Previous Result dialog appears, select a previous
PPI image as the input file and click “OK.”
5. When the Pixel Purity Index Parameters dialog appears, select the number of
iterations and threshold as described in the previous sections.
• For FAST PPI, enter a X and Y Resize Factor if desired.
6. Click “OK” to start the processing.
A processing status window and the Pixel Purity Index plot appear. The PPI image
appears in the Available Bands List when the processing is completed.
3. In the image window, select Overlay > Region of Interest > Image
Threshold to ROI to create an ROI containing only the pixels with high PPI
values (see “Converting Band Values to ROIs” on page 279)
Typically, use a minimum threshold. For example, a minimum of 10 will include all
of those pixels with PPI values greater than 10 in the ROI. However, if bad data
points exist in the PPI image, both a minimum and maximum threshold can be used.
Once an ROI has been created containing the high PPI values, you can use the n-
Dimensional Visualizer (see the following section) to interactively define the image
endmembers.
cloud in the n-D Visualizer and modify the endmembers, as needed, using the tools
described in “The n-Dimensional Visualizer” on page 636.
Warning
The pre-clustering result is only a “first cut” attempt at selecting endmembers. You
should examine the data cloud and modify the endmember selections as needed.
1. From the ENVI main menu, select Spectral > n-Dimensional Visualizer >
Precluster from MNF/PPI.
2. In the input file selection dialog, select the MNF input file.
3. In the next input file selection dialog, select the PPI input file.
4. In the n-D Precluster Parameters dialog, enter the maximum number of input
pixels to use in the n-D Visualizer.
Smaller numbers animate in the n-D Visualizer faster and show only the purest
pixels; larger numbers give a better overall picture of the scatter plot, but
animate more slowly and may make selection of the corners more difficult. A
threshold is automatically applied to the PPI image to obtain the best PPI
pixels to use in the n-D Visualizer without exceeding the selected maximum.
The n-D Visualizer plot window and Controls dialog appear. The precluster
results are shown as colored pixels in the n-D Visualizer plot window.
5. Rotate the data cloud to assess the results and modify them as needed.
• The scatter plot can be rotated in “n” dimensions to isolate specific groups of
pixels.
Figure 9-8: The n-D Controls dialog (right) and the n-D Visualizer (left).
If you select three dimensions, you have the option of “driving” the axes, or
initiating automatic rotation.
If you select more than three dimensions, only automatic random rotation is
available.
Defining Classes
Typically, classes are defined where groups of pixels stay together during rotation
and are separated from the rest of the pixels. Multiple classes can be defined at once.
Use the Z-Profile option to aid in defining classes (see “N-D Visualizer/Controls
Options” on page 644).
1. Click the “Stop” button to stop the rotation when a group of pixels is isolated
from the main body of pixels that are plotted in the n-D Visualizer. Or, use the
arrow buttons to go to a particular projection view.
2. Highlight the desired pixels on the n-D Visualizer using standardized ENVI
polygon selection procedures (left button to set a vertex, right mouse button to
close the polygon).
• If a 3-D projection is selected, be sure to select Options > 3D: ROI
Definition.
3. From the “Class” menu, select a color for the class.
• To automatically use the next available class color for the next ROI, select
Class > New.
4. Click the “Start” button to rotate the scatterplot until additional groups of
pixels are isolated and repeat the class definition process.
Interacting with Classes
Use the n-D Class Controls dialog to interact with individual classes. The number of
points in each defined class and the class color are listed in the dialog. You can
change the symbol used, turn individual classes on and off, and select classes to use
when collapsing classes. You can also plot the minimum, maximum, mean, and
standard deviation spectra for a class, plot the mean for a class alone, and /or plot all
the spectra within a class. Also, you can clear a class and export a class to an ROI.
1. In the n-D Controls dialog, select Options > Class Controls.
All of the defined classes appear in the dialog. The white class contains all of
the unclustered or unassigned points. The number of points in each class is
shown in the text boxes next to the colored squares.
Turning Classes On/Off
• To turn a class off in the n-D Visualizer window, click the “On” check box for
that class. Click again to turn it back on.
• To turn all but one of the classes off in the n-D Visualizer window, double-
click on the colored box of the class that you want to remain displayed. Double
click again to turn the other classes back on.
Selecting the Active Class
• To designate a class as the active class, click on the colored square
corresponding to that class.
The color appears next to the “Active Class” label and any functions executed
from the Class Controls dialog affect only that class.
Note
A class may be selected as the active class even though it is not turned on in the n-D
Visualizer.
Clearing Classes
• To remove all points from a class, click the “Clear” button.
Exporting Classes
• To export the points to an ROI, click “Export.”
Collapsing Classes
In the n-D Visualizer use Collapse Classes by Means and Collapse Classes by
Variance to make class definition easier when the dimensionality of a data set is
higher than four or five. With more than four or five dimensions, it is often difficult
to interactively identify and define many classes. Both collapsing methods involve an
iterative collapsing of the data cloud based on the classes defined. To collapse the
data, a projection is calculated (based either on class means or covariance) to
minimize or hide the space spanned by the already defined classes and to maximize
or enhance the remaining variation in the data set. The data are subjected to this
special projection and replace the original data in the n-D Visualizer. Additionally, an
eigenvalue plot is displayed showing the residual spectral dimension of the collapsed
data. The collapsed classes should form a tight cluster so the remaining pixels can be
more readily examined. The dimensionality of the data, shown by the eigenvalue
plot, should drop with each collapse.
1. Select Options > Collapse Classes by Means or Collapse Classes by Variance
(see the descriptions in the following sections).
An eigenvalue plot is displayed, showing the remaining dimensionality of the
data and suggesting the number of remaining classes to be defined. The “n-D
Selected Bands” widget changes color to red to indicate that collapsed data is
being displayed in the n-D Visualizer.
2. Use the low number bands to rotate and to select additional classes.
3. Select Options > Collapse Classes by Means or Collapse Classes by Variance
again to collapses all of the defined classes.
4. Repeat these steps until all of the desired classes have been selected.
Note
The data can be “Uncollapsed” to the original data at any time.
Adding Annotation
• To add an annotation to the n-D visualizer window, select Options > Annotate
Plot.
Note
You cannot add borders to the n-D Visualizer window (see “Annotating Images” on
page 222 for details).
Plotting Z Profiles
• To open a plot window containing the spectrum of a point selected in the n-D
Visualizer:
1. Select Options > Z Profile.
2. When the file selection dialog appears, select the data file associated with the
n-D data.
Typically, this file is the reflectance or original data.
• If you select an input file of different spatial dimensions than the file used
for input into the n-D Visualizer, you will be prompted to enter the X and
Y offsets that point to the n-D subset.
3. Select from the following options:
• To plot the Z profile for the point nearest the cursor, click the middle
mouse button in the n-D plot window.
• To add plots to the Z profile plot window in the n-D Visualizer plot
window, click the right mouse button in the n-D plot window.
When the Z profile plot window is open, the selected file is automatically used
to calculate the mean spectra when you select Options > Mean Class or Mean
All.
Importing Spectra
To import spectra from other sources such as spectral libraries:
1. Select Options > Import Library Spectra.
The input spectra must be in the same space as the n-D input data (i.e., MNF
space).
Tip
To convert the spectra to MNF, use the Transforms > MNF Rotation > Apply
Forward MNF to Spectra function and use the statistics you saved when you ran the
MNF on the original data (see “Minimum Noise Fraction Transform” on page 563).
2. When the n-D Visualizer Import Spectra dialog appears, drag spectra into the
black draw widget or import spectra from a Spectral Library, ROI, or ASCII
file using the Import menu. For detailed instructions, see “Collecting
Endmember Spectra” on page 495 for details.
3. Click “Apply.”
4. When the Import Spectra Parameters dialog appears, select from the following
options to set the spectra parameters.
• To edit a spectrum name, click on the spectrum and make any changes in
the “Name” text box.
• To edit the spectrum color, click on the name and select a color from the
“Color” button menu.
• To plot the spectrum in the n-D Visualizer plot window, click in the
“Show Spectrum” check box.
5. Click “OK.”
The spectra appear in the n-D Visualizer plot window as stars with the name
labels next to them. Note that some spectra may fall outside the current
projection and will not be visible until you rotate the data.
Deleting Spectra
To delete imported library spectra from the n-D Visualizer:
1. Select Options > Delete Library Spectra.
2. Select the spectra to delete and click “OK.”
Editing Spectra Parameters
To change the color or name of imported library spectra and to turn spectra on or off
in the n-D Visualizer:
1. Select Options > Edit Library Spectra.
2. In the Import Spectra Parameters dialog, select the spectra to edit by clicking
on the names.
3. Edit the color, change the names, and turn the “Show Spectrum” check box on
or off for the individual spectra and click “OK.”
Warning
ENVI does not keep track of which classes have already been exported to ROIs. If a
selected class is exported more than once, multiple (identical) ROIs will be created.
Saving States
• To save the n-D Visualizer state, select File > Save State and enter an output
filename with the extension .ndv for consistency.
Mapping Methods
ENVI has many spectral mapping methods which include binary encoding, spectral
angle mapping, linear band prediction (LS-Fit), linear spectral unmixing, matched
filtering, mixture tuned matched filtering, continuum removal, and spectral feature
fitting.
endmembers and changing the endmembers changes the results. For additional
information, see “Spectral Tools References” on page 694 and “Spectral Unmixing
Results” on page 653.
ENVI linear spectral unmixing has two constraint options: unconstrained or a
partially constrained unmixing. In the unconstrained method, abundances may
assume negative values and are not constrained to sum to unity (one). ENVI also
supports an optional, variable-weight, unit-sum constraint in the Linear Mixing
algorithm. This was implemented to allow for user-defined weighting of a sum-to-
unity constraint on the abundance fractions. It also permits proper unmixing of MNF-
transform data, with zero-mean bands. The user picks a weight factor, default value
of one, for the extra constraint equation. This weighted unit-sum constraint is then
added to the system of simultaneous equations in the unmixing inversion process.
Larger weights in relation to the variance of the data cause the unmixing to honor the
unit-sum constraint more closely. To strictly honor the constraint, make the weight
many times the spectral variance of the data.
Note
If not all endmembers are known or if you only want to map a few endmembers, use
Matched Filtering or Mixture Tuned Matched Filtering (see “Using Matched
Filtering” on page 655 and “Using Mixture Tuned Matched Filtering” on
page 657).
Drag-and-Drop
Window
4. When all of the desired endmembers have been collected, click “Apply” at the
bottom of the Endmember Collection:Unmixing dialog.
The Unmixing Parameters dialog appears.
5. If you want to apply a unit sum constraint in the unmixing, use the arrow
toggle button to select “Yes.”
• If you select “Yes,” enter a weight in the appropriate text box.
This weight is added to the system of simultaneous equations in the unmixing
inversion process. Larger weights cause the unmixing to honor the unit-sum
constraint more closely.
6. Select either output to “Memory” or “File.”
7. Click “OK” to begin the spectral unmixing.
A processing status window appears.
Spectral Unmixing Results
The results of spectral unmixing appear as a series of gray-scale images, one for each
endmember, plus a root-mean-square (RMS) error image. Higher abundances (and
higher errors for the RMS error image) are represented by brighter pixels (larger
floating-point numbers). For example, in Figure 9-10, the brighter pixels represent
high abundances of cultivated vegetation unmixed from the other components using
an ROI spectrum and the linear spectral unmixing technique. The unmixing results
should have a data range (representing endmember abundance) from 0-1. However,
negative values and values greater than one are possible. Infeasible abundances
indicate erroneous endmembers. The results are dependent on the input endmembers
and will change if the endmembers are changed. View the RMS error image to help
determine areas of missing or incorrect endmembers.
8. From the “Output Data Type” menu, select an output data type: floating point
or byte.
• If you select “Byte,” enter a minimum and maximum data value to stretch
to.
9. Click “OK” to start the processing.
• If you selected “Use Existing Stats File,” select the statistics file that
corresponds to the input data file when the file selection dialog appears.
Note
This statistics file must contain both the mean and covariance statistics for the
input data.
The data histogram of the background material is centered around 0 and the
target (endmember) appears in the upper tail of the histogram (see Figure 9-
11). Therefore, the data in the upper tail of the histogram should be stretched
over the range from about 0.1 to about 0.65 to show only pixels containing the
target material. Image values in the symmetric histogram distribution centered
on 0 are background areas.
Tip
To set a default stretch range so that the data does not have to be stretched each time
it is displayed, see “Editing ENVI Headers” on page 99.
1. Select Spectral > Mapping Methods > Mixture Tuned Matched Filtering.
2. When the Mixture Tuned Matched Filter Input File selection dialog appears,
select the input MNF file and any spatial or spectral subsetting.
3. Click “OK.”
The Endmember Collection:Mixture Tuned Matched Filter dialog appears.
4. Import spectra (in MNF space) to be matched.
For detailed instructions, see “Using the Drag-and-Drop Window” on
page 495, “Importing Endmember Spectra” on page 496, “Endmember
Options” on page 499 and “Managing Endmember Spectra” on page 502).
The spectra must be in the MNF space. They can be calculated from ROIs
found in the MNF input file or transformed into MNF space (see “Applying
Forward MNFs to Spectra” on page 572).
Warning
The input spectra must be pure and spectrally extreme endmembers for the mixture
tuned matched filtering to be interpretable. These types of endmembers can be
found using ENVI’s PPI and n-D Visualizer (see the ENVI Advanced
Hyperspectral Analysis Tutorial).
The continuum is removed by dividing it into the actual spectrum for each
pixel in the image. The resulting image spectra are equal to 1.0 where the
continuum and the spectra match and less than 1.0 where absorption features
occur. Continuum removal can be performed on data files or on individual
spectra in a plot window. For references, see “Spectral Tools References” on
page 694.
1. Select Spectral > Mapping Methods > Continuum Removal.
2. When the Continuum Removal Input File dialog appears, select the input file
and any spatial subsetting, spectral subsetting, or masking.
Tip
For the best results, spectrally subset around the region containing the absorption
features of interest.
3. Click “OK.”
4. When the Continuum Removal Parameters dialog appears, select output to
“Memory” or “File.”
5. Click “OK” to begin processing.
A processing status window appears. The results are listed in the Available Bands
list.
For detailed instructions, see “Using the Drag-and-Drop Window” on page 495,
“Importing Endmember Spectra” on page 496, “Endmember Options” on page 499
and “Managing Endmember Spectra” on page 502.
spectrally and spatially subsetting the data. It helps you to visualize the data in n-
dimensions and to cluster the purest pixels into endmembers and optionally allows
you to input user-supplied endmembers. It also allows you to map the distribution
and abundance of the endmembers and aids you in reviewing the mapping results.
Each step in the wizard executes a stand-alone ENVI function and all steps can be
performed using the individual functions separately if desired. Detailed
documentation for the functions used in this wizard can be found in this manual
under each separate function name (i.e. Forward MNF Transform, n-Dimensional
Visualizer, etc.). The name of the function to be executed appears in the top panel of
the screen. Results from specific steps are output to the Available Bands List and can
be viewed using standard ENVI methods. Various plots appear to help assess results
along the way.
The Wizard has individual panels that take you through the following steps, which
are outlined further in Figure 9-14 and explained step-by-step in “Using the Spectral
Mapping Wizard” on page 668.
1. Introduction
2. Input/Output file selection
3. Minimum Noise Transform (MNF)
4. Review of MNF results
5. Data dimensionality determination
6. Derive endmembers from data or select user endmembers
7. Pixel Purity Index (PPI)
8. Examine PPI results
9. n-Dimensional Visualization and endmember selection
10. Option to input user supplied endmembers
11. Mapping with the Spectral Angle Mapper (SAM) and/or Mixture Tuned
Matched Filtering (MTMF)
12. Investigate mapping results
13. Summary report.
Introduction
Input/Output
File Selection
Minimum Noise
Transform (MNF)
Data Dimensionality
Determination
NO
Derive Endmembers
from Data?
YES
NO
Mapping with SAM
and/or MTMF
Summary Report
Figure 9-14: The Spectral Mapping Wizard takes you through the these steps.
Each step in the flow chart represents a panel in the wizard.
Wizard Basics
To successfully use the Spectral Mapping Wizard, familiarize yourself with the basic
functions and concepts as shown in Figure 9-15 and as described following the
figure:
Function Title
Important Information
and instructions are
displayed in the upper
panel
Figure 9-15: The Spectral Mapping Wizard screen with the Select Input/Output Files
panels displayed.
• Text in the top panel of the Wizard provides background information and
guidance for each step. It is very important that you read this information
before proceeding with each step. Use the vertical and horizontal scroll bars to
view all of the text.
• Enter and select the parameters for that step using the buttons and text boxes in
the bottom panel.
• Use the “<-Prev” and “Next->” buttons to step through the wizard.
• Each processing step will execute when the “Next->” button is selected.
• If the “Next->” button is not available for selection make sure that all the
necessary parameters have been set.
• Use the “<-Prev” button to go back to a previous step to modify parameters
and to re-execute the process.
• The results of the processing steps appear in the Available Bands List.
• You can examine the results of a function at any time during the wizard
process using standard ENVI display functions.
• Various plots are displayed during processing and can be saved by selecting
File > Save Plot As in the plot window.
• To use only a subset of a file to calculate noise statistics for the whole file,
click the “Shift Difference Spatial Subset” button.
6. Click the “Next->” button.
The Calculating Forward MNF panels appear and progress windows display
the status of the MNF process.
After the processing is complete, the View MNF Results panels and an
Eigenvalue plot window appear.
7. Choose whether to load the MNF result into an ENVI display as an RGB
image and/or load the MNF result as a grayscale animation.
Refer to the wizard text for descriptions of these two options. For details
about ENVI animation, see “Creating Animations” on page 378.
8. After displaying and analyzing the MNF result, click the “Next->” button in
the wizard.
The Determine Data Dimensionality panels appear.
9. In the Calculate Dimensionality panels, refer to the wizard text for instructions
before clicking the “Calculate Dimensionality” button or changing the “Data
Dimensionality” value.
10. Click the “Calculate Dimensionality” button.
The Spatial Coherence Threshold plot appears.
11. Evaluate the Spatial Coherence Threshold plot.
• To calculate the data dimensionality using a different value, click
“Cancel” in the plot window, enter a new value in the “Data
Dimensionality” text box and click “Calculate Dimensionality.”
12. Click “OK” in the plot window, then click “Next ->” in the wizard.
The Derive or Select Endmember panels appear.
13. Select from the following options for selecting endmembers to be used in the
classification and unmixing of the image:
• To derive endmembers from the input image, see “Deriving Endmembers
from the Input Image”.
• To manually select endmembers from another source, such as a spectral
library or an ROI, click the arrow button and select “No.” Click “Next ->”
to display the User Supplied Endmember screen, then refer to “Manually
Selecting Endmembers” on page 671 for instructions.
Deriving Endmembers from the Input Image
1. In the Derive or Select Endmember panels, select “Yes” and click “Next ->.”
The Pixel Purity Index panels appear.
2. Refer to the wizard text for information and instructions.
• To change the number of iterations, the threshold value, or your system
memory usage, enter or change the values in the corresponding text boxes.
3. Click the “Next ->” button.
The Calculating Pixel Purity Index panels appear and progress windows
display the status of the operation.
4. Refer to the wizard text for information about how the Pixel Purity Index
calculation works.
The Pixel Purity Index plot is displayed and the PPI Results screen appears.
5. Refer to the on-screen information and click “Next ->”.
The n-D Visualizer is displayed and the n-D Visualizer panels appear in the
wizard.
6. Refer to the wizard text for information and instructions for retrieving
endmembers from the n-D Visualizer.
• To plot endmembers once they are loaded into the wizard, click “Plot
Endmembers.”
Note
For further details about the n-D Visualizer, see “The n-Dimensional Visualizer” on
page 636.
• To load the SAM classification image into a display, click the “Load SAM
Class Result” button.
4. Follow the wizard instructions for examining SAM rule images and MTMF
results.
Tip
To load a rule image into a display, double-click on the rule image name in the list.
Spectral Analyst
Use ENVI’s Spectral AnalystTM to help identify materials based on their spectral
characteristics. The Spectral Analyst uses ENVI techniques, such as binary encoding,
Spectral Angle Mapper, and Spectral Feature Fitting to rank the match of an
unknown spectrum to the materials in a spectral library (see “Using Binary
Encoding” on page 649, “Spectral Angle Mapper Classification” on page 649, and
“Using Spectral Feature Fitting” on page 661 for method descriptions). You can also
define your own spectral similarity techniques and add them to the Spectral Analyst
(see Spectral Analyst Functions in the ENVI Programmer’s Guide). The output of the
Spectral Analyst is a list of the materials in the input spectral library ranked in order
of best to worst match. An overall similarity “score,” and individual 0 to 1 scores for
each method are reported. For more information, see “Tips for Successful Use of the
Spectral Analyst” on page 676.
Warning
This function does not identify spectra, it just recommends likely candidates for
identification. The results may change when the similarity methods used or weights
are changed. It is still up to you to make the actual identification.
4. Edit the “Min” and “Max” factors for each method if desired.
Use the “Min” and “Max” factors to indicate which values are considered a
perfect match by scaling them to 0 to 1 (or 1 to 0) scores.
• For the Spectral Angle Mapper (SAM) method, enter the min and max
values in radians. (The similarity to the library spectra are measured as an
angle in radians.)
• For the Spectral Feature Fitting (SFF) method, enter the min and max
values in RMS error units. (The similarity is measured using the RMS fit
error.)
A SAM or SFF result less than or equal to the min value indicates a perfect
match and gets a score of 1. A SAM or SFF result greater than or equal to
the max value gets a score of 0.
• For the binary encoding method, enter the min and max values as a
percentage of bands correctly matched (0-1).
A binary encoding result less than or equal to the min value gets a score of
0 and a result greater than or equal to the max value a gets a score of 1.
See “Spectral Angle Mapper Classification” on page 649, “Using Spectral
Feature Fitting” on page 661, and “Using Binary Encoding” on page 649 for
method descriptions.
5. In the Edit Identify Methods Weighting dialog, click “OK.”
The Spectral Analyst window appears. Use the Spectral Analyst window to
open a new spectral library, edit the weights and min and max values, input x
and y scale factors, and get input spectra from a Z-profile plot (see the
following Spectral Analyst Options section) When a spectrum is displayed, the
Spectral Analyst works over the range displayed in the plot being analyzed.
6. In the Spectral Analyst window, click “Apply” to load a spectrum.
• If one spectral plot is open, that spectrum is automatically entered into the
Spectral Analyst.
• If more than one spectrum is plotted, select the desired spectrum name.
• Spectra can also be entered directly from a Z-profile window.
The results of the similarity measures are listed. ENVI resamples the spectral library
to match the spectral resolution of the input spectrum.
Methods
Determine whether materials have absorption features. If they do, Spectral Feature
Fitting is probably the best method. Otherwise, Spectral Angle Mapper and/or Binary
Encoding will give better results.
Context
Finally, examine the spectral ranking in the context of the image setting and known
information. If a suggested identification seems invalid with respect to the known
information, it is probably not the correct identification.
Spectral Analyst Caution
This tool is not foolproof. It is meant to be used as a starting point to put you on the
right track towards identifying the materials in an image scene. Used properly and
with a good spectral library, it can provide excellent suggestions for identification.
Used blindly, it can produce totally erroneous results.
Spectral Math
Use Spectral Math TM to apply mathematical expressions or IDL procedures to spectra
(and also to selected multiband images). The spectra can be either from a multiband
image (i.e., a Z profile), a spectral library, or an ASCII file (see “Extracting Z
Profiles” on page 338, “Opening Spectral Libraries” on page 619, and “Importing
Spectra from Spectral Libraries” on page 497). If one or more images are also open
and the number of bands matches the number of channels in one of the displayed
spectra, those images will also be available for processing. Spectral math can be used
to apply mathematical expressions to all of the bands of multiband images provided
that the number of bands and number of spectral channels match.
Note
To apply Spectral Math, at least one spectrum must be open and displayed in a plot
window and each spectrum to be processed must be displayed.
Note
When using mathematical expressions in Spectral Math, the operations will be
performed in the data type (byte, integer, floating point, etc.) of the input data. Use
the data type conversion functions listed in Table 9-1 to explicitly set each input
band to the desired data type.
Table 9-1: Functions and Operators (shown in parenthesis) that can be used
in Spectral Math.
output file using the standard plot functions (see “Using Interactive Plot Functions”
on page 343).
Figure 9-19: The Variable/Spectra Pairings Dialog. The image on the left shows
variables in their unassigned states. The image on the right shows the variables
after they have been assigned to spectra.
Note
Mapping Variables to Input Files can be used to perform mathematical operations
simultaneously on all bands of an image.
The following simple examples demonstrate the creation and use of custom Spectral
Math functions (see Band Math Basics in the ENVI Programmer’s Guide for more
information).
To call this function from the “Enter an expression:” box, use the syntax:
user_sm1(s1,s2)
To call this function from the “Enter an expression:” box, use the syntax:
user_sm2(s1,s2,s3,s4,s5,s6)
EFFORT Polishing
Use Effort Polishing to execute Empirical Flat Field Optimal Reflectance
TransformationTM (EFFORTTM) in order to determine and apply mild adjustments
to ATREM apparent reflectance data so the spectra appear more like spectra of
real materials.
Consistent “noise” or error features may appear in hyperspectral apparent
reflectance data because of the limited accuracy of the standards, measurements,
and models that were used and the limited accuracy of calibrations performed
along the data signal processing chain. This cumulative error may be several
percent in each spectral band, leading to apparent reflectance data with absolute
accuracies far less than the actual precision of the original data.
EFFORT searches for a mild linear correction—bootstrapped from the data
themselves—that “polishes” out this error and attempts to improve the accuracy
of the apparent reflectance data. The EFFORT correction applies statistically mild
adjustments to every band (gains near one and offsets near zero) that make a
visual improvement in the apparent reflectance spectra. This removal of the
cumulative errors of calibration and atmospheric correction allows improved
comparison of EFFORT corrected spectra to library spectra. For more
information, see the following references:
Huntington, J. F. and Boardman, J. W., 1995, Semi-quantitative Mineralogical
and geological mapping with 1995 AVIRIS data, Proc. Spectral Sensing Research
‘95, ISSSR, Published by the AGPS, 26 nov - 1 Dec, 1995, Melbourne, Australia.
Boardman, J. W., 1997, Mineralogic and geochemical mapping at Virginia City,
Nevada using 1995 AVIRIS data, in Proceedings of the Twelfth Thematic
Conference on Geological Remote Sensing, Environmental Research Institute of
Michigan, Denver, CO, pp. 21-28.
Boardman, J. W., 1998, Post-ATREM polishing of AVIRIS apparent reflectance
data using EFFORT: a lesson in accuracy versus precision, in Summaries of the
Seventh JPL Airborne Earth Science Workshop, Vol. 1, p. 53.
The EFFORT process is similar to the Empirical Line method of data calibration
which matches data spectra to field measured spectra. EFFORT, however, uses no
ground truth data, and the EFFORT-calculated gains and offsets are applied to
ATREM or other atmospherically corrected apparent reflectance data. EFFORT uses
the data themselves to generate “pseudo field” spectra by fitting each observed
spectrum with a parametric model of Legendre polynomials optionally augmented
with real spectra. Gains and offsets for every band are calculated by comparing the
modeled spectra to the data spectra, for pixels that are well fit. A number of spectra
are used spanning the entire albedo range to give good leverage for the linear
regression process, and the data values versus modeled values are fit with a line for
every band. The slope and offset of this line are used to correct the apparent
reflectance data for the error features. Gain-only corrections can be applied to fix the
model-to-data offset to zero.
One or more reality boost spectra (spectra from spectral libraries or field spectra)
can be used to aid in the modeling. Using a few spectra that you know are
characteristic of your area as reality boost spectra can produce better-fitting
modeled spectra. The modeled spectra are created by a linear combination of the
Legendre and reality boost spectra. Therefore, reality boost spectra that contain
sharp features, such as the vegetation red edge, when used to augment the
Legrendre basis set, can produce a better model, giving better EFFORT correction
factors and/or offsets.
EFFORT works on one or more wavelength segments that you enter.
Wavelengths ranges that contain only noise (e.g., the 1.4 µm and 1.9 µm water
vapor absorption bands) should not be used in the calculation.
Typically three segments are defined around the two large water vapor bands;
bands before the 1.4 µm water vapor band, bands between the 1.4 and 1.9 µm
water vapor bands, and bands past the 1.9 µm water vapor band. Each segment
must start and end with a valid band. Bands within a segment that contain large,
known errors but that are critical to further analysis can be set as invalid and not
used in the initial spectral modeling.
Invalid bands may include overlapping spectral bands, bands with ringing around
the 0.94 and 1.14 µm water vapor bands, and O2 and CO2 under-corrected or
over-corrected bands. These invalid bands are not used in the modeling but will be
corrected on output. The order of the Legendre polynomial that is used to model
the spectra is set by you through trial and error (though the default value provided
should work in most cases). Each segment can be modeled with a different order
polynomial.
Tip
Select a polynomial order that will fit the real data features without fitting the
error features. Before running EFFORT, use spectral plots of the radiance data
to select the wavelength segments and invalid bands to input into the EFFORT
dialog.
2. Enter the number of bins to divide the albedo range into and select spectra
from.
The number of spectra used in each albedo bin is the total number of points
divided by the number of albedo bins. This insures that spectra with a range
of albedo are used in the modeling.
3. Use the arrow toggle button to calculate gain and offset values or gain
values only.
• To correct your data for gain values only, select “Gain.”
These include errors in the radiometric calibration, atmospheric
transmittance model, and solar irradiance model.
• To correct your data for both gain error and offset error, which include
errors in the dark current and path radiance model, select “Gain and
Offset.”
• To save the gain and offset values to an ASCII file, enter an output
filename in the appropriate dialog.
4. Click on the arrow toggle button to apply the calculated gain and offset
values to the input data.
• If you select “No,” the gain and offset values will appear in a plot
window and no other output will be generated.
• If you select “Yes,” enter an output filename.
The gain and offset values will appear in a plot window and an
EFFORT-corrected apparent reflectance output file will be created.
• To write the EFFORT output over the input file, use the “In Place?”
arrow toggle button to select “Yes.”
Warning
The In Place option will overwrite the input file and can not be interrupted without
corrupting the original data file.
n-D Visualizer
Boardman, J. W., 1993, Automated spectral unmixing of AVIRIS data using
convex geometry concepts: in Summaries, Fourth JPL Airborne Geoscience
Workshop, JPL Publication 93-26, v. 1, pp. 11 - 14.
Boardman J. W., and Kruse, F. A., 1994, Automated spectral analysis: A geologic
example using AVIRIS data, north Grapevine Mountains, Nevada: in
Proceedings, Tenth Thematic Conference on Geologic Remote Sensing,
Environmental Research Institute of Michigan, Ann Arbor, MI, pp. I-407 - I-418.
Binary Encoding
Goetz, A. F. H., Vane, G., Solomon, J. E., and Rock, B. N., 1985, Imaging
spectrometry for earth remote sensing: Science, v. 228, pp. 1147 - 1153.
Mazer, A. S., Martin, M., Lee, M., and Solomon, J. E. (1988). “Image processing
software for imaging spectrometry data analysis.” Remote Sensing of
Environment 24(1): pp. 201 - 210.
Spectral Angle Mapper (SAM)
Center for the Study of Earth from Space (CSES), 1992, SIPS User’s Guide,
Spectral Image Processing System, Version 1.2, Center for the Study of Earth
from Space, Boulder, CO, p. 88.
Kruse, F. A., Lefkoff, A. B., Boardman, J. B., Heidebrecht, K. B., Shapiro, A. T.,
Barloon, P. J., and Goetz, A. F. H., 1993, The Spectral Image Processing System
(SIPS) - Interactive Visualization and Analysis of Imaging Spectrometer Data:
Remote Sensing of Environment, Special issue on AVIRIS, May-June 1993, v.
44, pp. 145 - 163.
Continuum Removal
Clark, R. N., and Roush, T. L., 1984, Reflectance spectroscopy: Quantitative
analysis techniques for remote sensing applications: Journal of Geophysical
Research, v. 89, no. B7, pp. 6329-6340.
Clark, R. N., King, T. V. V., and Gorelick, N. S., 1987, Automatic continuum
analysis of reflectance spectra: in Proceedings, Third AIS workshop, 2-4 June,
1987, JPL Publication 87-30, Jet Propulsion Laboratory, Pasadena, California, pp.
138-142.
Green, A. A., and Craig, M. D., 1985, Analysis of aircraft spectrometer data with
logarithmic residuals: in Proceedings, AIS workshop, 8-10 April, 1985, JPL
Publication 85-41, Jet Propulsion Laboratory, Pasadena, California, pp. 111-119.
Kruse, F. A., Raines, G. L., and Watson, K., 1985, Analytical techniques for
extracting geologic information from multichannel airborne spectroradiometer
and airborne imaging spectrometer data: in Proceedings, International
Symposium on Remote Sensing of Environment, Thematic Conference on
Remote Sensing for Exploration Geology, 4th, Environmental Research Institute
of Michigan, Ann Arbor, pp. 309-324.
Kruse, F. A., Lefkoff, A. B., and Dietz, J. B., 1993, Expert System-Based Mineral
Mapping in northern Death Valley, California/Nevada using the Airborne
Visible/Infrared Imaging Spectrometer (AVIRIS): Remote Sensing of
Environment, Special issue on AVIRIS, May-June 1993, v. 44, pp. 309 - 336.
Kruse, F. A., and Lefkoff, A. B., 1993, Knowledge-based geologic mapping with
imaging spectrometers: Remote Sensing Reviews, Special Issue on NASA
Innovative Research Program (IRP) results, v. 8, pp. 3 - 28.
Spectral Feature Fitting
Clark, R. N., Gallagher, A. J., and Swayze, G. A., 1990, Material absorption band
depth mapping of imaging spectrometer data using the complete band shape least-
squares algorithm simultaneously fit to multiple spectral features from multiple
materials: in Proceedings of the Third Airborne Visible/Infrared Imaging
Spectrometer 9AVIRIS) Workshop, JPL Publication 90-54, pp. 176 - 186.
Clark, R. N., Swayze, G. A., Gallagher, A., Gorelick, N., and Kruse, F. A., 1991,
Mapping with imaging spectrometer data using the complete band shape least-
squares algorithm simultaneously fit to multiple spectral features from multiple
materials: in Proceedings, 3rd Airborne Visible/Infrared Imaging Spectrometer
(AVIRIS) workshop, JPL Publication 91-28, pp. 2-3.
Clark, R. N., Swayze, G. A., and Gallagher, A., 1992, Mapping the mineralogy
and lithology of Canyonlands, Utah with imaging spectrometer data and the
multiple spectral feature mapping algorithm: in Summaries of the Third Annual
JPL Airborne Geoscience Workshop, JPL Publication 92-14, v 1, pp. 11-13.
Clark, R. N., and Swayze, G. A., 1995, Mapping minerals, amorphous materials,
environmental materials, vegetation, water, ice, and snow, and other materials:
The USGS Tricorder Algorithm: in Summaries of the Fifth Annual JPL Airborne
Earth Science Workshop, JPL Publication 95-1, pp. 39 - 40.
Crowley, J. K., and Clark, R. N., 1992, AVIRIS study of Death Valley evaporite
deposits using least-squares band-fitting methods: in Summaries of the Third
Annual JPL Airborne Geoscience Workshop, JPL Publication 92-14, v 1, pp. 29-
31.
Swayze, G. A., and Clark, R. N., 1995, Spectral identification of minerals using
imaging spectrometry data: evaluating the effects of signal to noise and spectral
resolution using the Tricorder Algorithm: in Summaries of the Fifth Annual JPL
Airborne Earth Science Workshop, JPL Publication 95-1, pp. 157 - 158.
Registration
Use Registration to reference images to geographic coordinates and/or correct them
to match base image geometry. Select ground control points (GCPs) interactively
from display windows and/or vector windows. Warping is performed using
polynomial functions, Delaunay triangulation, or rotation, scaling, and translation
(RST). Resampling methods include nearest neighbor, bilinear, and cubic
convolution. Comparison of base and warped images using ENVI’s multiple
Dynamic Overlay capabilities allows quick assessment of registration accuracy. For
step-by-step image registration instructions, see the ENVI Tutorial Image
Georeferencing and Registration.
1. Open the base image and warp image files and display them in two windows
using the Available Bands list (see “Opening Image Files” on page 65 and
“The Available Bands List” on page 176).
2. After the two images are displayed, choose Map > Registration > Select
GCPs:Image to Image.
The Image to Image Registration dialog appears.
3. In the “Base Image” list, click on the base (reference) display.
4. In the “Warp Image” list click on the display containing the image to be
warped.
5. Click “OK.”
The Ground Control Points Selection dialog (Figure 10-3) appears.
Tip
See the ENVI Tutorial Image Georeferencing and Registration for step-by-step
descriptions of image registration.
3. Once the desired pixel is selected in both images, click “Add Point” in the
Ground Control Points Selection dialog to add the selected GCPs to the list of
selected X, Y (sample, line) pairs.
• To view the list of GCPs, click “Show List.”
The Image to Image GCP List appears with the GCPs listed in a table. For
a description of the GCP List, see “Using the GCP List” on page 705.
When the GCPs have been added to the list, a marker is placed in the image
displays of both the base and warp images. The GCP marker in the image is the
identifying number of the GCP displayed next to an encircled cross-hair.
The marker indicates the selected pixel (or subpixel location); the center of the
marker (located under the cross-hair) indicates the actual GCP location.
4. Add additional GCPs following the same procedure.
When four or more GCPs have been selected, the predicted X, Y coordinates
for the selected warp, the X and Y error, and the RMS error are listed in the
GCP List table.
Tip
For the best registration, attempt to minimize the RMS error by refining the
positions of the pixels with the largest errors or by removing them. Using more
points can also give lower errors (see “Minimizing RMS Error” on page 705).
Figure 10-3: The Ground Control Points Selection Dialog (top). The GCP List,
(bottom) which you can display or hide from within the Selection dialog.
Ignoring GCPs
• To have GCPs selectively ignored during registration, click on the point to be
ignored and click the “On/Off” button.
The RMS error and the spatial transformation are recalculated without using
the selected point(s). The “+” next the GCP number changes into a “-” in the
GCP List and the color of the GCP marker changes.
• To turn the GCP “on” again, click on the point in the list and click the
“On/Off” button again.
Using the GCP List
Use the GCP List to edit and update positions, turn points on and off, delete selected
points, and predict point locations (see Figure 10-3).
Hiding/Showing the GCP List
• To display the GCP list, click “Show List” in the Ground Control Points
Selection dialog.
• To hide the GCP list, click “Hide List” in the Ground Control Points Selection
dialog or select File > Cancel in the GCP List window.
Positioning the Zoom Window
• To center the Zoom window over any of the selected GCPs, click on the
desired GCP in the list and click “Goto,” or click on the GCP number in the
GCP List.
The marker outlining the selected GCP is positioned at the center of the Zoom
window for both the base and warp images.
Editing GCP Locations
You can edit the location of a GCP by changing the X and/or Y values in the GCP
List, or by interactively selecting new locations in the Zoom windows.
To change a GCP from the GCP List:
1. In the GCP List, double-click on the value to be edited.
2. Enter the new value and press “Return” or enter a new value and click
“Update.”
The changes are reflected in the GCP list and in the base and warp images.
Note
If several GCPs have already been selected, a significant delay may occur while the
GCPs are redrawn and the error is recalculated.
GCP Options
Use the Options menu in the Ground Control Points Selection dialog to control the
ground control points’ labels, colors and ordering, to reverse the base and warp
images, and to set other preferences.
Reversing Base/Warp Images
Use this option to warp the base image to match the warp image.
• To reverse the positions of the base and warp GCPs, select Options > Reverse
Base/Warp.
Warping Options
Use the Options menu in the Ground Control Points Selection dialog to warp from
the currently displayed band or to warp from a file. You can also select image-to-map
type warping if your base image is georeferenced. This allows you to change the
output pixel size and projection type of the warped image.
• To use the GCPs to perform a standard registration, select either Options >
Warp Displayed Band or Warp File.
• To select image-to-map type warping, if the base image is georeferenced,
select Options > Warp Displayed Band (as Image to Map) or Warp File (as
Image to Map).
The Registration Parameters dialog appears. The details of the various warp options
available in ENVI are discussed in “Warping and Resampling” on page 714.
Managing GCPs
Use the File menu in the Ground Control Points Selection dialog to save and restore
ground control points files.
Saving GCPs to ASCII Files
1. In the Ground Control Points Selection dialog or in the GCP List, select File >
Save GCPs to ASCII.
2. Enter an output filename with the .pts extension or use the “Choose” button
to select an output filename.
3. Click “OK” (see “GCP File Format (.pts)” on page 896 for information on the
format).
x′ = a ( x, y ) = å åP i, j x
j i
y
i = 0j = 0
N N
y′ = b ( x, y ) = å åQ i, j x
jyi
i = 0j = 0
Where x′and y′ are the locations in the base image, x and y are the locations in the
warp image, N is the polynomial degree, and P and Q are the polynomial coefficients.
The P and Q polynomial coefficients matrices are written to the file by rows, one
element per line. For example, a 2 x 2 matrix of P and Q would be written in the
following format:
P[0, 0] Q[0, 0]
P[0, 1] Q[0, 1]
P[1, 0] Q[1, 0]
P[1, 1] Q[1, 1]
Restoring Saved GCPs
1. Select File > Restore GCPs from ASCII.
2. Enter the desired GCP .pts filename.
Closing the Dialog
• To exit the Ground Control Points Selection dialog, select File > Cancel.
Note
If the current points have not been saved to a file, a prompt appears.
3. Select common reference features in both the map and the image (for example
a road intersection seen in both image and map) and select from the following
options:
• To automatically enter map coordinates from vector data, see “Entering
Map GCPs from Vector Windows” on page 714.
• To automatically enter map coordinates from GPS locations, see “Using
GPS-Link” on page 770.
• To enter the map coordinates from a paper map, enter the easting and
northing (or lat/long) of the selected GCPs into “E” and “N” text boxes,
respectively.
• To enter the map GCP location from a paper map in latitude and
longitude, click the arrow toggle button next to the map projection
name (“UTM” in Figure 10-5) and enter the values into the “Lat” and
“Long” text boxes.
Use negative (-) longitude for the western hemisphere and negative (-)
latitude for the southern hemisphere.
• To change the latitude and longitude values between degrees, minutes,
seconds, and decimal degrees, click on the “DMS< - >DD” button.
• To return to map projection coordinates, click the arrow toggle button.
The corresponding map projection coordinates are calculated
automatically.
4. Once the desired pixel is selected in the image and the map coordinates have
been entered, click “Add Point” in the Ground Control Points Selection dialog
to add the point to the list of GCPs.
• To view GCP List, click “Show List.”
The Image to Map GCP List appears with the GCPs listed in a table. For a
description of the GCP List, see “Using the GCP List” on page 705.
When a GCP is added, a marker is placed in the image. The GCP marker in the
image is the identifying number of the GCP displayed next to an encircled
cross-hair. The marker indicates the selected pixel (or subpixel location); the
center of the marker (located under the cross-hair) indicates the actual GCP
location.
Note
When GCPs are selected from a vector window, a marker is also placed in the
vector window. The marker is the identifying number of the GCP displayed with a
“+.”
Figure 10-5: The Image to Map Ground Control Points Selection dialog.
The number of GCPs selected is displayed in the Ground Control Points Selection
dialog. Once a sufficient number of GCPs have been selected to conduct a 1st degree
polynomial warp, the total RMS error is also displayed.
Tip
For the best registration, attempt to minimize the RMS error by refining the
positions of the pixels with the largest errors or by removing them. Using more
points can also give lower errors (see “Minimizing RMS Error” on page 705).
For details about editing, predicting, and positioning GCPs, see “GCP Options” on
page 706. For details about managing GCPs, see “Managing GCPs” on page 708.
Warping Options
• To use the GCPs to perform a standard registration, select either Options >
Warp Displayed Band or Warp File in the Ground control points selection
dialog.
The Registration Parameters dialog appears. For details, see “Warping and
Resampling”.
warping available is 1 st to nth degree. The degree available is dependent upon the
number of GCPs selected where #GCPs > (degree + 1)2. Delaunay triangulation
warping fits triangles to the irregularly spaced GCPs and interpolates values to the
output grid.
The resampling methods available include nearest neighbor, bilinear, and cubic
convolution. Nearest neighbor resampling uses the nearest pixel without any
interpolation to create the warped image. Bilinear resampling does a linear
interpolation using four pixels to resample the warped image. Cubic convolution uses
16 pixels to approximate the sinc function using cubic polynomials to resample the
image. Note that cubic convolution resampling is significantly slower than the other
methods. For more information, see the following reference:
Richards, J. A., 1994, Remote Sensing Digital Image Analysis, Springer-Verlag,
Berlin, p. 340.
1. Select the Ground Control Points (see “Image-to-Image Ground Control
Points” on page 702).
2. In the Ground Control Points Selection dialog, select Options > warping
method.
3. When the Registration Parameters dialog (Figure 10-6) appears, select the
warping method from the “Warp Method” button menu.
The available warping methods are RST (rotation, scaling, and translation),
Polynomial, and Triangulation.
4. Select from the following method-specific options:
• For polynomial warping, enter the desired polynomial degree in the
“Degree” text box. The degree available is dependent on the number of
GCPs defined where #GCPs > (degree + 1)2.
• To select whether you want a one-pixel border of background color at the
edge of triangulation warp data, use the “Zero Edge” arrow toggle button
to select “Yes.”
By selecting this option, you will avoid a “smearing” effect which may
appear at the edges of warped images and which is often seen when using
ENVI’s data-specific georeferencing functions.
Figure 10-6: The Registration Parameters Dialog and the Image to Map
Registration dialog.
The output projection of the image was originally set when ground control points
were selected.
2. When the file selection dialog appears, enter the GCP file name or choose the
appropriate GCP input file from the list.
3. When the Input Warp Image dialog appears, select the image to be warped and
any spatial and spectral subsetting using standard ENVI procedures.
4. Click “OK.”
5. When the Input Base Image dialog appears, select the input base image.
6. Click “OK.”
7. When the Registration Parameters dialog appears, follow instruction as
described above (see “Warping and Resampling” on page 714).
6. Click “OK.”
In this case, the geographic map coordinates act as the base rather than image
pixel locations.
7. When the Registration Parameters dialog appears, follow instruction as
described above (see “Warping and Resampling” on page 714).
Orthorectification
Use Orthorectification to rectify aerial photographs and SPOT data using a digital
elevation model (DEM). The orthorectification uses geometric projections to produce
geometrically correct images for mapping and measurement. For more details, see
the following reference:
Wolf, R., 1974. Elements of Photogrammetry (2nd ed.), McGraw-Hill Inc., New
York.
The tie points are listed in the Ortho: Interior Orientation GCP List.
• To display the Ortho: Interior Orientation GCP List, click “Show List” in
the Ortho: Build Interior Orientation dialog.
The GCP List appears with the GCPs listed in a table with an identifying
number, fiducial location, pixel location, and error shown. The total RMS error
is shown in the “RMS Error” text box for each point. The errors are calculated
based on a first order polynomial fit to the points and shown to indicate
whether the points were entered correctly (if the error is large you may have a
typo in a fiducial location). For details, of the GCP List, see “Using the GCP
List” on page 705.
6. Continue selecting fiducial mark locations until three or more have been
entered.
7. Select from the following options:
• To go to, edit, delete, update, and turn on and off points, see “Using the
GCP List” on page 705.
• To change the order and color of the labels and to turn point labels on and
off, see “GCP Options” on page 706.
8. Select Options > Build Interior Orientation from the Ortho: Build Interior
Orientation dialog.
9. Enter the camera focal length in mm (obtain this information from the camera
report) and enter an output filename with an .ort extension for consistency.
The .ort file contains the fiducial tie point locations, affine transformation
coefficients for both the camera coordinates to image pixels and image pixels
to camera coordinates.
10. Save the points by selecting an option from the File menu as described in
“Managing GCPs” on page 708.
11. Close the Ortho: Build Interior Orientation dialog by selecting File > Cancel.
Building Exterior Orientations
Use Build Air Photo Exterior Orientation to relate points in the aerial photograph to
their known map coordinates and elevations. The exterior orientation is built by
selecting ground control points and entering the corresponding map coordinates
using methods similar to image-to-map registration.
Note
The aerial photograph must be displayed in an image window for selection of the
ground control point locations.
The output image dimensions are automatically set to the size of the bounding
rectangle that contains the warped input image. Therefore, the output warp
image size may not be the same size as the DEM image. The output size
coordinates are determined in the exterior orientation projection coordinates.
9. Change the map coordinate or latitude/longitude information for the upper left
coordinate, pixel size, and image size by clicking “Change Output Parameters”
and entering the desired values.
Note
Since only nearest neighbor resampling is currently available, it is recommended
that you set the pixel size to the resolution at which the photo was scanned.
Click the “Change Projection” button to change the projection of the upper left
coordinate only. Use Build Exterior Orientation to set the output projection of the
image.
SPOT Orthorectification
SPOT orthorectification uses satellite ephemeris information from the SPOT leader
file to generate an initial orbit and view geometry model. SPOT 1A and 1B data can
be orthorectified. Ground control points (GCPs) are used to optimize the orbital
model by performing a non-linear inversion. The satellite position and set of
collinearity equations for every line in the SPOT data are calculated and stored in a
.sot file.
The orthorectification is done in two steps. In the first step, you build the exterior
orientation using ground control points. In the second step, you execute the
orthorectification using the orbit model and a DEM file to correct the SPOT image
pixel by pixel. For details, see the following reference:
Westin, Torbjorn, 1990. Precision rectification of SPOT imagery, Photogrammetric
Engineering & Remote Sensing, Vol. 56, No. 2, pp. 247-253.
Building Exterior Orientations
Use Build SPOT Exterior Orientation to optimize the satellite orbit model by relating
points in the SPOT image to their known map coordinates and elevations. The
orthorectification is built by selecting ground control points and entering the
corresponding map coordinates using methods similar to image-to-map registration.
Note
The SPOT image must be displayed in an image window for selection of the ground
control point locations.
The Ortho: Build Exterior Orientation dialog appears. This dialog is similar to
the image-to-map registration Ground Control Points Selection dialog.
• To resize the dialog, click on any corner with the left mouse button and
drag to the desired size and/or shape.
5. Select a ground control point (GCP) by centering the zoom window cross-hair
over a pixel on the SPOT image and entering the corresponding map
coordinates in the appropriate text boxes.
6. In the “Elev” text box, enter an elevation for the selected pixel.
7. Click on “Add Point” to add the location to the list of GCPs.
8. Continue selecting ground control points until three or more are entered.
Note
It is recommended that you use as many GCPs as possible (dozens) spread over the
image to stabilize the satellite orbit inversion. Although the orthorectification can
be run with only 3 GCPs, it may produce instability in the satellite orbit inversion.
The GCPs are listed in the dialog with an ID#, map location, pixel location,
and error shown. The total RMS error is shown in the “RMS Error” text box.
The errors are calculated based on a first order polynomial fit to the points.
9. Select from the following options:
• To go to, edit, delete, and turn on and off points, use the buttons at the
bottom of the dialog as described in “Using the GCP List” on page 705.
• To change the order and color of the labels and to turn point labels on and
off, use the pulldown menus as described in “GCP Options” on page 706.
10. Select Options > Build Exterior Orientation from the Ortho: Build Exterior
Orientation dialog.
11. Select the SPOT leader filename, typically lead_xx.dat where xx is the
scene number.
12. Enter an output filename with a .sot extension for consistency.
The .sot file is in binary format and contains the satellite location and collinearity
equations for each line in the SPOT image. This file is needed in the next step.
9. Set the “Background Value” (the DN value used to fill areas where no image
data appears in the warped image) by entering the DN value in the
“Background Value” text box.
The output image dimensions are automatically set to the size of the bounding
rectangle that contains the warped input image. Therefore, the output warp
image size may not be the same size as the DEM image. The output size
coordinates are determined in the exterior orientation projection coordinates.
10. Change the map coordinate or latitude/longitude information for the upper left
coordinate, pixel size, and image size by clicking “Change Output Parameters”
and entering the desired values.
Note
Since only nearest neighbor resampling is currently available, it is recommended
that the pixel size is set to its native format resolution (i.e., 10 or 20 meters for
SPOT).
Use the “Change Projection” button to change the projection of the upper left
coordinate only. Use Build Exterior Orientation to set the output projection of the
image.
Image Mosaicking
Use Mosaic Images to overlay two or more images that have overlapping areas
(typically georeferenced) or to put together a variety of non-overlapping images
and/or plots for presentation output (typically pixel-based). Individual bands, entire
files, and multi-resolution georeferenced images can be mosaicked. You can use your
mouse or pixel- or map-based coordinates to place images in mosaics and you can
apply a feathering technique to blend image boundaries. You can save the mosaicked
images as a virtual mosaic to avoid having to save an additional copy of the data to a
disk file. Mosaic templates can also be saved and restored for other input files.
• To select individual bands, click the “Select By” arrow toggle button in the
Mosaic Input File dialog to select “Band.”
• If you select Import file with feathering, a Mosaic Entry Input Parameters
dialog appears with feathering options. For instructions, see “Feathering”
on page 742.
Figure 10-10: The Image Mosaicking Dialog for a pixel-based image mosaic.
Once you select the first input file for the mosaic, a colored graphic
representing the input image size is drawn in the draw widget on the right side
of the dialog.
3. Import other files as needed.
The image name, the color of graphic, and the coordinates for the upper left corner of
the image are listed in the center of the dialog.
Positioning Images
The coordinates for the upper left corner of the input image are listed in parentheses
next to the image name in the center of the Pixel Based Image Mosaicking dialog.
Images with “x start” and “y start” values in their headers are automatically placed in
the mosaic with the defined offset. Select from the following options:
• To initially place each new item in the mosaic at (1, 1,) select Options > Do
Not Use Image Offset.
• To enable editing of the position coordinates, click on any listed image and
enter the desired upper left coordinates in the fields labeled “X0” and “Y0.”
The number of the currently selected image is shown in the text box labeled
“#”. Any changes to the “X0”, and “Y0” fields will be applied to this item.
• Images can also be positioned within the mosaic by clicking and holding the
left mouse button on the appropriate image outline graphic box and dragging
to the desired location.
• To designate a fixed spacing see “Setting Snap Values” in the next section.
A “Snap” of 1 pixel causes images to be placed without snapping.
Pixel-Based Mosaicking Options
Use the Options menu to select image placement options, edit mosaic parameters,
and delete and clear images.
Setting Snap Values
1. Select Options > Set Snap Value.
2. In the Mosaic Window Snap Value dialog, click the arrow increment buttons
to select a value.
3. Click “OK.”
Note
The snap value refers to pixels in the mosaic window, not actual pixels. Each pixel
in the mosaic window represents many pixels in the output mosaic. If the mosaic
window is 256 x 256 pixels, and the output mosaic area is 1000 x 1000 pixels, a
snap value of 5 would produce a fixed spacing of 19.5312 pixels, rounded to 20, in
the output mosaic.
Centering Images
• To center all of the currently listed images (as a group) in the output mosaic,
select Options > Center Entries or double-click outside the graphic outlines
with the left mouse button.
Each image is not centered individually but the layout within the open mosaic
area is centered.
Editing Mosaic Parameters
1. Click on an image name and select Options > Edit Entry.
The Mosaic Entry Input Parameters dialog appears.
2. Select from the following options:
• To make pixels with a certain background value transparent so that the
underlying image is visible, enter the pixel value in the “Background Data
Value to Ignore” text box. (Use for mosaicking of images with constant
DN value borders.)
• To change the offset for the selected image, enter the desired values in the
“Image Offset X0/Y0” text boxes.
• To control feathering parameters (see “Feathering” on page 742).
Replacing Images
To replace the current image with a new image of the same size:
1. In the Pixel Based Image Mosaicking dialog, click on an image name and
select Options > Replace Entry.
2. Select the new image filename and click “OK.”
The new image is placed in the same position as the original image.
Setting Mosaic Sizes
To set the size of the mosaic based on pixels in the border of the entries:
1. Select Options > Reset Mosaic Size.
2. In the Mosaic Reset Size dialog, click the arrow increment buttons to select a
value for the reset border.
The border value is the number of pixels that will be added around the edges of
the mosaic.
3. Click “OK.”
Locking Groups
• To group all of your entries and lock them together, select Options > Lock All
Entries: On.
Locked entries can be moved together as a unit.
• To ungroup and unlock entries, select Options > Lock All Entries: Off.
Tip
To toggle the lock feature on and off, click anywhere within the graphic area with
the right mouse button.
Deleting Images
• To delete that image from the mosaic, click on an image name in the list and
select Options > Delete Entry.
• To remove all the images from the mosaic dialog, select Options > Clear All
Entries.
Setting Image Placement Preferences
Images with “x start” and “y start” values in their headers are automatically
placed in the mosaic with the defined offset.
• To initially place the images at the top right corner, select Options > Do
Not Use Image Offset.
• To place images using the header offsets, select Options > Use Image
Offset.
Creating Virtual Mosaics
It is not necessary to save the mosaic to an output file unless feathering was used.
Instead, you can save the mosaic to a Virtual Mosaicä. ENVI uses a virtual mosaic
file (saved mosaic template) like an image file. When a virtual mosaic template file is
opened, ENVI opens the individual image files that make up the mosaic and puts
them together on-the-fly. ENVI cannot do feathering on-the-fly, however. The
mosaic template file can be displayed in ENVI and annotated, stretched, etc., like any
other image. Using a virtual mosaic prevents having multiple files containing the
same images and therefore saves disk space.
1. In the Pixel Based Image Mosaicking dialog, select File > Save Template.
2. In the Output Mosaic Template dialog, enter an output filename with the
extension .mos for consistency.
The template file is a virtual mosaic file in ASCII format. It contains the mosaic size,
file names, bands used, data dimensions, and mosaic information. The “Info” field
has the X and Y offsets, edge feathering distance, cutline feathering distance, and
data value to ignore.
The mosaic template file appears in the Available Bands List and can be used as input
for processing with other functions.
Note
The template file can be edited, using any text editor, to change the file or the bands
used in the mosaic.
Building Mosaics
Use Apply to build a mosaic after all of the images for the mosaic have been
positioned. Building the mosaic outputs the mosaic to a file.
Note
It is not necessary to build the mosaic to an output file unless feathering was
used. The mosaic can be saved as a virtual mosaic to save time and disk space
(see “Creating Virtual Mosaics” on page 735).
Figure 10-11: The Image Mosaicking Dialog for a georeferenced image mosaic.
Importing Images
Use the Import menu to select input files for the mosaic. The first image imported
into the mosaic must be a georeferenced image. The mosaic size will be set to the
georeferenced image size.
1. In the Georeferenced Image Mosaicking dialog, select Import > Import file
with feathering or Import file without feathering.
2. When the Mosaic Input File appears, select a file or files and perform any
spatial and spectral subsetting.
Note
Individual bands or entire files can be mosaicked.
• If you select Import file with feathering, a Mosaic Entry Input Parameters
dialog appears with feathering options. For instructions, see “Feathering”
on page 742.
Once you select the first input file for the mosaic, a colored graphic
representing the input image size is drawn in the draw widget on the right side
of the dialog and the mosaic size is set.
3. Import additional georeferenced images to the mosaic as needed.
For multi-resolution mosaicking, the output pixel size is entered on output and
ENVI automatically resamples the lower resolution images to match.
4. Import additional non-georeferenced images to the mosaic as needed.
When importing non-georeferenced images, the Mosaic Entry Input
Parameters dialog appears.
• Enter a background value to ignore, if needed, and an image offset in
pixels from the upper left corner.
Each image is listed in the center of the dialog with the color of the graphic box and
the feathering parameters.
Note
You cannot adjust the image positions with the graphic boxes like you can in pixel-
based mosaics.
Feathering
Use Feathering to blend the edges of overlapping areas in input images for pixel-
based and georeferenced mosaicking. The two types of feathering in ENVI are edge
feathering and cutline feathering.
Tip
To use feathering when mosaicking images, import the bottom image without
feathering. Import the overlapping images with edge or cutline feathering as
desired.
1. In the Image Mosaicking dialog, select Import > Import file with feathering or
Options > Edit Entry.
The Mosaic Entry Input Parameters dialog appears.
2. In the “Edge feathering distance (pixels)” text box, enter the distance over
which to blend the images.
Using Cutline Feathering
Use Cutline feathering to blend the boundary between two overlapping images based
on a user-defined cutline. A specified blending distance is used to blend the images
along the cutline (see Figure 10-13).
Note
Cutlines must be defined using the annotation tools prior to mosaicking. The
annotation file must contain a polyline defining the cutline that is drawn from
edge-to-edge and a symbol placed in the region of the image that will be cut off
(see “Annotating Images” on page 222).
The distance specified is used to create a linear ramp that averages the two images
across that distance from the cutline outwards. For example, if the specified distance
is 20 pixels, 100% of the top image is used in the blending at the cutline and 0% of
the bottom image is used to make the output image. At the specified distance (20
pixels) out from the cutline, 0% of the top image is used to make the output image
and 100% of the bottom image is used. 50% of each image is used to make the output
at 10 pixels out from the cutline.
1. In the Image Mosaicking dialog, select Import > Import file with feathering or
Options > Edit Entry.
2. When the Mosaic Entry Input Parameters dialog appears, click the “Ann File”
button and select an annotation file.
3. In the “Cutline feathering distance (pixels)” text box, specify the distance used
to blend the image boundaries.
negative value). A zero value signifies that no input pixel corresponds to the output
pixel.
1. Select Map > Georeference from Input Geometry > Build GLT.
2. When the Input X Geometry Band selection dialog appears, select the band
that contains the X geometry coordinates. Click “OK.”
3. When the Input Y Geometry Band selection dialog appears, select the band
that contains the Y geometry coordinates. Click “OK.”
The Geometry Projection Information dialog appears.
4. In the “Input Projection of Geometry Bands” list, click on the projection type.
5. In the “Output Projection for Georeferencing” list, click on the projection for
the georeferencing.
For instructions on selecting input and output projections, see “Selecting Map
Projection Types” on page 757.
6. Click “OK.”
A default output pixel size and rotation angle is calculated and it appears in the
Build Geometry Lookup File Parameters dialog.
The default output pixel size is calculated based on the map coordinates in
output space. The default output rotation angle is used to minimize the output
file size. If the rotation angle is set to 0 then north will be “up” in the output
image. If it is set to another angle, then north will be at an angle and will not be
“up” in the output image. The rotation angle is stored in the ENVI header and
is used when overlaying grids, so the grid lines will appear at an angle.
• To change the output pixel size, replace the value in the “Output Pixel
Size” text box.
• To change the output rotation angle, replace the value in the “Output
Rotation” text box.
Note
If you change a non-zero rotation angle to 0 so north is “up,” your resulting image
may contain a lot of background fill and may become very large.
The process runs in two parts and the output GLT filename appears in the Available
Bands List.
The default output pixel size is calculated based on the map coordinates in
output space. The default output rotation angle is used to minimize the output
file size. If the rotation angle is set to 0 then north will be “up” in the output
image. If it is set to another angle, then north will be at an angle and will not be
“up” in the output image. The rotation angle is stored in the ENVI header and
is used when overlaying grids, so the grid lines will appear at an angle.
• To change the output pixel size, replace the value in the “Output Pixel
Size” text box.
• To change the output rotation angle, replace the value in the “Output
Rotation” text box.
Note
If you change a non-zero rotation angle to 0 so north is “up,” your resulting image
may contain a lot of background fill and may become very large.
8. Enter the DN value to use as the background value around the edges of the
warped data.
9. Enter an output filename.
10. Click “OK.”
1. From the ENVI main menu, select Map > Georeference from Input Geometry
> Build Super GLT.
2. Select the input X and Y geometry bands, then select the input and output
projections.
The process runs in two parts. The regular GLT filename appears in the Available
Bands List, but the Super GLT filename does not.
1. Select Map > Georeference from Input Geometry > Georeference from Super
GLT.
2. In the input file selection dialog, select the data file to georeference and
perform any spectral subsetting.
3. In the next file selection dialog, select the super GLT file.
The Georeference from SGL Parameters dialog appears.
4. In the “Background Pixel Value” text box, enter the DN value to use as the
background value around the edges of the warped data.
5. In the “Kernel Size Min” and “Max” text boxes, enter a minimum and
maximum kernel size to use, or click the arrow buttons to set the values.
The minimum kernel size is used in the resampling unless fewer than the
“minimum number of pixels to resample,” or valid pixels, are contained in the
kernel. If fewer than the minimum number of valid pixels are contained in the
kernel, the kernel size is increased until either the minimum number of valid
pixels is met or the maximum kernel size is met. If there are fewer than the
minimum number of valid pixels in the maximum kernel size then the output
pixel value will be set to the background value.
6. Enter the minimum number of pixels to resample, or click the arrow buttons to
set a value.
If fewer than the minimum number of pixels are contained in the maximum
kernel size then the output pixel value will be set to the background value.
7. Select “File” or “Memory” output.
8. Click “OK.”
The results appear in the Available Bands List.
A default output pixel size and rotation angle are calculated and appear in the
Build Geometry Lookup File Parameters dialog.
5. In the “Kernel Size Min” and “Max” text boxes, enter a minimum and
maximum kernel size to use, or click the arrow buttons to set the values.
The minimum kernel size is used in the resampling unless fewer than the
“minimum number of pixels to resample,” or valid pixels, are contained in the
kernel. If fewer than the minimum number of valid pixels are contained in the
kernel, the kernel size is increased until either the minimum number of valid
pixels is met or the maximum kernel size is met. If there are fewer than the
minimum number of valid pixels in the maximum kernel size then the output
pixel value will be set to the background value.
6. Enter the minimum number of pixels to resample, or click the arrow buttons to
set a value.
If fewer than the minimum number of pixels are contained in the maximum
kernel size then the output pixel value will be set to the background value.
7. Enter an output filename for the super GLT file, if desired.
8. In the “Background Pixel Value” text box, enter the DN value to use as the
background value around the edges of the warped data.
9. Select “File” or “Memory” output.
• For “File” output, click the “Compress” check box if you want to
compress the output file.
10. Click “OK.”
The results appear in the Available Bands List.
3. If your input file is not in HDF or CEOS format, select the associated HDF or
CEOS annotation file to read the header information from.
4. When the SeaWiFS Geometry Parameters dialog appears, select the values to
be computed by selecting one of the options below:
• To select individual values, click in the check boxes next to the desired
value.
• To select a range of values, enter the beginning and ending numbers into
the two text boxes next to the “Add Range” button and click “Add Range.”
• To select all values, click “Select All.”
• To de-select any selected items, click “Clear.”
5. Select “File” or “Memory” output.
6. From the “Output Data Type” button menu, select “Double” or “Floating
Point.”
7. Click “OK.”
1. Select Utilities > Data-Specific Utilities > SeaWiFS Utilities > HDF
Georeference Data or CEOS Georeference Data or Map > Georeference
SeaWiFS > HDF Georeference Data or CEOS Georeference Data
2. When the SeaWiFS Input File dialog appears, select an image file and perform
any spatial or spectral subsetting.
3. If your input file is not in HDF or CEOS format, select the associated HDF or
CEOS annotation file to read the header information from.
4. When the Georeference SeaWiFS Parameters dialog appears, select the desired
output map projection from the list (see “Selecting Map Projection Types” on
page 757).
5. Enter the number of X and Y warp points to use in the corresponding “X” and
“Y” text boxes.
You may select a number of warp points up to the number of samples and lines
in your image. If you select fewer warp points, they will be evenly spaced
throughout the image.
• To save the warp points to a GCP file, enter or choose an output filename.
Note
Using many warp points increases the warping time considerably, but can
significantly increase the accuracy of the georeferencing.
6. Click “OK.”
7. When the standard Registration Parameters dialog appears, select the
warping and resampling methods and change the output dimensions, if
desired (see “Warping and Resampling” on page 714 for details).
Tip
We recommend that you use the triangulation method to produce the most accurate
results. Note, however, that it will be much slower than polynomial warping.
1. Select Map > Georeference AVHRR Data > Build Geometry File or Basic
Tools > Data-Specific Utilities > AVHRR Utilities > Build Geometry File.
2. Select the original AVHRR file.
The AVHRR Image Geometry Parameters dialog appears.
3. Select which values to compute by clicking on them in the list.
4. Select whether to output the zenith angles in degrees or radians by selecting
the corresponding toggle button.
The zenith is the angle measured vertically from each pixel to the sensor or sun
(straight above the pixel = 0 degrees).
5. Enter an output filename.
6. Select “Double” or “Floating Point” output data type from the “Output Data
Type” button menu.
7. Click “OK.”
ENVI extracts the header information and calculates the geometry values for each
pixel.
Note
After the original AVHRR data are georeferenced, the header information needed
to calculate the calibration and sea surface temperatures is not in the new ENVI
header. Therefore, georeferencing should not be done until the AVHRR data is
calibrated and the sea surface temperatures are calculated (see “Calibrating
AVHRR Data” on page 472 and “Computing Sea Surface Temperature” on
page 473).
Tip
We recommend that you use the more accurate technique, (AVHRR) Build
Geometry File and Georeference from Input Geometry (see “Georeferencing from
Input Geometry” on page 745), instead of Georeference AVHRR Data.
1. Select Map > Georeference AVHRR Data > Georeference or Basic Tools >
Data Specific Utilities > AVHRR Utilities > Georeference Data.
2. Select the input data file and perform any spatial and/or spectral subsetting.
• If the input data file is not the original AVHRR format file, another input
file dialog appears for selection of the original AVHRR file.
The georeferencing information is extracted from the original AVHRR file.
3. When the Georeference AVHRR Parameters dialog appears, select the
desired output map projection from the list and enter any necessary
parameters (see “Selecting Map Projection Types” on page 757).
4. Enter the number of X and Y warp points to use in the corresponding “X” and
“Y” text boxes.
Up to 51 points in the X direction and up to the number of lines in the Y
direction can be used in the georeferencing. If fewer warp points are entered,
they are evenly spaced throughout the image.
Note
Using many warp points increases the warping time considerably, but can
significantly increase the accuracy of the georeferencing.
5. Click “OK.”
The standard Registration Parameters dialog appears for you to select the
warping and resampling methods and to change the output dimensions (see
“Warping and Resampling” on page 714 for details).
6. Select either “File” or “Memory” output and click “OK.”
1. In the list of projection types, click on the name of the projection to select it.
• To build a customized map projection, click “New” and follow the
instructions under “Building Customized Map Projections” on page 758.
Different parameters are available depending on the selected projection type.
2. Enter or select the corresponding secondary parameters for the selected
projection type:
• If you select “Arbitrary,” select either “Pixel Based” or “Map Based” by
clicking on the arrow toggle button next to the “Coordinates” label.
Pixel-based uses the upper left corner as the origin and map-based uses the
lower left corner as the origin. Either selection only affects the “y”
coordinates.
• To change the datum for a projection type, click the “Datum” button and
select a datum from the list in the “Select Geographic Datum” dialog.
The datum conversions are done using the Molodensky Transformation
(see the web page http://www.connect.net/jbanta/).
• If you select “UTM,” click the “N” or “S” toggle button to indicate if the
selected latitude is north (N) or south (S) of the equator. Enter a zone, or
click the “Set Zone” button and enter the latitude and longitude values to
automatically calculate the zone.
• If you select a “State Plane...” projection, enter the zone or click the “Set
Zone” button and select the zone name from the list.
Both NOS and USGS zone numbers are shown next to the zone name.
• To designate the units for a projection type, click the “Units” button and
select a unit type. Enter a pixel size (in the selected unit), if needed.
1. Select Map > Build Customized Map Projection, or click the “New” button in
any dialog where map projection selection is available.
2. When the Customized Map Projection Definition dialog appears, either enter a
new projection name and parameters, or select Projection > Load Existing
Projection to select from a list of “standard” projections contained in the file
“map_proj.txt” located in the ENVI directory structure (see “ENVI Map
Projections File” on page 886).
Once loaded, all of the parameters can be edited.
3. Enter or modify the projection name in the “Projection Name:” text box.
4. Select the “Projection Type” from the list of supported projections (see “Map
Projections” on page 913).
Figure 10-15: The Customized Map Projection Definition dialog. Options on the
right side of the dialog vary depending on the map projection.
• To save the new or modified projection information, select File > Save
Projections.
The file map_proj.txt, located in the ENVI directory structure, is
modified to contain the new projection. You can edit this file using
any text editor as an alternate to the interactive definition above.
10. Select File > Cancel to exit the function.
6. Click “OK.”
The Convert Map Projection function uses the standard registration
parameters dialog to perform the warping of the image to the new
projection (see “Warping and Resampling” on page 714).
7. When the Registration Parameters dialog appears, select the warp method:
RST, Polynomial, or Triangulation.
8. Select the resampling method: Nearest Neighbor, Bilinear, or Cubic
Convolution.
9. Enter the output filename.
Layer Stacking
Use Layer Stacking to build a new multiband file from georeferenced images of
various pixel sizes, extents, and projections. The input bands will be resampled and
re-projected to a common user-selected output projection and pixel size. The output
file will have a geographic extent that either encompasses all of the input file extents
or encompasses only the data extent where all of the files overlap.
For detailed instructions, see “Layer Stacking” on page 421.
Figure 10-17: The Map Coordinate Converter and Projection Selection dialogs.
Using GPS-Link
Use GPS-Link to read National Marine Electronics Association 0183 format (NMEA
0183) data directly from a GPS unit. The GPS must be manually set to the NMEA -
0183 mode. ENVI supports a GPS-link on PCs running Microsoft Windows 95,
Windows 98, Windows NT, or Windows 2000.
9. Enter X and Y output pixel sizes in the units that correspond to your projection
type and select the output data type from the button menu.
2. When the Topo Model Input DEM dialog appears (see Figure 12-2), select a
DEM image to process from the file list and perform any spatial subsetting.
• To open a new DEM image, select File > Open New File.
3. Click “OK.”
The Topo Model Parameters dialog appears.
4. Enter the desired kernel size.
Tip
Use various kernel sizes to extract multi-scale topographic information. Larger
kernel sizes run slower.
Figure 12-2: The Topo Model Parameters Dialog (left) and the Compute Sun
Elevation and Azimuth dialog (right).
For more information, see the following reference on the World Wide Web at
www.geog.le.ac.uk/jwo/research.
• If a pixel size was not found in the ENVI header for the DEM file,
enter the X and Y pixel size (in meters) in the corresponding text boxes.
5. In the “Select Features to Classify” list, click on the features to be included in
the output classification image.
If a feature type(s) is not selected, those pixels will be unclassified.
• To select all of the features, click “Select All Items.”
• To deselect all of the selected features, click “Clear All Items.”
6. Select output to “File” or “Memory.”
7. Click “OK.”
A status window displays the progress of the operation. The output classification
image file can be displayed from the Available Bands List: green represents plane,
blue represents channel, orange represents ridge, red represents pass, yellow
represents peak, and magenta represents pit. An example of a topographic features
result is shown in Figure 12-4.
Tip
You can change the class colors by selecting Tools > Color Mapping > Class Color
Mapping (see “Mapping Class Colors” on page 364).
(To compute sun elevation values, see “Computing Sun Elevation Values” on
page 799.)
4. Click on the name of a color table to select it from the list.
5. From the “Stretch” button menu, select a stretch type.
• If you select “% Linear,” enter the percentage to clip.
• If you select “Linear Range,” enter the minimum and maximum values.
• If you select “Gaussian,” enter the number of standard deviations for the
data distribution.
6. Select “File” or “Memory” output.
7. Click “OK.”
The Hill Shade image is available for display from the Available Bands List.
Computing Sun Elevation Values
1. In the Hill Shade Image Parameters dialog, click “Compute Elevation and
Azimuth.”
The Compute Sun Angle dialog appears.
2. Select the month from the “Month” button menu, and enter the day, year, and
time (GMT) in the appropriate text boxes.
3. Enter the desired latitude and longitude coordinates in the appropriate text
boxes.
4. Click “OK” to perform the calculations.
The calculated elevation and azimuth are automatically entered into the Hill Shade
Image Parameters dialog.
1. Select Topographic > Replace Bad Values or Radar > TOPSAR Tools > DEM
Replace Bad Values.
2. When the DEM Input File dialog appears, select the DEM file and perform any
subsetting or masking.
The Replace Bad Data Parameters dialog appears.
3. Enter a bad pixel value or a range of bad pixel values in the appropriate text
boxes.
Note
No values are needed if you selected a mask band that contains the locations of the
bad pixels.
1. Display the grayscale or color image you want to be draped over your DEM
(or other 3-D data set).
The entire image is used as the overlay image on the DEM unless both your
image and DEM files are georeferenced. If both the files are georeferenced,
then only the part of the image that overlaps with your DEM is used. If the
DEM is subset, then the georeferenced image is also subset to match. The
spatial resolutions of the two files do not need to be the same.
2. Select one of the following options:
• From the ENVI main menu, select Topographic > 3-D SurfaceView.
• From the Display menu, select Tools > 3-D SurfaceView.
3. If more than one display window is open, select the display window that
contains the desired image.
4. Select the associated digital elevation model (DEM) input file (or other 3-D
data set) and perform any spatial subsetting.
5. Select the desired DEM Resolution (number of pixels) check box(es) to use for
the 3-D plot.
6. Click the “Nearest Neighbor” or “Aggregate” buttons to select a resampling
method.
Nearest neighbor resampling uses the nearest DEM value when resampling
and pixel aggregate averages all the DEM values that contribute to the
output pixel. For example, if your DEM resolution is 30 meters and your
image resolution is 60 meters, the nearest neighbor resampling will use
every other pixel and every other line to create the DEM in the 3-D window
and the pixel aggregate option will average four pixels to create the output
DEM.
Warning
Using higher DEM resolutions will significantly slow the display and should only
be used on powerful platforms.
More than one resolution can be selected. Typically you will want to use the
lowest resolution (64) while you are determining the best flight path. Then a
higher resolution can be used to display your final fly-through sequence.
7. Enter DEM minimum and maximum plot values if desired.
DEM values lower than the minimum value and higher than the maximum
value will not be plotted in the 3-D views.
8. Enter the vertical exaggeration.
The value entered produces a true scale vertical exaggeration applied to the Z
axis where higher values correspond to greater exaggeration.
9. Select either “Full” or “Other” image resolution.
If you select “Other,” click the “Nearest Neighbor” or “Aggregate” buttons to
select a resampling method.
10. Set the “High Resolution Texture Mapping” parameter to “Off” or “On” by
clicking the arrow button.
When this parameter is “On”, which is the default, a higher resolution image is
used, if it is available, when you zoom into your the 3-D SurfaceView. The
input image needs to be at least 1024 x 1024 pixels in order for the “High
Resolution Texture Mapping” parameter to have a noticeable effect in the 3-D
SurfaceView.
• To set a higher image resolution, set it under “Image Resolution” as
described in step 9. “Full” resolution is the highest possible resolution, but
if you have a large image, full resolution may cause you to run out of
memory.
Note
Using the “High Resolution Texture Mapping” option may make zooming and
flying through the 3-D SurfaceView slow.
11. Click on the “Spatial Subset” button and select a spatial subset of the image, if
desired.
The spatial dimensions of the DEM and image do not need to be same. The full
dimensions (or selected subsets) of both data sets will be displayed.
12. Enter the X and Y pixel sizes of the image.
The pixel sizes are used to determine the correct vertical exaggeration factor
and they need to be in the same units as the DEM.
Figure 12-7: A “Texture” type 3-D plot displayed in the 3-D SurfaceView
plot window.
• To reset the surface plot to its original position, select Options > Reset View in
the 3-D SurfaceView plot window.
The mouse button functions are listed in Table 12-1. You can also control the
rotation, translation, and zoom by using the Options menu in the 3-D SurfaceView
plot window.
• To display the desired surface plot type, select Surface > Texture, Wire, Ruled
XZ, Ruled YZ, or Point.
The display changes automatically.
• To see through the wire mesh lines when a wire or ruled surface is
displayed, select Options > Wire Lines:See Through.
• To use hidden wire mesh lines when a wire or ruled surface is displayed,
select Options > Wire Lines:Hidden.
Note
This option is much slower than using the Wire Lines:See Through option.
See the following sections for details about working in the two different modes.
Figure 12-8: The Surface View Motion Controls dialog in User Defined mode
(left) and in Annotation mode (right).
• To delete a projection in the flight path list, click on the path view number
and click “Delete.”
• To clear the flight path list, click “Clear.”
6. Enter the number of frames to be used in the “fly-through” animation.
The flight path will be smoothly interpolated between the projections.
7. Click the “Play Sequence” button to animate the fly-through.
• To control the speed and direction of the fly-through, select Options >
Animate Sequence in the SurfaceView Motion Controls dialog (see
“Animating Flight Paths” on page 812).
Defining a Flight Path in Annotation Mode
Use “Annotation” mode to define a flight path based on annotation drawn on the
image in the display window from which the 3-D SurfaceView was created, or based
on an imported annotation object. Use a polyline, polygon, rectangle, or ellipse
annotation object to define the flight path (see “Annotating Images” on page 222 for
annotation details). You can control the vertical and horizontal look angles, fly at a
constant elevation above the DEM terrain, or fly at a constant altitude.
Note
To use Annotation mode, you must have annotation drawn on the display window
from which the 3-D SurfaceView was created, or have the desired annotation object
saved in an annotation file (.ann).
1. In the Surface SurfaceView Motion Controls dialog, select Options > Motion:
Annotation.
2. When the Input Annotation Flight Path dialog appears, select whether to
import annotation from the display or from a file by clicking the corresponding
button.
• If you select the option to input the annotation object from a display
window, select the desired annotation object.
• If you select the option to import the annotation object from a saved
annotation file, select the desired annotation (.ann) file and object.
The selected annotation object, number of nodes, and the number of points are
displayed in the middle of the SurfaceView Motion Controls dialog and the
flight path is plotted on the 3-D SurfaceView plot.
Tip
If you are already in Annotation mode and want to input annotation, select File >
Input Annotation from Display or Input Annotation from File in the SurfaceView
Motion Controls dialog.
Figure 12-9: Use the RST Controls dialog to control rotation, scaling (zoom), and
translation of the 3-D SurfaceView plot.
Changing Rotation
1. In the Rotation section of the SurfaceView RST dialog, click on the arrow
buttons to change the rotation of the surface plot.
2. In the “Inc” text box, enter a value in degrees, to change the rotation
increment.
Zooming
1. In the Scaling section of the SurfaceView RST dialog, click the “+” or “-”
buttons to zoom in or out of the surface plot.
2. In the “Inc” text box, enter a value to change the zoom increment.
Moving the Image
1. In the Translation section of the SurfaceView RST dialog, click on the arrow
buttons to move the surface plot.
2. In the “Inc” text box, enter a value to change the translation increment.
Animating Flight Paths
Use Animate Sequence (in either User Defined or Animation modes) to display and
“fly through” your 3-D SurfaceView in an animation window. In the animation
window, you can control the characteristics of your “fly-through” with more
precision than in the SurfaceView Motion Controls dialog:
1. Select Options > Animate Sequence.
The SurfaceView is displayed in the standard ENVI animation window.
2. See “Controlling Animation Characteristics” on page 379 for details about
using animation controls.
Note
The first few times through the frame sequence may be slow until the frames are put
in memory.
Viewing Panoramically
To view the surface view panoramically as if you were “standing” in the image:
1. Select Options > Position Controls.
2. Click the arrow buttons to select “Map Coord” for georeferenced images, or
“Pixel Coord” for non-georeferenced images.
• If you select “Pixel Coord,” enter the sample and line coordinates of where
you want to “stand” in the image or use the arrow increment buttons to
select the coordinates.
Note
If your image is a subset of a larger image, you can use the X and Y pixel offsets
from the header file by clicking the arrow toggle button next to the “Use Offset”
label to select “Yes.”
• If you select “Map Coord,” enter the map coordinates of the location
where you want to “stand” and click “Change Proj” to change the
projection (if desired).
3. Set whether changes will be automatically applied by clicking the “Yes” or
“No” toggle button next to the “Auto Apply” label.
4. Select from the following options to change your position and viewing angle in
the surface view image.
Note
You must have vectors displayed in the Main Image window from which the 3-D
SurfaceView was created. For information about overlaying vectors on an image,
see “Overlaying Vectors” on page 295.
• To change the output window size, enter the size (in pixels) in the “MPEG
Output Size” text boxes.
2. In the “Number of Frames” text box, enter the number of frames (individual
views) to be included in the output flight sequence (movie).
More frames will make a longer sequence, but will also make a larger output
file.
3. From the “MPEG Frame Rate” button menu, select a rate in frames/second.
4. Enter the desired MPEG compression quality.
5. Enter a duplication factor, if desired.
This helps to make the MPEG output appear smoother. For example, a
duplication factor of “2” will duplicate each frame and double the number of
output frames.
6. Enter an output filename and click “OK.”
Note
The writing of the output MPEG file is done in two steps and the second step cannot
be cancelled and can take up to many seconds per frame.
The compression is a lossy compression where 0 is lowest quality and 100 is highest
quality (no compression). Entering a compression quality factor less than 100
decreases the amount of disk space used to store the MPEG output.
2. When a standard ENVI file selection dialog appears, select the file from which
the header will be read.
A report of the header information is printed on the screen.
• To save the report to an output file, select File > Save Text to ASCII and enter
an output filename.
Figure 13-2: The Antenna Pattern Correction plot showing a first order
polynomial fit in white.
5. Enter the desired polynomial order and click “Plot Polynomial” to show a plot
of the mean data values in red with the selected polynomial fit overlaid in
white.
• The polynomial order can be changed and plotted again.
It is best to use a low order polynomial so as not to remove the local variation
in backscatter signal.
Note
The Antenna Pattern Correction plot pulldown menus will not be active until you
close the Antenna Pattern Correction Parameters dialog.
Necessary parameters will be automatically read from the selected input file
and entered into the Slant to Ground Range Parameters dialog.
• To manually enter the necessary parameters, click “Cancel” and enter
the parameters in the Slant to Ground Range Parameters dialog.
3. When a standard ENVI input file dialog appears, select the input file and any
spatial and/or spectral subsetting.
4. Click “OK.”
The Slant to Ground Range Parameters dialog appears.
5. Enter the desired output pixel size, select the desired resampling method, and
select memory or file output.
6. From the “Near Range” button menu, select the location of the near range in
the image: “Top,” “Bottom,” “Left,” or “Right.”
7. Click “OK” to start the processing.
2. When a standard ENVI input file dialog appears, select the input file and
spatial and/or spectral subsetting.
3. Click “OK.”
The Slant to Ground Range Parameters dialog appears.
4. Enter the instrument height, near range distance, slant range pixel size, and
desired output pixel size.
5. From the “Near Range” button menu, select the location of the near range in
the image: “Top,” “Bottom,” “Left,” or “Right.”
Please see “Warping and Resampling” on page 714 for details about
resampling methods.
6. Select output to “Memory” or “File.”
7. Click “OK” to start the processing.
Adaptive Filters
ENVI includes several adaptive filters to use for SAR processing. The filters include
Lee, Frost, Gamma, Kuan, and Local Sigma to reduce image speckle and a Bit Errors
filter to remove bad pixels.
• To select a filter, select Radar > Adaptive Filters > Filters.
The filters can also be accessed from the Filters menu on the ENVI main menu and
are described in detail in “Using Adaptive Filters” on page 604.
Texture Filters
ENVI includes several texture filters for extracting textural information from SAR
and other data types. These include filters based on the data range, RMS, 1st moment,
and 2nd moment of the data.
• To select a filter, select Radar > Texture > the desired filter.
The filters can also be accessed from the Filters menu on the ENVI main menu and
are described in detail in “Using Texture Filters” on page 599.
Tip
To transfer the JPL AIRSAR files to your local disk, use standard system-level tape
utilities or the ENVI “Dump Tape” routine (see “Dumping Tape Data” on
page 151). You can use AIRSAR data with missing or non-standard headers, but
you have to enter the data parameters as described in “Entering Missing AIRSAR
Parameters” on page 834).
For easier processing, name the three files with the following convention:
filename_p.stk, filename_l.stk, and filename_c.stk.
The Input Stokes Matrix Files dialog appears. Use this dialog to read the
compressed Stokes matrix files.
Warning
Do not open the Stokes matrix files using the standard ENVI File menu selection.
• To clear the names in the Stokes Matrix Input File dialog at any time, click
“Reset” or click “Cancel” to quit without processing.
If the file has a valid AIRSAR header with all of the required parameters, the
filename is listed in one of the “Selected Files” text boxes in the Input Stokes
Matrix File dialog (depending on whether the file is P-, L-, or C-band data). If
you followed the suggested file naming convention described above, correct
file names for the other two files are automatically entered into the appropriate
text boxes. Otherwise, the file selection process must be repeated for each of
the bands.
Note
If the Stokes Matrix input file does not have a valid AIRSAR header, or if values
are missing from the header, the AIRSAR Header Parameters dialog appears. For
instructions, see “Entering Missing AIRSAR Parameters”.
All of the synthesized bands are placed in a single file. The synthesized images are
added to the Available Bands List and can be processed further using standard ENVI
image processing functions.
1. In the AIRSAR Header Parameters dialog, verify the parameters and change
values as required.
2. Enter any missing values.
3. Click “OK” to return to the Stokes Matrix Input File dialog.
Selecting Synthesizing Parameters
Use the Synthesize Parameters dialog to select specific send and receive polarization
combinations to be synthesized into ENVI images. The “standard” polarizations
(H=horizontal, V=vertical) “HH,” “VV,” “HV,” and a total power (TP) image are
generated for each of the three frequencies (bands) by default. These bands appear in
the “Select Bands to Synthesize” list.
• To mask bad data values, enter the minimum and maximum data values to use,
in units of intensity, in the “Intensity Min” and “Max” text boxes.
When outputting images in dB, the minimum and maximum values are still entered in
units of intensity as the output is bounded by these values prior to computing dB
(e.g., If you bound the data by 0 to 1 then a dB image will be bounded by -Inf to 0).
Synthesized values less than the minimum will be set to zero (0) and values greater
than the maximum will be replaced by the value one (1).
For easier processing, name the files with the following convention: filename_c.cdp
and filename_l.cdp.
• To clear the file names in the Data Products Input File dialog at any time, click
“Reset” or click “Cancel” to quit the process without processing.
4. Click “OK” to accept the filenames.
The Synthesize Parameters Dialog appears.
• Enter the number of samples and lines in the corresponding text boxes.
• Enter the image size in the range direction (in kilometers) in the “Width
(km)” text box.
• Enter the scene size in the azimuth direction (in kilometers) in the “Length
(km)” text box.
• To skip any imbedded header and get to the beginning of the SIR-C data,
enter the byte offset in the “Offset” text box.
• Click the “C” or “L” band toggle button.
• Select “SAR Channel Type” by clicking on a SIR-C data type toggle
button.
• To strip line headers from the input data and exclude them from output
image, click the “Yes” toggle button.
If the data have been dumped directly from tape in CEOS format, they
may have an extra 12 bytes at the beginning of every line.
• Click “OK” to return to the Data Products Input File dialog.
Note
You can also extract polarization signatures using the Display Tools menu (see
“Extracting Polarization Signatures” on page 356).
Note
The z axis units you select will be used for the polarization signature images; all
three axis units will be available when the data are visualized in the Polarization
Signature Viewer.
5. Select whether or not to load each signature into its own Polarization Signature
Viewer after it is extracted by clicking the “Yes” or “No” toggle button.
Tip
Selecting “Yes” may create numerous windows and use significant amounts of
resources. The preferred alternative is to select “No” and to use the Polarization
Signature Viewer function to view individual signatures (see the following “Using
the Polarization Signature Viewer” section).
6. Click “OK.”
Both co-polarized and cross-polarized signatures are calculated for each selected
ROI. When completed, the signatures are listed in the Available Bands list. They
can also be analyzed in their own Polarization Signature Viewers (see the
following “Using the Polarization Signature Viewer” section).
When the Polarization Signature Viewer appears, a 3-D wire mesh surface is
displayed on the left and a 2-D gray scale image of the signature is displayed on the
right (see Figure 13-9). The statistics for the current signature are listed below the
plot.
The color table is applied to all displayed Polarization Signature Viewers. For more
information about color tables, see“Applying ENVI Color Tables and Density Slices”
on page 358.
Note
The color table only applies to the 3-D plot if it is a shaded surface.
Outputting Signatures
• To save the 3-D signature as an image file, select File > Save Plot As > Image
File.
• To save the 3-D signature as a VRML 2.0 file, select File > Save Plot As >
VRML.
• To print the 3-D signature, select File > Print.
For detailed instructions, see “Display Output Options” on page 398.
Outputting Statistics to ASCII Files
To save the current polarization signature statistics to an ASCII file:
1. Select File > Save Stats as ASCII.
2. Enter an output filename and click “OK.”
Tip
If you load another signature, you can save the statistics for it and append them to
the same file by using the same filename.
The numbers next to the title in the ASCII file are the pixel locations of the pixel the
signature was extracted from.
Closing Polarization Signature Viewers
• To close the Polarization Signature Viewer, select File > Cancel.
• To close all open Polarization Signature Viewers, select Options > Close all
Polsig Windows.
Figure 13-11 shows polarization signatures and surface plots that have been
annotated to clarify the relation between the images and the default orientation 3-D
polarization signatures.
1. Select Radar > Polarimetric Tools > Multilook Compressed Data > SIR-C
Multilook.
2. When the Input Data Product File dialog appears (see Figure 13-3), select a
compressed input file using the procedures described in “Synthesizing JPL
AIRSAR Data” on page 832.
3. When the SIR-C Multi-look Parameters dialog appears, choose the files to
multilook by clicking on the file name in the “Select Files to Multilook” list.
4. Enter the desired number of looks in the “Samples (Range)” and “Lines
(azimuth)” directions or select from the following options:
• To specify the number of pixels desired in the output image, enter the
values in the “Pixels” text boxes for the samples and lines.
• To specify the desired output pixel size in meters, enter the values in the
“Pixel Size (m)” text boxes for samples and lines.
When one of these parameters is entered, the others are automatically
calculated to match. For example, if you enter the Pixel Size as 30 m, then
the corresponding number of pixels and the looks are calculated and
change in the corresponding text boxes.
Note
Both integer and floating point number of looks are supported.
5. Click “Spatial Subset” to use standard ENVI Procedures to subset the data.
6. Enter a base name in the “Enter Base Name” text box.
This name will be used as the basis for multiple file names, one for each
frequency selected. For example if you enter “sirc” as the base name and both
C-band and L-band data are being processed, then two output files will be
created with the names “sirc_c.cdp” and “sirc_l.cdp”
7. Click “OK” to multilook the data.
Use the synthesize function to generate image data from the output multilooked
compressed data files (see “Synthesizing SIR-C Data” on page 837).
1. Select Topographic > Replace Bad Value or Radar > TOPSAR Tools > DEM
Replace Bad Values.
2. When the DEM Input File dialog appears, select the DEM file and perform any
subsetting or masking.
The Replace Bad Data Parameters dialog appears.
3. Enter a bad pixel value or a range of bad pixel values in the appropriate text
boxes.
Note
No values are needed if you selected a mask band that contains the locations of the
bad pixels.
Installing and
Customizing ENVI
Appendix A describes ENVI hardware and software requirements and some details about
installing and customizing ENVI. This appendix covers the following topics:
Memory
32 Mb recommended
Mouse
UNIX - 3-Button Mouse
Windows - Three-button mouse with device driver for all three buttons is
recommended. Microsoft 2-button mouse or equivalent 2-button mice are supported
through emulation. The middle button is simulated using the left mouse button and
the control key pressed simultaneously.
Display
1024 x 768, 8 bit or 24 bit color display minimum.
Storage
Approximately 60 Mb for program and supporting files (300 Mb+ for data).
Platform Dependencies
SCSI Tape Support for PCs
ENVI includes tape support for PCs running Microsoft Windows 95, Windows 98,
Windows 2000, and Windows NT versions 3.51 and 4.0. The tape drivers are
installed automatically. Please see the install instructions for additional information.
The file “envitape.txt” file also gives more specific information on how to use these
drivers from within ENVI. Once installed, this routine provides transparent access to
ENVI tape tools using the ASPI32 interface provided with Windows. All ENVI tape
functions work the same as their UNIX counterparts on any SCSI tape device that
runs under ASPI32. Tape32 for ENVI supports reading of many known tape formats
including Landsat MSS, Landsat TM, AVHRR, AVIRIS, SPOT, etc. See the ENVI
Tape Utilities menu for a complete list. Other formats that are not directly supported
can be read using ENVI’s “Scan Tape” and “Dump Tape” functions.
• Select File > Tape Utilities > the appropriate tape function.
Setting the Window Drag in Windows NT
ENVI has problems resizing windows in Windows NT if “Full Drag” is on for
window resizing.
Turning off “Full Drag” in Window NT 4.0
1. Click the right mouse button in the display background.
2. Select “Properties” and click on the Plus! tab.
3. Make sure that “Show Window Contents While Dragging” is deselected.
Customizing ENVI
You can setup custom menus, system configuration variables, and even add your own
ENVI routines to the ENVI menu. Several files are used for custom configurations
(located in the /menu and /map_proj subdirectories):
colors.txt - ENVI graphics colors rgb file (see “ENVI Graphic Colors File” on
page 883).
display.men - display menu file (see page “The ENVI Display Menu Definition File”
on page 874).
e_locate.pro - ENVI directory locator file.
envi.cfg - system configuration file (see “The ENVI Configuration File” on
page 867).
envi.men - main menu file (see “The ENVI Main Menu Definition File” on
page 873).
filetype.txt - contains a list of ENVI file types and the routine name used to read the
files that need specialized spatial and spectral readers.
map_proj.txt - user-defined map projections file (see “ENVI Map Projections File”
on page 886).
sensor.txt - list of sensor types that appears in the ENVI header (see “ENVI Sensor
File (sensor.txt)” on page 885).
useradd.txt - used to define parameters for user-defined plot routines, Spectral
Analyst routines, user-defined map projection routines and/or user-defined map
projection units (see page 868 for details).
usersym.txt - contains user-defined symbols.
For example, if you want to setup your own private ENVI configuration in a
directory, copy the above files from the installation directory to your personal
directory. ENVI first searches for the file envi.cfg using the IDL !PATH variable,
so the directory where you place the local copy of envi.cfg must be included in
your IDL_PATH variable *BEFORE* the standard $IDL_DIR/lib entry. There
must also be a file with a “.pro” or “.sav” extension in this directory as well, which is
why the e_locate.pro dummy file is included. Once the envi.cfg file is located,
ENVI uses this file to locate the other user definable files; envi.men,
display.men, map_proj.txt, and colors.txt.
The configuration items “default envi menu file,” “default display menu file,”
“default graphic colors file,” and “default map projection file” in “envi.cfg” can be
used to tell ENVI where local copies of these files may be found. If any of these
entries are left blank or are invalid, ENVI searches for the files in the default ENVI
installation directories.
Once ENVI successfully locates your private copies of these files, they may be edited
for your own configuration and menu setups. See the following section for details
about the ENVI configuration and menu files.
default envi menu file - specifies a user file that defines the ENVI main menu
(optional).
default graphic colors file - specifies a user file to define the graphic colors
(optional).
default map projection file - specifies a user file that defines map projections
(optional).
default output directory - this is the specified directory for output files and will be
the default directory every time ENVI output files are written unless another specific
path is specified.
default output page offset - specifies the default x and y page offset for multiple
page postscript output in inches or centimeters.
default output page size - specifies the default page size for postscript output in
either cm or inches.
default previous files file - (optional) specifies a file name used to store the names of
the 20 previous files opened in ENVI using the Open Image File menu item.
default save_add directory - (optional) if you place your custom IDL routines in
this directory they will automatically be restored or compiled when ENVI is started.
default spectral library directory - this is the default directory every time ENVI
spectral library file selection functions are started.
default startup script file - (optional) specifies a file name that contains the script
that executes upon startup of ENVI.
default tmp directory - used to store ENVI temporary files.
default useradd text file - (optional) contains button name, event handler, etc., for
user-defined plot routines, spectral analyst routines, user-defined map projection
routines and/or user-defined map projection units (see User Defined Units in the
ENVI Programmer’s Guide).
display default stretch - designates the default stretch that will be used for images
loaded into ENVI display windows. Options are “n% linear” (where “n” is a specific
value for example 0% linear, 2% linear, etc.), “m n linear” (where m is data minimum
and n is data maximum), “n gaussian” (where “n” is the number of standard
deviations about the mean), “equalize” (for histogram equalization), and “square
root” (for square root stretch).
display retain value - sets the control of the backing store. A retain value of 0
specifies no backing store. A retain value of 1 requests that the server or window
system provide backing store. A retain value of 2 (default) specifies that IDL provide
backing store.
exit idl on exit from envi - determines if IDL is automatically exited when exiting
from ENVI or if the IDL session remains open.
image tile size (Mb) - designates the tile size that will be used by ENVI for
processing. Tiling is an internal ENVI image segmentation technique that allows the
system to work on images larger than available RAM. This value should be set to
about 1/10th the total cache size described on page 871. Images of any size can be
viewed in ENVI, but this field determines how much of that image is kept in memory
at any given time.
image window default xsize and image window default ysize - sets the initial size
of the full resolution image windows in pixels.
image window scroll bars - determines whether the main image display has scroll
bars.
interactive stretch auto apply - sets whether on not to automatically apply changes
to the stretch in Interactive Stretching. This can also be toggled on/off from the
Interactive Stretching dialog.
main menu orientation - controls whether the ENVI main menu is displayed in a
horizontal or vertical orientation.
max number of histogram bins - indicates the maximum number of bins to use
during histogram calculation.
max number of items for multilist - indicates the maximum number of items to be
listed in a widget. If the number of items listed is greater than the specified number,
ENVI uses an alternate check box mode to speed up scrolling of the list.
max number of items in pulldown menus - indicates the maximum number of
items listed in a pulldown menu. If the number of items is greater than this maximum
value then the pulldown menu breaks the items into sub-menus each containing only
this max number of items or fewer. This keeps long lists of items from running off the
display.
max number of vertices for memory - indicates maximum number of polygon
vertices for vector files loaded into ENVI. If the number of vertices is greater than the
specified number, ENVI will not load the polygons into memory, but will create an
ENVI vector (.evf) file.
menu border size and edge border size - sets the window border sizes according to
system specific parameters to allow consistent spacing of window.
number of colors per rgb image and number of colors per gray scale image -
ENVI runs on 8- or 24-bit color workstations. These settings are for 8-bit mode. Each
display window occupies a certain range of entries in the color table. These two
parameters determine how many colors from the 256 colors in the color table are
used for each RGB “color quantized” image display and for each gray scale display.
open applicable formats automatically to memory - sets whether or not to open
BMP, HDF, JPEG, PICT, SRF, and XWD external files directly to memory instead
of prompting for file or memory output.
plot window default axis thickness - sets the thickness of the X and Y axis lines (1
is normal).
plot window default background color - sets the plot background color.
plot window default charsize - sets the default character size.
plot window default font - sets the default font for the axis labels and title.
plot window default foreground color - sets the plot foreground color.
plot window default key margin - sets the size of the margin when the key or data
labels are turned on.
plot window default minor ticks - sets the number of minor tick marks.
plot window default tick length - sets the length of the major tick marks, measured
as a ratio of the axis length normalized to 1.0, (e.g., a length of .02 results in ticks that
are 2% of the length of the entire axis).
plot window default xmargin - two values used to set the size (in characters) of the
margins around the plot axes. The first value is the left margin and the second value is
the right margin.
plot window default xsize/ysize - sets the initial size of a plot window in pixels.
plot window default ymargin - two values used to set the size (in characters) of the
margins around the plot axes. The first value is the bottom margin and the second
value is the top margin.
scroll and zoom window default position - allows selection of the initial position
(left, right, above, below, within, off) of the zoom and scroll windows relative to the
main image window.
scroll window default xsize and scroll window default ysize - sets the initial size of
the scroll windows
status window for input data reading - specifies whether a status window will
appear during input of data files.
status window for input data reading - sets whether or not to show a status window
when loading data of BIL or BIP format to a display window.
tape device name - default system device name for tape drives. A typical example
for a SCSI tape drive on a UNIX machine might be /dev/rst0 or /dev/rmt2h—check
your system documentation for the correct default device name for your specific
installation.
thread pool maximum elements - The maximum number of elements in a
computation that will be processed using the thread pool. Computations with more
than this number of elements will not use the IDL thread pool. Set this parameter if
large jobs are causing virtual memory paging on your system. Setting this value to 0
removes any limit on maximum number of elements. The default is 0.
thread pool minimum elements - The number of data elements (each element being
a single data value of a particular data type) in a computation that are necessary
before IDL will use the thread pool. If the number of elements is less than the number
you specify, ENVI will perform the computation without using the thread pool. Use
this parameter to prevent ENVI from using the thread pool on tasks that are too small
to benefit from it. The default is 100000.
thread pool number of processors - The number of threads that IDL will use in
thread pool computations. The default value is equal to the value of the number of
CPUs on your system, so that each thread will have the potential to run in parallel
with the others. Note that there is no benefit to using more threads than your system
has CPUs. However, depending on the size of the problem and the number of other
programs running on the system, there may be a performance advantage to using
fewer CPUs.
total cache size (Mb) - designates a soft limit for the amount of system RAM the
program will expect to use. ENVI has an internal memory management/cache
scheme that attempts to limit the amount of memory used. This is designed to avoid
“unable to allocate array” errors in IDL and segmentation fault/core dumps back to
system level from IDL on some platforms. This type of error results when the
program attempts to use more memory than is available. Higher values for the cache
size will speed up spatial processing functions. Set this value to slightly less than the
amount of available system RAM (less on multi-user systems) (see “Additional
Caching Information” on page 876).
user defined motion routine - specifies a user procedure that is called when the
mouse is moved within a display window (optional; see the ENVI Programmer’s
Guide).
user defined move routine - specifies a user procedure that is called when the zoom
location is moved within a display window (optional; see User Move Routines in the
ENVI Programmer’s Guide).
zoom window default xsize and zoom window default ysize - sets the initial size of
the zoom windows in pixels.
zoom window zoom increment - sets the integer zoom factor for each subsequent
zoom event.
The available startup commands and their formats are described here with the
keywords shown in italics.
Opening an Image File
Open File = filename
Loading a Gray Scale Image into a New Display
Load Band = band number
The band number refers to the file opened in the line above the load band command.
Loading an RGB Color Image into a New Display
Load Bands = R band number, G band number, B band number
The band numbers refer to the file opened in the line above the load band command.
Opening an ENVI Vector File
Open evf = filename
Opening a Region of Interest file
Open ROI = filename
Opening a Saved Display Group
Open Display Group = display group filename
The cache system tracks the total memory used by all data in the system. If the size of
a new process or display request exceeds the available memory, ENVI will remove
some items from cache until there is enough memory to store the result. The first
items removed are the raw data read from disk files, (oldest-by-use first), then the
byte-scaled display images are removed (oldest-by-use first), and finally, if enough
memory has not been freed, the memory-only items will be removed after requesting
you to save/remove them. If, however, the data in the current request is a memory-
only item, you are required to store (not remove) the item. If the request still exceeds
the total cache size with nothing in memory, the operation is still attempted.
Tip
You should, however, periodically store memory images to disk to avoid cases
where the “in memory” request is greater than the total cache size.
ENVI uses a generalized raster data format consisting of a simple “flat binary file”
and a small associated ASCII (text) header file. This approach permits ENVI’s
flexible use of nearly any image format, including those with embedded header
information. The text header provides ENVI with information about the dimensions
of the image, the internal header if present, the data format, and other pertinent
information.
The generalized raster data is stored as a binary stream of bytes either in band
sequential (BSQ), band interleaved by pixel (BIP), or band interleaved by line (BIL)
format. In its simplest form, the data is in BSQ format, with each line of the data
followed immediately by the next line in the same spectral band. This format is
optimal for spatial (X, Y) access of any part of a single spectral band. Images stored
in BIP format have the first pixel for all bands in sequential order, followed by the
second pixel for all bands, followed by the third pixel for all bands, etc., interleaved
up to the number of pixels. This format provides optimum performance for spectral
(Z) access of the image data. Images stored in BIL format have the first line of the
first band followed by the first line of the second band, followed by the first line of
the third band, interleaved up to the number of bands. Subsequent lines for each band
are interleaved in similar fashion. This format provides a compromise in performance
between spatial and spectral processing.
Because ENVI uses ASCII header files that are built “on-the-fly” if required, you
typically do not need to convert your image file formats. Additionally, the flexible
file format allows direct utilization of generic BSQ, BIL, or BIP files. ENVI has been
tested on numerous data types including MSS, TM, SPOT, ERS-1, AVHRR,
AVIRIS, GERIS, GEOSCAN, TIMS, digitized aerial photographs, DEM data,
AIRSAR, RADARSAT, and SIR-C data. All of these data types are supported in
their native formats (byte, integer, floating-point, etc.).
byte order -describes the order of the bytes in integer, long integer, 64-bit integer,
unsigned 64-bit integer, floating point, double precision, and complex data types;
Byte order=0 is Least Significant Byte First (LSF) data (DEC and MS-DOS systems)
and byte order=1 is Most Significant Byte First (MSF) data (all others - SUN, SGI,
IBM, HP, DG).
x-start and y-start - parameters define the image coordinates for the upper left hand
pixel in the image. The values in the header file are specified in “file coordinates,”
which is a zero-based number.
map info - lists geographic coordinates information in the order of projection name
(UTM), reference pixel x location in file coordinates, pixel y, pixel easting, pixel
northing, x pixel size, y pixel size, Projection Zone, “North” or “South” for UTM
only.
Note
In ENVI, pixel values always refer to the upper left corner of the pixel. Map
coordinates also typically refer to the upper left corner of the pixel. However, if you
entered “magic pixel” coordinates in the ENVI header, the map coordinates would
refer to the x,y coordinates entered (e.g., x=1.5, y=1.5 would make the map
coordinates refer to the center of the pixel).
band names - allows entry of specific names for each band of an image.
wavelength - lists the center wavelength values of each band in an image. Units
should be the same as those used for the FWHM.
fwhm - lists full-width-half-max values of each band in an image. Units should be the
same as those used for wavelength
bbl - lists the bad band multiplier values of each band in an image, typically zero for
bad bands and one for good bands.
Sensor types specified in the ENVI header file must match an entry in this list
verbatim, including case.
You can edit the Previous Files List by selecting File > Preferences and clicking the
“Previous Files List” button to open the editing window (see “Setting ENVI
Preferences” on page 160).
File : E:\DATA\bldr_reg\bldr4m.img
Bands: 1
Dims : 1-359,1-516
Info : (1,1) {0} [ {0}] {}
File : E:\DATA\bldr_reg\bldr_sp.img
Bands: 1
Dims : 1-1071,1-1390
Info : (1,1) {20} [ {0}] {0.00}
ENVI Spectral
Libraries
This appendix covers the following topics:
General Information
This appendix describes the ENVI spectral libraries that are provided with the ENVI
distribution. The spectral libraries are contained in the SPEC_LIB directory in the
ENVI installation tree. They are also provided in the ENVIDATA/SPEC_LIB
directory on the ENVI Data and Tutorials CD.
The full details of the spectral library and the descriptions of the samples are
available at: http://speclab.cr.usgs.gov/
Hardcopy is also available from the USGS. The reference is given here:
Clark, R.N., G.A. Swayze, A.J. Gallagher, T.V.V. King, and W.M. Calvin, 1993, The
U. S. Geological Survey, Digital Spectral Library: Version 1: 0.2 to 3.0 microns, U.S.
Geological Survey Open File Report 93-592, 1340 pages.
The full details of the spectral library and the descriptions of the samples are
available at: http://speclab.cr.usgs.gov/
Hardcopy is also available from the USGS. The reference is given here:
Clark, R.N., G.A. Swayze, A.J. Gallagher, T.V.V. King, and W.M. Calvin, 1993, The
U. S. Geological Survey, Digital Spectral Library: Version 1: 0.2 to 3.0 microns, U.S.
Geological Survey Open File Report 93-592, 1340 pages.
These spectra were measured at the Center for the Study of Earth from Space (CSES)
at the University of Colorado on a custom modified Beckman 5270 dual beam
spectrometer. This spectrometer was under direct computer control measuring
reflectance spectra at constant high resolution (3.8 nm) sampled at 1.0 nm intervals
throughout the 0.7 to 2.5 µm range. A tungsten light source was used and HALON
was the reference material. The reference and sample spectra were collected
simultaneously and ratioed in real time.
The following is reproduced verbatim from the README file provided by JHU with
the data:
With the exception of man-made materials, all spectra in the Johns Hopkins
Library were measured under the direction of John W. Salisbury. Most
measurements were made by Dana M. D'Aria, either at Johns Hopkins
University in Baltimore, MD, or at the U.S. Geological Survey in Reston, VA.
This text is a general introduction to the library, with an overview of
measurement techniques, which do differ for different materials. There is a
separate introductory text for each kind of material (rocks, minerals, lunar
soils, terrestrial soils, meteorites, etc.) that contains more detailed information.
Two different kinds of spectral data are resident in this library. Spectra of
minerals and meteorites were measured in bidirectional (actually biconical)
reflectance (see two Salisbury et al., 1991 references below for details). These
spectra, recorded from 2.08-25 micrometers, cannot be used to quantitatively
predict emissivity because only hemispherical reflectance can be used in this
way. However, when recorded properly, as described in the meteorite paper,
curve shape is accurate and can be used for remote sensing applications.
All other spectral data, with the exception of portions of generic snow and
vegetation spectra (see the introductory text for each type of material), were
measured in directional hemispherical reflectance. Under most conditions, the
infrared portion of these data can be used to calculate emissivity using
Kirchhoff's Law (E=1-R), which has been verified by both laboratory and field
measurements (Salisbury et al., 1994; Korb et al., 1996). The unusual
circumstances (e.g., the lunar environment) where thermal gradients may
cause significant departure from Kirchhoffian behavior are discussed in
Salisbury et al., 1994.
Spectra from the Beckman and the FTIR instruments were compared in the
overlap range of 2.08-2.5 micrometers. If the difference was greater than 3
percent, measurements were repeated. Typically, however, the agreement was
within the 3 percent limit. In view of the greater accuracy of the FTIR
measurements, any small discrepancy between the two spectral segments was
resolved by adjusting the Beckman data to fit the reflectance level of the
segment measured by the FTIR instruments.
REFERENCES
Korb, A. R., Dybwad, P., Wadsworth, W., and Salisbury, J. W., 1996, Portable FTIR
spectrometer for field measurements of radiance and emissivity: Applied Optics, v.
35, pp. 1679-1692.
Salisbury, J. W., D'Aria, D. M., and Jarosevich, E., 1991a, Midinfrared (2.5-13.5
micrometers) reflectance spectra of powdered stony meteorites: Icarus, v. 92, pp. 280-
297.
Salisbury, J. W., Wald, A., and D'Aria, D. M., 1994, Thermal-infrared remote sensing
and Kirchhoff's law 1. Laboratory measurements: Jour. of Geophysical Research, v.
99, pp. 11,897-11,911.
Salisbury, J. W., Walter, L. S., Vergo, N., and D'Aria, D. M., 1991b, Infrared (2.1- 25
micrometers) Spectra of Minerals: Johns Hopkins University Press, 294 p.
ENVI Map
Projections
This appendix covers the following topics:
Map Projections
Use map projections to represent all or part of the 3-dimensional surface of the earth
in 2-dimensions. Distortion always occurs when projecting a spherical surface onto a
planar map and different projections cause different map characteristics to be
distorted. You must choose the projection that shows the characteristics important to
your goals accurately at the expense of other characteristics, which will be distorted.
Map projections can have properties such as equal area, conformal, equidistant, or
true azimuth (direction) characteristics. On an equal area map projection, circles of a
fixed diameter drawn on any part of the map will encompass the same geographic
area. This projection is useful for comparing land areas. However, the shapes, angles,
and scales of equal area maps may be distorted. On a conformal map projection (e.g.,
UTM), the local angles are correct and the local scale in every direction is constant
showing the true shape correctly. This projection is useful for measuring distance and
direction between relatively near points. An equidistant map projection has a true
accurate scale between one or two points and every other point on the map. Reference
lines are called standard parallels or standard meridians. True direction map
projections show the correct directions or azimuths among all points on the map.
Many map projections use a compromise between these characteristics to reduce
distortion yet provide accurate measurements for local areas. Several map projections
are designed for specific uses, i.e., air and sea navigation, satellite mapping, etc.
Map projections are typically projected onto one of three types of surface: cylinder,
cone, or plane. These surfaces wrap around or intersect with the globe and then are
“cut” and laid flat to produce a map. Cylindrical projections are made by wrapping a
cylinder around the globe and projecting the surface onto the cylinder. Often, the
cylinder touches the globe at the equator so the meridians of longitude are projected
as equidistant straight lines perpendicular to the equator and the parallels of latitude
are projected parallel to the equator (mathematically spaced). The Mercator
projection is an example of a cylindrical projection. A conical projection is made by
placing a cone over the globe. Often, the apex of the cone is along the polar axis of
the globe and the cone touches the globe at a parallel of latitude. In this case, the
meridians are projected onto the cone as equidistant straight lines and the parallels
are lines around the circumference of the cone that are circular when the map is laid
flat. Planar or azimuthal map projections are produced when a plane is placed tangent
to the globe’s surface. In a polar azimuthal projection, the plane is tangent to one of
the globe’s poles so the meridians are projected as straight lines radiating from the
pole and the parallels are circles centered on the pole. Modifications are often made
to these types of projections and there are other projections that are not constructed in
these ways.
You can easily add or modify map projections in ENVI. You can define your own
parameters for the supported ENVI projection types and select the desired ellipsoid
or datum (see “Building Customized Map Projections” on page 758). You can also
define new projection types by providing the formula used to translate latitude and
longitude coordinates into the new projection coordinates
(see ENVI_CONVERT_PROJECTION_ COORDINATES in the ENVI
Programmer’s Guide).
The map projections available in ENVI are listed in Table D-1. The ENVI projection
number is used when creating map information structures when programming in
ENVI.
ENVI Projection
Projection Name and Description
Number
Alaska Conformal 23
a, b, x0, y0, name
Albers Conical Equal Area 9
a, b, lat0, lon0, x0, y0, sp1, sp2, [datum], name
Arbitrary 0
Azimuthal Equidistant 12
r, lat0, lon0, x0, y0, name
Equidistant Conic A 33
a, b, lat0, lon0, x0, y0, sp1, [datum], name
Equidistant Conic B 34
a, b, lat0, lon0, x0, y0, sp1, sp2, [datum], name
Equirectangular 17
r, lat0, lon0, x0, y0, name
General Vertical Nearside Perspective 15
r, lat0, lon0, x0, y0, height, [datum], name
Geographic 1
Gnomonic 13
r, lat0, lon0, x0, y0, name
ENVI Projection
Projection Name and Description
Number
Hammer 27
r, lon0, x0, y0, name
Hotin Oblique Mercator A 5
a, b, lat0, lat1, lon1, lat2, lon2, x0, y0, k0, [datum],
name
Hotin Oblique Mercator 6
B a, b, lat0, lon0, azimuth, x0, y0, k0, [datum], name
azimuth:azimuth of central line (degrees east of north)
Interrupted Goode 24
r, name
Interrupted Mollweide 26
r, name
Lambert Azimuthal Equal Area (sphere) 36
r, lat0, lon0, x0, y0, [datum], name
Lambert Azimuthal Equal Area 11
a, b, lat0, lon0, x0, y0, [datum], name
Lambert Conformal Conic 4
a, b, lat0, lon0, x0, y0, sp1, sp2, [datum], name
Mercator 20
a, b, lat0, lon0, x0, y0, [datum], name
Miller Cylindrical 18
r, lon0, x0, y0, name
Mollweide 25
r, lon0, x0, y0, name
Oblated Equal Area 30
r, lat0, lon0, x0, y0, shapem, shapen, angle, name
Orthographic 14
r, lat0, lon0, x0, y0, name
ENVI Projection
Projection Name and Description
Number
Polar Stereographic 31
a, b, lat0, lon0, x0, y0, [datum], name
Polyconic 10
a, b, lat0, lon0, x0, y0, [datum], name
Robinson 21
r, lon0, x0, y0, name
Sinusoidal 16
r, lon0, x0, y0, name
Space Oblique Mercator A 22
a, b, sat num, path num, path flag, x0, y0, [datum],
name
Space Oblique Mercator B 32
a, b, sat num, path num, x0, y0, [datum], name
State Plane 8
Stereographic (ellipsoid) 7
a, b, lat0, lon0, x0, y0, k0, [datum], name
Stereographic (sphere) 35
r, lat0, lon0, x0, y0, [datum], name
Transverse Mercator 3
a, b, lat0, lon0, x0, y0, k0, [datum], name
User Defined projection 99
a, b, lat0, lon0, x0, y0, [additional parameters],
[datum], name, user defined projection name
UTM 2
Van der Griten 19
r, lat0, lon0, x0, y0, name
ENVI Projection
Projection Name and Description
Number
Wagner IV 28
r, lon0, x0, y0, name
Wagner VII 29
r, lon0, x0, y0, name
Coordinate Systems
The position of a point on a globe is often represented in spherical coordinates by
degrees of latitude and longitude. The parallels of latitude run east-west and are
formed by 90 equally spaced circles around the globe from the equator to each pole
(north latitudes are positive and south latitudes are negative). The circle at the equator
is at 0 degrees and the numbers increase to the north and south poles which are at 90
degrees each. The meridians of longitude are defined by north-south lines passing
through each pole that intersect the equator at 360 equally spaced intervals. The
meridian that passes through Greenwich, England is defined as 0 degrees and is
called the prime meridian. Degrees of longitude are defined between 0 degrees and
180 degrees east (positive) or west (negative) of the prime meridian. Map projections
are used to represent the latitude and longitude lines on a plan map.
The position of a point on a map is often represented in Cartesian (x, y) rectangular
coordinates. The x-axis coordinates typically increase to the east and the y-axis
coordinates increase to the north. The x and y coordinates are often called “eastings”
and “northings” and the origin may be defined with a “false easting” and “false
northing”. These coordinate grids are often divided into “zones” to reduce distortion.
The Universal Transverse Mercator (UTM) and State Plane projections are examples
of these type of coordinate systems.
Ellipsoids
The shape of the Earth is often represented by an oblate ellipsoid, which is an ellipse
that is rotated about its shorter axis. The ellipsoids are described by two parameters,
the semi-major and semi-minor axes. Reference ellipsoids are used to represent the
shape of the Earth and many are based on surface measurements to give a regional
best fit and not an entire Earth best fit. Therefore, different ellipsoids are often used
for different regions of the Earth.
You can easily add an ellipsoid to ENVI by adding it to the “ellipse.txt” file in the
map_proj directory of the ENVI distribution. To add an ellipsoid, enter the name,
semi-major axis (a) in meters, and semi-minor axis (b) in meters to this file.
The ellipsoids available in ENVI are listed in Table D-2.
Airy IUGG
Australian National Krassovsky
Bessel 1841 Mercury
Clarke 1858 Modified Airy
Clarke 1866 Modified Everest
Clarke 1880 Modified Fischer 1960
Clarke IGN New International
Danish Plessis
Delambre South American 1969
Everest Southeast Asia
Fischer 1960 Struve
Fischer 1968 Walbeck
GRS 67 WGS 60
GRS 80 WGS 66
Helmert 1906 WGS 72
Hough WGS 84
IAU “165”
International
Datums
A datum is a smooth, mathematical surface that closely fits the mean sea level surface
throughout the area of interest. It is created when an ellipsoid model is fixed to a base
point on the Earth. Since the ellipsoid models are approximate, as you move away
from the fixed point you get larger errors. Therefore, different datums exist for
different regional areas to reduce error. Because different datums are defined by
fixing an ellipsoid to different base points, changing datums changes the latitude and
longitude of a point on the surface of the Earth. Therefore, it is necessary to know
which datum is used when defining the coordinates of your points.
ENVI supports many datums which are listed in the “datum.txt” file in the map_proj
directory of the ENVI distribution. Users can easily add a datum to ENVI by adding
it to the datum.txt file. To add a datum, enter the name, associated ellipsoid name
(must be in ENVI’s ellipse.txt file), and the Molodensky x, y, and z shift values
in meters from the WGS-84 datum. See the web pages listed on page 912 for more
information.
Closing Computing
All Displays, 210 AVHRR Sea Surface Temperature, 473
All Files, 159 ROI Spectral Separability, 281
All Plot Windows, 210 Statistics, 427 , 556
Closing Filter, 594 Sun Elevation for Hill Shade, 799
Clump Classes, 541 Confusion Matrix
Collecting Calculating, 530
Endmembers, 495 Example of, 533
Points, 368 Context-Sensitive Help , 27
Color Image from Grayscale, 582 Contingency Matrix, 530
Color Mapping Continuum Removal, 660
Class Color Mapping, 364 Contour Levels Format (.lev), 895
Control RGB Image Planes, 363 Contour Lines
Density Slicing , 358, 359 Exporting to Vector Files, 254
ENVI Color Tables, 358 Output Contours to Vectors, 254
Functions, 358 Plotting on Images, 249
Color Normalized Sharpening, 552 Contrast Stretching
Color Tables Arbitrary Stretch, 325
Applying, 358 Default (Quick) Stretch, 318
System, 163 Defining Look-Up-Tables, 326
Color Transforms File-to-File, 425
Converting Images, 575 Gaussian Stretch, 324
Hue, Lightness, Saturation, 577 Histogram Equalization, 325
Hue, Saturation, Value, 575 Histogram Matching, 325
Munsell, 575, 579 Interactive, 321
colors.txt, 883 Linear Stretch, 323
Combining Piecewise Linear Stretch, 323
Bands, 117 Restoring LUTs, 331
Classes, 543 Saving LUTs, 331
Command Line Square Root, 325
See Also ENVI Command Line, IDL Com- Converting
mand Line ASCII Coordinates, 767
Switches, 32 Band Values to ROIs, 279
Compile Module, 126 Classification to Vector, 781
Complex Data Complex Data, 469
Calculating Images, 469 Data Type
Converting, 469 File-to-File, 425
Display Lookup Function, 110 Stretching, 330
Outputting Images, 469 Map and Lat/Lon, 765
Compressing Output, 55 Raster to Vector, 780
Z
W Z Plot Information, 108
Warping Z Profiles
Delaunay, 714 Extracting, 338
from Existing GCPs, 718 Extracting Additional, 340
Image-to-Image, 702 Zoom Window
Image-to-Map, 710 Changing Indicator Box Color, 218
Options, 714 Controlling Interpolation, 191, 218
Orthorectification, 720 Controlling Zoom Factor, 189
Polynomial, 714 Display, 188
RST, 714 Hiding, 195
Water Vapor Interpolation, 36
Omit from Hyperspectral Data, 102 Mouse Button Functions, 191
Wavelength Output, 405
Editing, 103 Positioning, 194
Locating, 181 Resizing, 188