User's Guide

CCTTIPSP

Reads the P-type Thematic Mapper (TM) scenes that are recorded as quadrants on four nine-track 6250 bpi magnetic tapes in BSQ or BIL format.

Function:

Reads the P-type Thematic Mapper (TM) scenes that are recorded as quadrants on four nine-track 6250 bpi magnetic tapes in band sequential (BSQ) or band interleaved by line (BIL) format. If no window is specified, the user is given the option to have the specified quadrants mosaicked into one output LAS image or to have each quadrant output as a separate LAS image. If a window is specified to be processed and it intersects more than one quadrant, the pieces of the window are automatically mosiacked and output as a single LAS image. The user may also specify a subset of the bands to be output to the images. Finally, the user may choose to have information from the leader, trailer, and supplemental data files written to associated disk files.

Parameters:

Subcommand -WIN:
Process a window. CCTTIPSP-WIN allows the user to specify a window to be processed. The window specified is relative to the full mosaicked TM scene. If the window intersects more than one quadrant, the pieces of the window will be mosaicked together.

COMMENT
Description of tape. A text string sent to the operator's terminal. COMMENT consists of two pieces of information:


  1.  Tape library storage location ID number
  2.  Short description of the tape

The operator uses this text to find the tape to be mounted, so COMMENT should be as descriptive as possible. Including both the ID number and a short description gives the operator a double check to ensure that the correct tape gets mounted. Since CCTTIPSP may process up to a four-volume set, COMMENT is a four-value parameter allowing each tape volume to have a unique mount message. Each value can contain up to 80 characters of any kind. The values for the parameter COMMENT must correspond to the values specified for QUADNUMS (i.e., COMMENT(1) must be the tape description for the quadrant number specified in QUADNUMS(1)).

OUT
Output image. The name of the image created by the program. The output data type is always BYTE. The number of bands in the output image is determined by the BANDS parameter. Output name for each separate image.

WINDOW(--)
Window specification. WINDOW specifies the starting line, starting sample, number of lines, and number of samples of the scene to be processed. The reference area for a window is the size of the full mosaicked TM scene (i.e., 5965 lines x 6967 samples). If the input window intersects a quadrant which is not specified in the QUADNUMS parameter, an error occurs. For example, if the user specified (1,1,512,512) for WINDOW and (3,4) for QUADNUMS, an error would occur. This is because the window specified is located in the upper-left corner of the full mosaicked scene which would be contained in quadrant 1--and quadrant 1 is not one of the available quadrants listed in the parameter QUADNUMS.

                                           
*-------------------------------- ^
|               |               | |
|               |               | |
|  Quadrant 1   |  Quadrant 2   | |
|               |               | |
|               |               | 5
|-------------------------------| 9
|               |               | 6
|               |               | 5
|  Quadrant 3   |  Quadrant 4   | |
|               |               | |
|               |               | |
--------------------------------# v
<--------------6967------------->

* Line 1/sample 1 of reference area for windows 
# Line 5965/sample 6967 of reference area for 
  windows 

BANDS(--)
Band numbers. The image bands on the tape to be processed. The default value indicates that all seven bands are processed.

QUADNUMS(--)
Available quadrangle numbers. The quadrants available to be processed. The default value indicates that all four quadrants are available to be processed for the specified window. If CCTTIPSP determines that the window specified intersects a quadrant not specified by QUADNUMS, an errors occurs.

The values for the parameter QUADNUMS must correspond to the values specified for COMMENT (i.e., COMMENT(1) must be the tape description for the quadrant number specified in QUADNUMS(1)).

WRTDSK(--)
Write to disk. Write the specified records to associated disk files. No formatting or conversions are performed, so the format is the same as that of the input tape. The default value indicates that NO records are written to associated files.


  = ANB:  Annotation and band quality record(s). 
          Indicates that the annotation record and 
  	  band quality record(s) from the supplemental 
          data file are to be written to an associated 
          disk file named "xxxxx;tipsp_annot".
  = HDR:  Header record(s).  Indicates that the 
          scene header, map projection ancillary, 
          and radiometric calibration records from 
          the leader file are to be written to an 
          associated disk file named "xxxxx;tipsp_head".
  = TRA:  Trailer record(s).  Indicates that the 
          records from the trailer file are to be 
          written to an associated disk file named 
          "xxxxx;tipsp_trail".

