Generates statistics about a HiRISE cube and ancillary data
Overview
Parameters
Example 1
Example 2
Description
This program computes statistics about the HiRISE image and it's
associated ancillary data including the calibration image,
dark reference pixels, and buffer pixels. There are ten sets
of statistics that will be produced using:
1) Lines postramp, the first 30 lines of image data
1) Remaining lines of image data
2) Image dark reference pixels (16 pixels per line)
3) Image buffer pixels (12 pixels per line)
4) Calibration image dark reference pixels (16 pixels per line)
5) The calibration image buffer pixels (12 pixels per line)
6) Calibration image reverse lines (First 20 lines of calibration image)
7) Calibration masked lines (From 5 - 20 lines after reverse depending on TDI)
8) Calibration ramp(Remaining lines after masked lines)
The following statistics for each data set will be produced:
Average
Standard deviation
Variance
Minimum
Maximum
Total pixels
Valid pixels
Null pixels
Low instrument saturation pixels
Low representation saturation pixels
High instrument saturation pixels
High representation saturation pixels
The statistics will be output to the print file and additionally, if the user specifies, a file using the
TO parameter, the statistics will be written to the file in a standard PVL format which can then be read using
the getkey program. Because the very edges of several parts of the image are
often inaccurate, histat also has the ability to disregard some pixels.
The first and last line of the calibration image is not regarded, nor are the
first and last samples of any line in the calibration image. For this reason,
an image with a calibration image of 62 lines by 512 samples will be broken
down as follows:
Last 19 lines of the reverse readout pixels (all but the first)
All 6 (in this case) lines of the masked pixels
First 33 lines of the ramp pixels (all but the last)
Since the first and last samples of each of these lines is disregarded
automatically, the user is left statistics for the three sections of a
60 line by 510 sample calbration image.
The user is given much more flexibility in excluding samples from the
calibration and dark reference areas of the actual (not calibration)
image. The specific parameters used are described in the "Parameters"
section.
Fixed reporting of special pixels within the HiRISE tables. Special pixels were
not being converted from 16 bit signed word to 32 bit double values before
being sent to the Statistics objects.
Drew Davidson
2006-01-18
Added the ability to use offsets so that edges of the calibration data may
be disregarded.
Drew Davidson
2006-01-23
Seperated calibration image into reverse, masked, and ramp groups.
Drew Davidson
2006-05-25
Changed the default offsets, keywords, and internal offsets, Also added
the CAL_DARK_RAMP group and the IMAGE_POSTRAMP group
Stuart Sides
2006-10-06
Fixed bug where the number of mask lines was calculated. This also
effected the number of ramp lines.
Stuart Sides
2006-10-06
Modified brief and full descriptions of the keywords for ignoring left and
right edges of the different calibration and main image portions of the
observation to eliminate identical descriptions.
Kris Becker
2007-01-18
Merged the changes made by Drew Davidson with the USGS version
to provide single source code management. Changed how the data
is recorded. When a TO file is given output is not written to the terminal
or the log file. If TO is not given, output is written to the terminal and
the log file (default: print.prt).
This ascii file will contain the statistics of the various HiRISE components.
It is written in such a format that the values can be read using the getkey program.
This is useful for when developing
scripts.
In this example we disregard the ability to use offsets on the buffers.
Since the default is to include offset values, we must explicitly set
useoffsets
to false.
GUI Screenshot
histat Gui
Example Gui
Screenshot of GUI with parameters set to gather stats without offsets.
Input Image
Input image
HiRISE input image for histat
Parameter Name:
FROM
This is the input image for which we will gather statistics. Note that it has
been run through higlob so that the buffers and ramp are part of the image.
This is the output file from running histats without any offsets.
Example 2
Default offsets
Description
This example gathers only the center 12 pixels from the dark current
area (both calibration and actual image), the center 8 pixels from
the buffer area (both calibration and actual image), and all of the data
from what is considered to be the normal, viewable image.
Command Line
histat from=histatExample.cub > histatOut.log
Note that we are redirecting standard output from the command line. If
no "TO" file is specified, histat statistics will go to standard output,
a feature we are taking advantage of here.
GUI Screenshot
histat Gui
Example Gui
Screenshot of GUI with parameters set to gather
statistics not including the 2 outermost columns of dark current and
buffer pixels.
Input Image
Input image
HiRISE input image for histat
Parameter Name:
FROM
This is the input image for which we will gather statistics.