MSH -- Mag Tape Source Header Listing

Reads a specified source header on magnetic tape and generates a report.

See Also: MAGREP, MBUREP, CDSH

PARAMETERS

MSH is controlled by the following global parameters:

Name     Prompt                                  Count     Type
STARTFIL Start File on Tape                      0-1       Int
REPORT   Report mode: TERM/OFF/filename          0-64      Char

The following parameters receive output:

MTSH     Mag Tape Source Header Type             1-8       Char
MTCH     Mag Tape Characteristics                3         Int
For LGSOWG CD the program CDSH can be used to read the source header.

STARTFIL

Specifies the start file number on tape from which to start reading header data. If STARTFIL is greater than one, the program rewinds the tape and advances to the specified file.

 EASI>STARTFIL=n        | read nth header file on tape
 EASI>STARTFIL=         | defaults to 1
For JSC (CCRS) tapes, STARTFIL must be set to 3n-2, where `n' is the file number. For example, to read file 3 of a JSC tape, set STARTFIL=7. STARTFIL must be set to either 1, 3, or 5 for NOPS tapes. STARTFIL must always be set to 1 for EOSAT Fast format tapes.

REPORT

Specifies the file to which the generated report is appended.

 EASI>REPORT="filename"
 EASI>REPORT=           | defaults to terminal output
The following names have special meaning:

 EASI>REPORT="TERM"     | generates reports on your terminal
 EASI>REPORT="DISK"     | generates reports on file "IMPRPT.LST"
 EASI>REPORT="OFF"      | usually cancels report generation, but
                        | MSH forces REPORT to terminal output

MTSH

MSH writes an 8-character descriptor of the format found on tape to the output parameter MTSH. This parameter can be used by procedures and users to determine which programs to use to read the tape.

The following table lists tape reading programs, for each possible value for MTSH.

 MTSH value  Programs       Description of tape format

  "PCI"       MAGRD         PCI database interchange format
  "LGSOWG"    MIL,MVL       8-bit or 16-bit LGSOWG or CEOS format
  "NOAA8"     MIT,MVT       8-bit AES TIROS/NOAA (AVHRR) format
  "NOAA10"    MIN10,MVN10   10-bit AES NOAA (AVHRR) format
              MINAES        10-bit AES TeraScan (HRPT) format
  "LAC"       MINLAC        10-bit NOAA LAC or GAC format
  "NOPS"      MIZ,MVZ       8-bit NOPS NIMBUS-7 (CZCS) format
  "EOSAT"     MIEOSAT       8-bit EOSAT Fast format
  "WIPS"      MIW,MVW       8-bit WIPS format
  "GOES"      MIG,MVG       8-bit GOES/VISSR format
  "JSC"       MIC,MVC       8-bit JSC CCRS LANDSAT format OR
              MIS           16-bit JSC CCRS SEASAT format
  "NRSA"      MIMSS         8-bit NRSA MSS format OR
              MIMET         8-bit NRSA METSAT format
  "PCIOLD"    MIH,MVH       8-bit old PCI image format
  "GARS"      MIGARS        8-bit or 16-bit unsign GARS format 
  "JPL-CM5"   DIJPL         JPL Compressed Stokes Matrix, version-5
  "JPL-CM"    MIJPL         JPL Compressed Stokes Matrix
  "JPL-HR"    MIJPL         JPL High-Res (Complex Scattering Matrix)
  "JPL-CH"    MIJPL         JPL Compressed Scattering Matrix (4 strips)
  "JPL-CS"    MIJPL         JPL Compressed Scattering Matrix (4 images)
  "JPL-UN"    MIJPL         JPL Polarimetric, but otherwise unknown.
  "UNKNOWN"   If band sequential format, try MIB,MVB programs.

MTCH

MSH sets the first three values of the tape characteristics parameter (MTCH) to the number of pixels per line, number of lines per band, and number of bands on tape. The values put in MTCH can be used by automated tape reading procedures.

DETAILS

MSH reads the tape source header at a specified file (STARTFIL) on a tape mounted on a tape drive. The tape header data is formatted and listed on the selected report device (REPORT). This program allows users to examine tape headers, to determine what is stored on tape before deciding whether to transfer image data from tape to disk or display.

MSH automatically determines the tape format type (if it is a format supported by EASI/PACE), prints the header, and saves the tape format type string in the output parameter MTSH. MSH also saves the number of pixels, number of lines, and number of bands on tape in the output parameter MTCH.

NOTE: MSH CANNOT READ HEADERS OF R-STREAM DIPIX BU FORMAT TAPES. USE THE MBUREP PROGRAM TO READ DIPIX BU TAPE HEADERS. If a Dipix BU tape is mounted and MSH is run, it will interpret the header as if it were a 512-byte header of a PCI image tape; garbage data values will print as a result.

EXAMPLE

Run MSH to determine the tape format of a mounted tape.

 EASI>REPORT=
 EASI>STARTFIL=1
 EASI>RUN MSH
Use the MTCH parameters, set by MSH, to specify the size of a new database file, to be created by the CIM program.

 EASI>DBSZ=MTCH(1),MTCH(2)
 EASI>DBNC=MTCH(3)
 EASI>FILE="lgsowg.pix"
 EASI>RUN CIM
If the tape is a LGSOWG format tape (MTSH="LGSOWG"), then run MIL to read the image from tape.

 EASI>MTIC=1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16
 EASI>MTIC(MTCH(3)+1)=
 EASI>DBOC=MTIC
 EASI>MTIW=
 EASI>DBOW=
 EASI>IF (MTSH="LGSOWG") RUN MIL
The TM image on the training data set PCIDSK file, irvine.pix, is a subset of the image which was read from a LGSOWG BIL format tape, using the MIL program. The tape label has the following information:

 EROS Data Center
 Thematic Mapper
 Corrected BIL TM Quad 1
 Path: 040    Row: 037
 Acquisition Date: 20-May-89
 Scene ID:         Y5190617505X0
MSH was run to print a tape header report for this tape:

 EASI>STARTFIL=1
 EASI>REPORT=
 EASI>RUN MSH
The first page of the report lists volume descriptor information:

 MSH     Mag Tape Source Header     V5.2 EASI/PACE  13:21 16-Jul-93

 LGSOWG Volume Descriptor

 Control Document Number      CCB-CCT-0002 D A
 Software Release Number      APPL_7.0F_SY
 Physical Volume ID           L5TCP9007255    
 Logical Volume ID            L5TCP9007255    
 Volume Set ID                                

 Number of Tapes in Set       1
 Start of Logical Volume      1      End of Logical Volume        1
 Current Tape Volume          1      First File on Volume         1
 Logical Volume in Set        1      Logical Volume in Tape       1

 Creation Date-Time           19900313-16033430
 Generating Country           USA         
 Generating Agency            NOAAGSFC
 Generating Facility          TIPS 2
The second page of the report lists imagery file information:

 LGSOWG Imagery File Descriptor

 Number of image records                                   20881
 Image record length                                        4320
 Number of bits per pixel                                      8
 Number of pixels per data group                               1
 Number of bytes per data group                                1
 Justification and order of pixels in data group            RJLR
 Number of images (bands)                                      7
 Number of lines per image (one band)                       2983
 Number of left border pixels per line                         0
 Number of image pixels allocated per line per band         4220
 Number of right border pixels per line                        0
 Number of top border lines                                    0
 Number of bottom border lines                                 0
 Interleaving indicator                                     BIL 
 Number of physical records per line                           1
 Number of physical records per multispectral line             7
 Number of bytes of prefix data                               20
 Number of bytes of image data per record                   4220
 Number of bytes of suffix data per record                    68
 Prefix/Suffix repeat flag
After MSH is completed, the MTCH and MTSH parameters have the following values:

 EASI>SEE MTCH

 MTCH    - Mag Tape Characteristics        >   4220   2983     7

 EASI>SEE MTSH

 MTSH    - Mag Tape Source Header Type     :LGSOWG
This indicates that the tape contains a LGSOWG format image which has 4220 pixels per line, 2983 lines per band, and 7 bands.


About PCI Help Gateway