PRINT(TERM)
Output destination. The destination of the output. Selected information from the scene header and annotation records may be output. The information consists of the following data: the scene ID, WRS path row, the WRS scene center (lat/long), the WRS scene center (line/sample), acquisition date, and data source.

    
  = --:        No Report
  = TERM:      Terminal.  Output is sent to the 
               user's terminal.
  = LP:        Line printer.  Output is sent to 
               the printer defined by $PRINTER.
  = Filename:  User-supplied filename.  Output is 
               sent to the user-supplied file with 
               the extension ".prt".
Subcommand -NOWIN:
Do not process a window. CCTTIPSP-NOWIN does not allow the user to specify a window to process. The area processed is defined by the QUADNUMS parameter.

COMMENT
Description of tape. A text string sent to the operator's terminal. COMMENT consists of two pieces of information:


  1.  Tape library storage location ID number
  2.  Short description of the tape

The operator uses this text to find the tape to be mounted, so COMMENT should be as descriptive as possible. Including both the ID number and a short description gives the operator a double check to ensure that the correct tape gets mounted. Since CCTTIPSP may process up to a four-volume set, COMMENT is a four-value parameter allowing each tape volume to have a unique mount message. Each value can contain up to 80 characters of any kind. The values for the parameter COMMENT must correspond to the values specified for QUADNUMS (i.e., COMMENT(1) must be the tape description for the quadrant number specified in QUADNUMS(1)).

OUT
Output image. The name of the image created by the program. The output data type is always BYTE. The number of bands in the output is determined by the BANDS parameter.

Only one output image name is entered. If the user does not want the quadrants mosaicked, the program appends the necessary qualifiers (.quad1, .quad2, etc.) to the name specified for OUT to create the output name for each separate image.

BANDS(--)
Band numbers. The image bands on the tape to be processed. The default value indicates that all seven bands are processed.

QUADNUMS(--)
Available quadrangle numbers. The quadrants available to be processed. The default value indicates that all four quadrants are processed. Diagonal selection of quadrants (1 and 4 or 2 and 3) or selection of three quadrants is not allowed if the MOSCFLG parameter is set to YES.

The values for the parameter QUADNUMS must correspond to the values specified for COMMENT (i.e., COMMENT(1) must be the tape description for the quadrant number specified in QUADNUMS(1)). The following table lists the areas defined and the sizes of various input specifications:


If MOSCFLG is set to NO:

QUADRANT NUMBERS   AREA DEFINED	       SIZE(NL,NS)
________________   ____________        ___________

  = 1 or 2:	   single quadrants    2983 x 4220
  = 3 or 4:	   single quadrants    2982 x 4220

If MOSCFLG is set to YES:

  = 1,2,3,4:  	   full scene 	       5965 x 6967
  = 1,2: 	   upper half 	       2983 x 6967
  = 3,4: 	   lower half	       2982 x 6967
  = 1,3: 	   left half	       5965 x 4220
  = 2,4: 	   right half	       5965 x 4220

MOSCFLG(YES)
Mosaic flag. Indicates whether or not the input quadrants should be mosaicked together.


  = YES:  Mosaic the quadrants.
  = NO:   Do not mosaic the quadrants.

WRTDSK(--)
Write to disk. Write the specified records to associated disk files. No formatting or conversions are performed, so the format is the same as that of the input tape. The default value indicates that NO records are written to associated files.


  = ANB:  Annotation and band quality record(s). 
          Indicates that the annotation record and 
  	  band quality record(s) from the supplemental 
          data file are to be written to an associated 
          disk file named "xxxxx;tipsp_annot".
  = HDR:  Header record(s).  Indicates that the 
          scene header, map projection ancillary, 
          and radiometric calibration records from 
          the leader file are to be written to an 
          associated disk file named "xxxxx;tipsp_head".
  = TRA:  Trailer record(s).  Indicates that the 
          records from the trailer file are to be 
          written to an associated disk file named 
          "xxxxx;tipsp_trail".

PRINT(TERM)
Output destination. The destination of the output. Selected information from the scene header and annotation records may be output. The information consists of the following data: the scene ID, WRS path row, the WRS scene center (lat/long), the WRS scene center (line/sample), acquisition date, and data source.

    
  = --:        No Report
  = TERM:      Terminal.  Output is sent to the 
               user's terminal.
  = LP:        Line printer.  Output is sent to 
               the printer defined by $PRINTER.
  = Filename:  User-supplied filename.  Output is 
               sent to the user-supplied file with 
               the extension ".prt".
