Level 2 Help for FASTMOS

SIZE

If the SIZE field is not entered, the output image has the same size as the
first input image.  If the SIZE field is entered, the number of lines and
number of samples refer to the size of the output image.  The starting line
and starting sample are ignored.


NB

Number of bands.


MMODE

The mosaicking mode specifies how the output data number values are determined 
from the input data numbers.   The following rules apply for each of the 
modes.  If none of the input images have a data number value for a 
given pixel that is greater than the THRESH value, the 
output data number is the data number from the first input image if 
the pixel is contained in the first input image, and the output 
data number is L0 if the pixel is not contained in the first input image, where
L0 is 0 if THRESH is greater than 0, L0 is 0 if THRESH=0 and the data format 
is byte, and L0 is equal to THRESH otherwise, for integer data.  For real*4
data, L0 is -1.0E10.
If exactly one of the input images has a data number value for a given pixel that
is greater than the THRESH value, the output data number is the
data number from the one input image.  If more than one of the input images
have a data number value for a given pixel that is greater than the
THRESH value, the output data number is determined by the mosaicking mode. 

There are currently five modes to choose from.  They are listed by name below.
For each mode a description is given of how the output data number is 
determined when there is more than one input image having a data number value 
that is greater than the THRESH value for a given pixel.  The
default mode is OVERLAY.

OVERLAY  - The input images are checked against the THRESH value in the order
           in which they are entered by the user.  The first data number value
           found which meets the threshold criteria is used for the output
           image.  This means that the order in which the input files are 
           entered gives a priority to the data in the files.

AVERAGE  - The average of the values meeting the threshold criteria is used.
           The average is found by integer division with no rounding.

MOD      - When there are two values meeting the threshold criteria, the 
           average of the values is used.  When there are more than two 
           values meeting the threshold criteria, the value closest to the
           average is used.  This mode may be particularly useful when
           combining many images with high bit-error rates.

MAX      - The maximum of the values meeting the threshold criteria is used.

MIN      - The minimum of the values meeting the threshold criteria is used.


THRESH

Only values greater than the THRESH threshold parameter are used
by the mosaicking mode in determining the data numbers for the output image.
The THRESH value is usually greater than 0 for mosaicking.  THRESH can be
set to 0 for cases such as averaging images.  The default value is 1.
(See Example 5 in the main help for details about the case of THRESH=0
for byte data.  Users may need to convert images to halfword to use THRESH=0
for mosaicking.  Other VICAR programs, such as INSECT may be an alternative.)

For halfword images for which negative DNs are considered valid, a negative
THRESH value may be used.  In this case, 0 is an inappropriate value for
representing the absence of image data.  When THRESH is less than 0, FASTMOS
uses an output DN of THRESH-1 to represent the absence of image data.
(If THRESH = -32768, -32768 is used to represent the absence of image data.)
This value is used as an output DN where the output pixel does not lie in one
of the input images.  (See the MMODE parameter.)


PROGRESS

If the PROGRESS parameter is specified, FASTMOS prints the percentage done
(in generating the output image) every 10% from 10 to 90%.
The default is to not print the progress.


EDGE

If the EDGE parameter is specified, all input images are edged prior to
applying the mosaicking mode. No edging is the default.  'EDGE M U S T
be specified to invoke the edging algorithm.

If edging is selected, then each line of each input image is edged first on the
left and then on the right.  Edging means scanning through a line from one
end or another to the point at which the data numbers are greater than
a threshold value and then removing the pixels from the end of
the line up to a certain number of pixels beyond the point.  This is 
referred to as finding the edge of the scene data and nibbling in a 
certain number of pixels beyond the edge.  Because of the line by 
line processing performed by the program, edging is only available
in the horizontal direction.  (Edging the top and bottom of images would
normally require an intermediate data set.)  Edging is typically used
to remove distortion around the edges of pictures that was caused by
interpolation, filtering, or other things.

Several parameters are used to control the way that edging is done.  The 
parameters NTHRESH, LTHRESH, RTHRESH, NSEQ, and NINCR determine the location
of the edge of the scene data for lines of the input images.  The parameters
NIBBLE, LNIBBLE, and RNIBBLE determine how many pixels beyond the edge of 
the scene data are removed.

The edge of the scene data for a line is determined as follows.  The program
scans through the pixels of a line comparing the data numbers against the
edging threshold.  (Separate edging thresholds can be specified for scanning
from the left and scanning from the right using the LTHRESH and RTHRESH
parameters.  The NTHRESH parameter can be used to specify the same threshold
for scanning from the left and scanning from the right.)  The scanning begins
at one end of the line, and it checks successive pixels unless the NINCR
parameter is entered.  If NINCR is entered, the scanning checks only every
NINCRth pixel.  The program scans until it finds a group of NSEQ consecutive
(in terms of NINCR) pixels all of which have a data number greater than
the edging threshold.  The edge of the scene data is defined as the
first pixel (according to the direction of the scan) of that group.

The nibbling number is the number of pixels, starting with the edge of the
scene data, which are to be removed along with any pixels from the end of
the line to the edge of the scene data.  (If the nibbling number is zero, 
then just the pixels from the end of the line to the edge of the scene data
are removed.)  Separate nibbling numbers can be specified for scanning from 
the left and scanning from the right using the LNIBBLE and RNIBBLE parameters.
The NIBBLE parameter can be used to specify the same nibbling number for 
scanning from the left and scanning from the right.  

If no edge of the scene data is found when scanning, the entire line is 
removed.


NTHRESH

The default for NTHRESH is THRESH.  (See also under EDGE.)


LTHRESH

The default for LTHRESH is NTHRESH.  (See also under EDGE.)


RTHRESH

The default for RTHRESH is NTHRESH.  (See also under EDGE.)


NSEQ

The default for NSEQ is 8.  (See also under EDGE.)


NIBBLE

The default for NIBBLE is 4.  (See also under EDGE.)


LNIBBLE

The default for LNIBBLE is 4.  (See also under EDGE.)


RNIBBLE

The default for RNIBBLE is 4.  (See also under EDGE.)


NINCR

The default for NINCR is 1.  (See also under EDGE.)


OFF1

Either two or four values may be entered for OFF1.  The first two values
give the line and pixel numbers, respectively, of the upper left hand corner
of the first input image file with respect to the output image. 
If the upper left hand corner of the input image is not within the 
boundaries of the output image, the location of the input image is given
by extending the numbering of lines and pixels beyond the boundaries of the
output image.  Thus negative numbers or zero would be used for the locations
of input images beginning to the left or above the boundaries of the output
image.  The default for the first two values is line 1 and pixel 1.  (The
default assumes that the input image was pre-registered.)

If entered, the third and fourth values give, respectively, the number of lines
and number of pixels per line to be used from the image.  This is used when
not all of the image is to be used in the program.  The default is to use all
of the lines and samples as specified in the VICAR label.


OFF2

(See under OFF1.)


OFF3

(See under OFF1.)


OFF4

(See under OFF1.)


OFF5

(See under OFF1.)


OFF6

(See under OFF1.)


OFF7

(See under OFF1.)


OFF8

(See under OFF1.)


OFF9

(See under OFF1.)