Isis 3 Application Documentation
Creates cubes that have slope data or aspect data
Description
This program will compute the slope or aspect of a cube. Typically a digital terrain model with DN
values representing the radius of a target body is
given as the input but other non-radius datasets can be provided. Horne's algorithm is used
to compute the slope or aspect. A 3x3 kernel:
A B C
D E F
G H I
is convolved through the image and each output pixel is computed as follows:
SLOPE EQUATION
[dz/dx] = ((C + 2F + I) - (A + 2D + G)) / (8 * X_PIXEL_RESOLUTION)
[dz/dy] = ((G + 2H + I) - (A + 2B + C)) / (8 * Y_PIXEL_RESOLUTION)
slope = ATAN ( SQRT ( [dz/dx]^2 + [dz/dy]^2 ) )
percentslope = slope / 90
ASPECT EQUATION
[dz/dx] = ((C + 2F + I) - (A + 2D + G)) / 8
[dz/dy] = ((G + 2H + I) - (A + 2B + C)) / 8
aspect = 90 - ATAN2 ([dz/dy], -[dz/dx])
if (aspect < 0) then aspect = aspect + 360
Slope is typically betwen 0 and 90 degrees, flat to vertical slope,
respectively. The aspect represents the direction (0 to 360) of the slope in pixel space.
From the center pixel (E), 0 degrees is straight towards B, 45 is towards C, 90 is towards F,
135 is towards I, 180 is towards H, and so on. The may choose to output the slope in
radians, degrees, or percent slope, the aspect in degrees or radians.
The slope equation above assumes the pixels are not square: hence X_PIXEL_RESOLUTION and
Y_PIXEL_RESOLUTION. That is, the x distance across the pixel is not equal to the y distance
from top to the bottom of the pixel. By default the program will attempt to remove any
scaling differences by using the map projection information (PIXRES=AUTOMATIC). This
computation is done at every pixel so the correct x-to-y ratio is computed. This
is important for global maps where the x/y ratio deviates with distance from the latitude
and/or longitude of true scale in the map projection. If the image lacks a map projection
then the user must provide the pixel resolution via PIXRES=USER. For this option the pixels are
assumed to be square.
The user then provides a single value (RESOLUTION) that will be applied to all pixels in the
image and in both directions.
The second assumption is the xy units are the same as the z (pixel) units. By default
the program assumes the units are the same, but allows the user to scale the z units to the xy
units using the CONVERSIONFACTOR parameter if the PIXRES=USER option is being used.
Categories
History
Brian Peck | 2006-12-25 |
Original version
|
Steven Lambright | 2008-10-06 |
Changed slope and aspect algorithms
|
Jeff Anderson | 2012-08-02 |
Changed the slope algorithm to compute the sample and line resolution
at each pixel. Previously the algorithm used the resolution at the
center of the image. In projected images the resolution varies as you
move away from the latitude and/or longitude of true scale. Also, improved the
documentation and added user options to output percent slope.
|
Stuart Sides | 2013-01-30 |
Backward Compatibility Issue: Changed the default output to be slope rather than percent
slope.
Backward Compatibility Issue: Removed ability to supply a conversion factor when using
the automatic resolution option (CONVERSION=AUTOMATIC). AUTOMATIC, assumes the DNs in
the cube have units of meters.
Added a test to the CONVERSION=AUTOMATIC option so DNs in the cube with negative values
will cause a better error to be shown. Added a BANDBIN group to the output cube labels.
|
|
Parameter Groups
Files
Name
|
Description
|
FROM |
Input cube
|
TO |
Output cube
|
Output Options
Name
|
Description
|
OUTPUT | Type of output requested, slope, aspect, or percent slope |
UNITS | Units of the output image |
Scaling Options
Name
|
Description
|
PIXRES | Defines the pixel resolution (width and height) |
CONVERSION | Conversion from z units to spatial units |
RESOLUTION | Pixel resolution |
|
Files:
FROM
Description
Use this parameter to select the input cube. All bands of the cube within the file
will have the algorithm applied.
Type
| cube |
File Mode
| input |
Filter
|
*.cub
|
Files:
TO
Description
Use this parameter to define the filename of the resultant slope or aspect cube
Type
| cube |
File Mode
| output |
Pixel Type
| real |
Output Options:
OUTPUT
Description
This determines the type of output pixels that will be created. The output file will
contain either slope, aspect, or, percent slope.
Type
| string |
Default
| SLOPE |
Option List:
|
Option |
Brief |
Description |
SLOPE | Create slope cube |
This creates a slope cube.
|
ASPECT | Create aspect cube |
This creates an aspect cube. That is, the direction/azimuth of the slope.
Exclusions
- PIXRES
- RESOLUTION
- CONVERSION
|
PERCENTSLOPE | Create percent slope cube |
This creates a slope cube whose pixel values are percentages (slope/90) instead of
angles.
Exclusions
|
|
Output Options:
UNITS
Description
Units of the output pixels
Type
| string |
Default
| DEGREES |
Option List:
|
Option |
Brief |
Description |
RADIANS | Output pixels in radians |
The output pixels will be in radians, between 0 and PI/2 for slope and 0 and
2PI for aspect.
|
DEGREES | Output pixels in degrees |
The output pixels will be in degrees, between 0 and 90 for slope and 0 and 360
for aspect.
|
|
Scaling Options:
PIXRES
Description
This determines how the resolution of the input pixels will be defined.
Type
| string |
Default
| AUTOMATIC |
Option List:
|
Option |
Brief |
Description |
AUTOMATIC | Automatically compute the resolution using the map projection |
The program will use the map projection to automatically compute the resolution
(X and Y) of each pixel in order to ensure the slope is computed properly.
Exclusions
|
USER | User defined pixel resolution |
If the input cube does not have a map projection this option can be used to
define the resolution which is assumed to be square. A single resolution is used
for the entire image in both the X and Y directions. Note: If the pixel height
varies significantly from the width, the slope will not be computed correctly.
|
|
Scaling Options:
CONVERSION
Description
Since the slope algorithm depends on cancelling out the units, the
conversion factor from the z vertical (input pixel) units to the xy horizontal (spatial)
units needs to be considered.
For example, if the
xy units are in meters and the z units are in kilometers the unit conversion factor
should be 1000 as we are converting z kilometers to xy meters.
The default presumes the units are the same.
Scaling Options:
RESOLUTION
Description
Defines both the X and Y pixel resolution to be used across the entire image. Note that
if the pixel height varies significantly from the width, the slope will not be computed
correctly.