Subcommand -ASSOC:
Process associated files only. The header, annotation, and/or trailer records are read from tape and written to a specified file. The image data is not processed.

COMMENT
Description of tape. A text string sent to the operator's terminal. COMMENT consists of two pieces of information:


  1.  Tape library storage location ID number
  2.  Short description of the tape

The operator uses this text to find the tape to be mounted, so COMMENT should be as descriptive as possible. Including both the ID number and a short description gives the operator a double check to ensure that the correct tape gets mounted. Since CCTTIPSP may process up to a four-volume set, COMMENT is a four-value parameter allowing each tape volume to have a unique mount message. Each value can contain up to 80 characters of any kind. The values for the parameter COMMENT must correspond to the values specified for QUADNUMS (i.e., COMMENT(1) must be the tape description for the quadrant number specified in QUADNUMS(1)).

OUTFILE
Output file. Name of the associated disk files to be created. The associated files are written to the specified disk file name plus an extension (i.e., wash;tipsp_head).

QUADNUMS(--)
Available quadrangle numbers. The quadrants available to be processed. The default value indicates that all four quadrants are available to be processed.

The values for the parameter QUADNUMS must correspond to the values specified for COMMENT (i.e., COMMENT(1) must be the tape description for the quadrant number specified in QUADNUMS(1)).

WRTDSK(HDR,ANB,TRA)
Write to disk. Write the specified records to associated disk files. No formatting or conversions are performed, so the format is the same as that of the input tape. The default value indicates that ALL records are written to associated files.


  = ANB:  Annotation and band quality record(s). 
          Indicates that the annotation record and 
  	  band quality record(s) from the supplemental 
          data file are to be written to an associated 
          disk file named "xxxxx;tipsp_annot".
  = HDR:  Header record(s).  Indicates that the 
          scene header, map projection ancillary, 
          and radiometric calibration records from 
          the leader file are to be written to an 
          associated disk file named "xxxxx;tipsp_head".
  = TRA:  Trailer record(s).  Indicates that the 
          records from the trailer file are to be 
          written to an associated disk file named 
          "xxxxx;tipsp_trail".

PRINT(TERM)
Output destination. The destination of the output. Selected information from the scene header and annotation records may be output. The information consists of the following data: the scene ID, WRS path row, the WRS scene center (lat/long), the WRS scene center (line/sample), acquisition date, and data source.

    
  = --:        No Report
  = TERM:      Terminal.  Output is sent to the 
               user's terminal.
  = LP:        Line printer.  Output is sent to 
               the printer defined by $PRINTER.
  = Filename:  User-supplied filename.  Output is 
               sent to the user-supplied file with 
               the extension ".prt".

Examples:

  1. LAS> ccttipsp-nowin comment=("cc220 mckinley 1/4", "cc221 mckinley 2/4","cc222 mckinley 3/4", "cc223 mckinley 4/4") out=mckinley bands=(3,4,5,6)

    Each quadrant is read in from tape. Mosaicking is then performed to form the full TM scene. The output mosaicked image MCKINLEY has four bands. No associated files are created, and no information is output to the terminal, a disk file, or the line printer.

  2. LAS> ccttipsp-nowin comment="mount j876 needles 1/4" out=tm bands=(1,2) quadnums=1 moscflg=no wrtdsk=anb print=lp

    The first quadrant, bands 1 and 2, is read in. CCTTIPSP creates the output image TM.QUAD1 and the associated file TM.QUAD1;TIPSP_ANNOT which contains annotation and band quality records from the supplemental data file. The selected header/annotation information is sent to the line printer.

  3. LAS> ccttipsp-nowin comment=("c519 wash 2/4", "c550 wash 4/4") out=right.half bands=(1,2,3) quadnums=(2,4) print=term

    The right half of the TM scene, bands 1, 2, and 3, is read in. CCTTIPSP mosaics these two quadrants and creates the output image RIGHT.HALF with three bands. The header, annotation, and trailer records are not written to associated files but the selected header/ annotation information is sent to the user's terminal.

  4. LAS> ccttipsp-win comment=("cc220 mckinley 1/4", "cc221 mckinley 2/4","cc222 mckinley 3/4", "cc223 mckinley 4/4") out=mckin.win window=(100,100,3000,3000) bands=(3,4)

    The window starting at line 100 and sample 100 (relative to the full scene) is read from tape. The pieces of the window are mosaicked together and written as a single image containing 2 bands. No associated files are created, and no information is sent to the terminal, a disk file, or the line printer.

  5. LAS> ccttipsp-win + comment=("c519 wash 2/4", "c550 wash 4/4") out=right.win window=(100,3000,512,512) bands=(1,2,3) quadnums=(2,4)

    The window starting at line 100 and sample 3000 (relative to the full scene) is read from tape. Because the entire window falls within quadrant 2, quadrant 4 is not processed. The output image contains three bands. The header, annotation, and trailer records are not written to associated files, and no information is sent to the terminal, a disk file, or the line printer.

  6. LAS> ccttipsp-assoc comment=("c519 wash 2/4", "c550 wash 4/4") out=wash quadnums=(2,4) wrtdsk=(hdr,anb,tra) print=term

    Only the header, annotation, and trailer records from quadrants two and four are read from tape and written to the files WASH;TIPSP_HEAD, WASH;TISP_ANNOT, and WASH;TIPSP_TRAIL. The image date is not processed. The selected header/annotation information is also sent to the user's terminal.

