lac - Creates AVHRR datasets from LAC tapes.

SYNOPSIS

lac  [ parameter=value ... ]  [ outputfile ... ]
lac  [ parameter=value ... ]  [ directory ]

Parameters are: first_file, num_files, tape_device, use_master, master_file, start_time, delta_line, num_lines, start_sample, delta_sample, num_samples, channels, calibrate, temp_units, zero_sync, tbm_header, packed_fmt, in_channels.

DESCRIPTION

lac creates TeraScan datasets from Environmental Data Information Service (EDIS) Local Area Coverage (LAC) tapes. Tapes containing 1, 2, 3, or 5 channel data are supported; 5 channel packed LAC tapes with missing headers are also supported.

lac can also read LAC data from a disk file.

Multiple telemetry frames on a single tape can be processed in succession with this function. The user can specify one or more channels to extract. Subsampling can be specified if full resolution data is unnecessary.

A spatial subset can be specified in one of two ways:

1) the smallest rectangular area required to cover a master dataset. 2) a rectangular area of specific size beginning at a specified time and scan sample.

Data can be left as raw counts or converted to radiances or brightness temperatures. If the output is raw counts, the hrpt header records are stored in the dataset along with the counts. If the data are converted to radiances or temperatures, the header information is not retained.

There are no input data sets. The sources for the input pass data were described above. Multiple output TeraScan datasets are supported. Output is either to a user supplied directory or a user supplied list of dataset names. If a directory name is entered, output dataset names will automatically be generated and the output files written to the specified directory. The format of the output file names is n#.yyddd.hhmm, where # is the NOAA satellite number, yyddd is the julian date, and hhmm is the start hour and minute.

PARAMETERS

first_file

This is the number of the pass on tape with which processing will begin. This number is relative to the current position of the tape. For example, if the tape is positioned at the beginning of the tape and the user specifies first_file=2; the second pass on the tape will be processed. If the tape is positioned at the third pass on the tape and first_file=1; the third pass will be processed or if first_file=2 the fourth pass will be processed.

Valid range [>=1]. The default is 1.

num_files

This is number of consecutive passes to process when the outputfile specified to go to a directory.

Valid range is [>=1]. The default is 1.

tape_device

This is the name of the input tape device. Tape device names are machine specific.

Valid responses for lac on the Sun SPARC Station:

/dev/nrwd0	4mm DAT, variable blocking
/dev/nrsx0	8mm, variable blocking
/dev/nrmt0	12" tape

The default is extracted from the UNIX environment variable TAPE and may not be appropriate.

tbm_header

This indicates whether or not the input LAC data is preceded by the NOAA/NESDIS TBM header. Valid responses are [yes, no]. The default is yes.

zero_sync

OPTIONAL. This indicates whether or not the 6-word HRPT sync code has been zero'd out. lac uses the sync code as a quality indicator for the 103-word HRPT header. If zero_sync=yes, lac compares the sync pattern in the input data against an all-zero pattern. Valid responses are [yes, no]. The default is no.


packed_fmt

This indicates whether or not the input LAC data is packed. If the data is packed, 3 10-bit AVHRR image values are stored in 4 input bytes. If the data is unpacked, each 10-bit AVHRR image value is stored in 2 input bytes. If tbm_header=no, the input LAC data is assumed to be packed; the packed_fmt parameter is not used.

Valid responses are [yes, no]. The default is yes.

in_channels

Indicates which AVHRR channels are present in the input LAC data. If the input data is packed, all five channels are assumed to be present, and the in_channels parameter is not used. Valid responses are lists of numbers in the range [1, 5]. The default is 1 2 3 4 5

use_master

Answer yes if the data is to be selected from the intersection of a master dataset (number 1 in the description above, also see master). Answer no if subsets are to be specified by start time and sample (number 2 in description above).

Valid responses are [yes or no]. The default is yes.

master_file

If use_master=yes, then this is the name of the master dataset used to specify a region for data extraction (see master).

Valid responses are any TeraScan dataset that contains an earth transform. The default is Master.

start_time

If use_master=no, then this is the start time for data extraction. The first line with a time greater than start_time is the first output line. A response of 00:00:00 instructs lac to begin processing at the first scan line.

Any valid time is allowed (see formats). The default is 00:00:00.

delta_line

This specifies the rate of subsampling in the direction of subtrack. If delta_line=3 every third line will be used. If delta_line=1, all lines will be used.

Valid responses are [1,2,3,4]. The default is 1.

num_lines

If use_master=no, then this is the number of lines written to the output dataset. delta_line * num_lines input lines will be processed to produce an output dataset containing num_lines. If the end of pass is detected before the output dataset is complete, the output dataset is truncated.

The valid range is [>=1]. The default is 700.

start_sample

If use_master=no, then this is the first sample to extract from the pass. Samples are numbered starting with 1.

The valid range is [1 to 2048]. The default is 1.

delta_sample

This specifies the rate of subsampling in the scan direction. If delta_sample=3, every third sample will be used. If delta_sample=1, all samples will be used.

Valid responses are [1,2,3,4]. The default is [1].

num_samples

This is the number of samples written to the output dataset. delta_sample * num_samples input samples will be processed to produce an output dataset containing num_samples. If the edge of the pass is detected before the output dataset is complete, the output dataset is truncated.

The valid range is [>=1, num_samples * delta_sample <= 2048]. The default is 800.

channels

This is a list of the AVHRR channels to extract from the HRPT pass. The five channels correspond to 0.6-0.7, 0.7-1.1, 3.5-3.9, 10.3-11.3, and 11.5-12.5 micrometers.

Valid responses are [1,2,3,4,5]. The default is 1,2,3,4,5.

calibrate

Answer yes to convert raw sensor counts to radiance or temperature using EDIS provided transforms. Answer no if raw count data is desired. Raw data can subsequently be calibrated and converted using the avcal function.

Channels 1 and 2 are converted to radiance, with units 100*albedo. Channels 3, 4, and 5 are converted to brightness temperatures with units of Celsius, Kelvin or Fahrenheit.

Valid responses are [yes or no]. The default is no.

temp_units

If calibrate=yes, it is necessary to specify the temperature units. Temperature units can be degrees celsius, kelvin, and fahrenheit.

Valid values are [ celsius, kelvin, fahrenheit]. The default is celsius.

EXAMPLES

The following example reads AVHRR channels 2 and 4 from a disk  file containing   LAC data.  The HRPT sync code in the  input LAC data has been zero'd out, requiring zero_sync=yes.


     % lac zero_sync=yes /tmp/testout
     tape_device    : char(255) ? a14_tms_960315_0903.l1b
     tbm_header     : char(  3) ? [yes]
     packed_fmt     : char(  3) ? [yes]
     use_master     : char(  3) ? [yes] n
     start_time     : char( 15) ? [00:00:00]
     delta_line     : int       ? [1]
     num_lines      : int       ? [5500]
     start_sample   : int       ? [1]
     delta_sample   : int       ? [1]
     num_samples    : int       ? [2048]
     channels       : int (  5) ? [1 2 3 4 5] 2 4
     calibrate      : char(  3) ? [no]
     Processing tape file 1
     /tmp/testout starts at time 09:03:08.306, sample 1.
     Actual size is 4283 lines by 2048 samples.


SEE ALSO

gac, avin, avcal, master, etx, formats, avhrr

NOTES

Only AVHRR data is available on EDIS LAC or GAC tapes. Due to an unfortunate decision by EDIS, the TIP header data has been removed, thus negating the possibility of ingesting TOVS or DCS data from LAC or GAC tapes.