Description/Algorithm:

The program begins by getting the user-specified parameters and the necessary global variables. If the subcommand -NOWIN was chosen, for each quadrant specified, the input tape is opened and verified, and the specified bands are read in. If a valid pair of quadrants or all four quadrants were specified and mosaicking is also desired, the quadrants are mosaicked. If the subcommand -WIN was chosen, for each quadrant intersected, the input tape is opened and verified, and the specified bands and window are read in. The window specified is always relative to the full mosaicked TM scene and the QUADNUMS parameter indicates which quadrants are available for processing the window. If the window specified intersects a quadrant which the user has not specified as available, an error occurs. If the window intersects more than one quadrant, the pieces of the window are mosaicked together. The subcommand -ASSOC only processes the associated header, annotation, and/or trailer records. The records are read from the specified quadrants and written to a specified file. The image data is not processed.

For all subcommands, if PRINT is not allowed to default, certain information about the scene from the header and annotation records is sent to the terminal, a disk file, and/or the line printer and several TAE globals are set for use by other procedures. Finally, the history and minmax files are created to represent the images, and a completion message is written to the terminal.

Nonfatal Error Messages:

  1. [tipsp-nointer] Window does not intersect quadrant <X>, processing <quadrant X,complete>

    The window specified does not intersect the quadrant indicated. CCTTIPSP will either continue processing with the quadrant specified; or if the entire image has been processed, the message indicates that processing is complete.

  2. [tipsp-onehalf] Window intersects only <right half, lower half, upper half>. Processing quadrants <X> and <X>

    This message indicates that the window specified is completely contained within either the right half, the lower half or the upper half of the image. The quadrant numbers specified correspond to the half being processed. For the right half--quadrants 2 and 4 will be processed, for the lower half--quadrants 3 and 4 will be processed, and for the upper half--quadrants 1 and 2 will be processed.

  3. [tipsp-print] Unable to open print file

    The file to contain the header/annotation information requested to be output to the user's terminal, a disk file, or the line printer could not be opened. Therefore, the header and annotation information will not be output.

  4. [tipsp-skip] Skipping <to specified input band> <first input record> <to next input band> <to end of tape to get annotation file>

    This message lets the user know that the program is skipping forward on the input tape for one of four different reasons. This is done to help explain any apparent delays in processing.

  5. [tipsp-subset] Window reset to subset (<XXXX,XXXX,XXXX,XXXX>) intersecting file

    The window entered by the user is not fully contained within the input image. This message informs the user of the area of the intersecting window that is to be processed.

  6. [tipsp-tpclose] Error closing tape

    An error was encountered while trying to close the tape. As a result, the current tape volume has not been dismounted.

  7. [tipsp-warn] Nonfatal error encountered--Image data saved

    A nonfatal error was encountered during processing. The image data is valid and therefore saved. The message that is displayed immediately preceding this message is the specific error that was encountered. Processing continues.

  8. [tipsp-wrongvol] The current volume does not contain the correct quadrant

    The tape that was mounted did not contain the desired quadrant. The operator was flagged to mount the tape containing the correct quadrant.

Fatal Error Messages:

  1. [tipsp-badvol] The current volume does not contain the correct quadrant

    The first time the wrong tape volume is mounted, a warning message is output and the operator is prompted to mount the correct volume. If the second tape volume mounted is still not the correct one, a fatal error message is output.

  2. [tipsp-badwin] (<XXXX,XXXX,XXXX,XXXX>) Invalid window syntax

    The window entered by the user is not a valid window. The values in parentheses are the starting line, starting sample, number of lines and number of samples entered by the user. This error may be output if any of the values entered are less than zero or if any of the values are equal to zero (unless all the values are equal to zero indicating the entire image is to be processed).

  3. [tipsp-density] Tape density is not 6250 bpi

    The input tape volume's density is not 6250 bpi. Only input tapes with a density of 6250 bpi are supported.

  4. [tipsp-diagonal] Diagonal quadrant specification not allowed

    Diagonal selection of quadrant pairs (1 and 4, or 2 and 3) is not allowed if the parameter MOSCFLG is set to YES.

  5. [tipsp-duplicate] Duplicate <band,quadrant> numbers were specified

    Duplicate band or quadrant numbers were entered.

  6. [tipsp-fatal] Fatal error encountered

    A fatal error was encountered during processing. The input tape is closed and rewound. The output images and any associated files are not deleted, but they are probably not valid. The error message that is displayed immediately preceding this message is the specific error that was encountered.

  7. [tipsp-mosaic] Mosaicking was indicated, however only one input quadrant was specified

    The user indicated that the input quadrants should be mosaicked; however, only one input quadrant was specified.

  8. [tipsp-mount] Error mounting tape

    An error was encountered while trying to mount the input tape volume.

  9. [tipsp-ncomment] User must specify <X> values for COMMENT (one for each quadrant specified)

    The number of values specified for the parameter QUADNUMS and the parameter COMMENT must be the same. This message indicates that an incorrect number of values were entered for COMMENT and how many values should have been entered.

  10. [tipsp-notape] The tape for quadrant <X> is not available

    The window to be processed intersected a quadrant for which a tape was not available.

  11. [tipsp-open] Error opening output image

    An error was encountered while trying to open the output image.

  12. [tipsp-output] Error writing to output image

    An error was encountered while trying to write to the output image.

  13. [tipsp-outside] (<XXXX,XXXX,XXXX,XXXX>) does not intersect (XXXX,XXXX)

    The window entered by the user does not fall within the area of the input image. The values in parentheses at the beginning of the message are the starting line, starting sample, number of lines, and number of samples entered by the user. The values at the end of the message are the number of lines and samples in the input image.

  14. [tipsp-three] Three quadrant specification not allowed

    Specification of three quadrants is not allowed when the MOSCFLG parameter is set to YES.

  15. [tipsp-tpread] Error reading tape

    An error was detected while reading from the input tape volume.

  16. [tipsp-type] Input tape is not a P tape

    After reading the header record, it has been determined that the tape is not a P tape format.

User Notes:

  1. Depending on the bands specified, processing time may be slower if the user requests the header/annotation information be output to the terminal, a disk file, or the line printer or specifies that the associated annotation file should be created. This is due to the fact that the file containing the annotation is located at the end of the tape volume.

  2. If the header/annotation information is requested to be output and more than one input quadrant is specified, the information is for the first specified quadrant.

  3. If the user requested that an associated header and/or trailer file be created, this file will contain one copy of the header and/or trailer records from tape for each quadrant.

  4. If the user requested that an associated annotation file be created, this file will contain the annotation record and the appropriate image quality data records for each band of each specified quadrant. For example, if the user specified to read in quadrants 1 and 2, bands 4 and 5, then the associated annotation file contains six records: band 4 quality data record for quadrant 1, band 5 quality data record for quadrant 1, annotation record for quadrant 1, band 4 quality data record for quadrant 2, band 5 quality data record for quadrant 2, and annotation record for quadrant 2.

  5. Timing for reading in and mosaicking a single band from a full TM scene is 00:31:00. This timing was done with PRINT set to TERM and also includes operator time for mounting tapes.

  6. If a window is specified to be processed, CCTTIPSP will determine which quadrants of those specified are to be processed.

  7. If the option PRINT is not allowed to default, several TAE globals are also set to provide information for other procedures (such as TMFLOPPY). The globals set are: (1) TMWIND which is the actual window processed by CCTTIPSP, (2) TMQUADS which is the quadrant numbers of the quadrants the image was extracted from, (3) TMPTHRW which is the WRS path/row of the scene, (4) TMACQ which is the acquisition date of the scene, (5) TMSCENE which is the scene ID, (6) TMRESAMP which is the resampling technique used, (7) TMQUAL which is the overall geometric quality code of the scene.