User's Guide

Convert a geoTIFF file to a LAS image.

Function:

Converts a Striped or Tiled geoTIFF image to a LAS image.

Parameters:

COMMENT(--)
Description of CD(s). A text string is sent to the operator's terminal describing the CD(s) to be mounted. COMMENT should include both the ID number and a short description which allows the operator to ensure the correct media is mounted. If multiple CD's are specified the user must specify them so that the image data is in band sequential order. If the source media is disk, leave this field blank. See User Note 4.

INFILE(-- )
The full LAS pathname of the input image on disk or CD. This includes the sceneid of the input geoTIFF file. See User Note 3.

OUT(--)
Output image(s). The output LAS image. The number of images specified in OUT must either be one, equal to the number of bands specified in BANDS, or equal the number of entries in NBANDS. The directory and root specified in OUT will be used for the directory and root specification of the intermediate .BIL file. The output direcory and file names must be in lower case. See User Note 1 and User Note 2.

BANDS(-- )
Band number(s). The image bands to be processed. The default indicates that all bands present on disk or CD(s) are processed. See User Note 2.

NBANDS(-- )
Defines the number of bands to be placed in each output file. If NBANDS is specified, BANDS must be also specified. Also the number of entries must match the number of entries in OUT. See User Note 2.

WINDOW(--)
Window specification. If UNITS is LS, the window specifies the start line, start sample, number of lines, and number of samples for the window. If only the start line and sample are entered, the number of lines and number of samples will default to the end of the image. If UNITS is not LS, the window specifies the upper left Y, upper left X, lower right Y, and lower right X coordinates. If the WINDOW is not specified, it defaults to the entire image. If a window is specified, it is applied to all of the bands.

UNITS(LS)
Units used for WINDOW parameter.

  = LS:  Line/Sample
  = DEG: Degrees
  = DMS: Degrees Minutes Seconds
           (+DDDMMMSSS.SS)
  = PRO: Projection coordinates

ODTYPE(SAME )
Output data type. The data type of the output images.

  = SAME: Same as input
  = BYTE: BYTE       (8-bit unsigned integer)
  = I*2:  INTEGER*2  (16-bit signed integer)
  = I*4:  INTEGER*4  (32-bit signed integer)
  = R*4:  REAL*4     (32-bit signed real)

Example:

  1. LAS> geotiffin comment=-- infile=l71028029_0291991082 out=outfile bands=-- nbands=-- window=(100 110 512 512) units=ls odtype=i*4

    All geoTIFFs with the sceneid l71028029_0291991082 will be converted to the LAS image outfile.img. BANDS was not specified,therefore all bands will be copied to outfile.img. A 512 X 512 window will copied starting line at 100, starting sample at 110 using LS as UNITS. The output image will be data type INTEGER*4 data.

  2. LAS> geotiffin comment="pls mount cd 123" infile=l71028029_0291991082 out=(outfile1,outfile2) bands=(1 4 5) nbands=(2 1)

    CD 123 will be mounted by operations. The geoTIFF files with sceneid l71028029_0291991082 will be read. Bands 1 and 4 will be output to outfile1 and band 5 will be output to outfile2.

  3. LAS> geotiffin comment= -- infile="[sg1.csb]l71028029_0291991082" out="[sg1.dsb]output1 bands=-- nbands=-- window=(4354290.000,588000.001,4320690.000,650400.002) units=pro odtype=byte

    The geoTIFF files in directory [sg1.csb] with the sceneid l71028029_0291991082 will be read in and all the bands will processed to the las image output located in [sg1.dsb] . The file output will be windowed according to the WINDOW and UNITS parameters. If the geoTIFF files are different resolutions then the outfile will be given the extension "_r#"

  4. LAS> geotiffin comment=-- infile=[cdrom]l71028029_0291991082 out=output bands=1 nbands=1

    This is an example of a user reading in a CD from their CDROM. The user added the cdrom path along with the sceneid name. Band 1 will be read and processed to the outfile output.img In this case the user is only allowed to read one CD at a time. If another CD is to be read, the user needs to re-run Geotiffin.

Description/algorithm

The specified input TIF file will be read from disk or CD(s). The TIF file will be copied to a flat transfer file with the root of OUT, and the extension .bil. The transfer file will be converted to LAS by TRANSLAS-IN. Finally, the geographic information (in the form of tags and keys)is read from the input TIF file and the ddr is updated. The CD will dismount and the intermediate .bil file(s) will be deleted.

Nonfatal Error Messages:

  1. [geotiffin-gtif] Error closing CD

    Error closing CD. Make sure CD is closed and offline.

Fatal Error Messages:

  1. [geotiffin-bits] Only handle 8, 16, and 32-bit images

    Only 8, 16, and 32-bit images are handled.

  2. [geotiffin-open] Error opening input image <XXXXXX>

    There was an error opening the input image file <XXXXXX>. Check the input file name and the file permissions.

  3. [geotiffin-open] Error opening output image <XXXXXX>.

    There was an error opening the output image file <XXXXXX>. Check the output file name and the file permissions.

  4. [geotiffin-mem] Error allocating memory for <XXXXX>.

    There was an error allocating memory for the data buffers <XXXXX>. If the error persists contact the system administrator.

  5. [geotiffin-read] Error reading geoTIFF image

    There was an error reading the geoTIFF image file. Check the file name and file permissions.

  6. [geotiffin-fatal] Fatal error encountered

    The error message that is displayed immediately preceding this message is the specific error that occurred. Processing is terminated.

  7. [geotiffin-wndconv] Error converting window coordinates

    There was an error converting the window parameters from their units to line/sample. The error message that is displayed immediately preceding this message is the specific error that occurred. Processing is terminated.

  8. [geotiffin-wndchk] Error checking the window coordinates

    An error occurred while checking the window coordinates and verifying they are valid for the input image. The error message that is displayed immediately preceding this message is the specified error that occurred. Processing is terminated.

  9. [geotiffin-lng2tae] Error passing variable <XXXXXX> to TAE.

    An error occurred while trying to output a long value for the TAE parameter <XXXXXX>. If the error persists contact the system administrator.

  10. [geotiffin-qout] Error passing variables to TAE

    An error occurred while attempting to pass variables back to TAE. If the error persists contact the system administrator.

  11. [geotiffin-q_intg] Error passing <XXXXXX> to TAE

    An error occurred while attempting to pass variable <XXXXXX> back to TAE. If the error persists contact the system administrator.

  12. [geotiffin-utmzonegen] geoTIFF has an invalid UTM zone code

    Check the geoTIFF file for a valid UTM zone. Double check the ProjectionGeoKey for a vaild key.

  13. [geotiffin-zone_spheroid] geoTIFF has an invalid ProjectedCSTypeGeoKey for UTM

    Check if the ProjectedCSTypeGeoKey in the geoTIFF file is valid.

  14. [geotiffin-getpar] BANDS cannot be NULL if NBANDS is specified

    Double check the BANDS and NBANDS parameters. Either specify BANDS or leave BANDS NULL and specify NBANDS as NULL. All files will be processed if both parameters are NULL.

  15. [geotiffin-getpar] Total number of BANDS must equal sum of NBANDS

    Double check the NBANDS and BANDS. Since NBANDS pairs the specified BANDS into groups, the sum of all the pairings in NBANDS must equal the total number of BANDS.

  16. [geotiffin-getpar] Must specify OUT

    Add an OUT file name and re-run

  17. [geotiffin-getpar] Total number of OUT must equal the count of NBANDS

    Double check the OUT and NBANDS parameters. There must be an output file specified for each of the values in NBANDS.

  18. [geotiffin-pixel] Pixel size does not exist

    GeoTIFF tag ModelPixelScaleTag does not exist. This is a necessary key so double check geoTIFF file for this key.

  19. [geotiffin-coors] Corner coordinates do not exist

    GeoTIFF tag ModelTiepointTag does not exist. Double check geoTIFF file for this tag.

  20. [geotiffin-rtcoef] Error computing the transformation coefficients

    An error occurred in c_rtcoef while trying to compute the transformation coefficients. The error message that is displayed immediately preceding this message is the specified error.

  21. [geotiffin-datasys] DATASYS environment variable not set

    The DATASYS environment variable was not set. This environment variable is required to convert the window parameter to line/sample.

  22. [geotiffin-getddr] DDR does not exist

    An error occurred while retrieving the DDR file. Check if the DDR file exists on disk and check the file permissions.

  23. [geotiffin-putddr] Error writing DDR

    An error occurred while writing the DDR to disk. Check disk space. If the error persists, contact the system administrator.

  24. [geotiffin-putbdr] Error writing BDDR

    An error occurred while writing the BDDR to disk. Check disk space. If the error persists, contact the system administrator.

  25. [geotiffin-utm] geoTIFF does not contain a spheroid code

    Double check the geoTIFF file for the correct GeographicTypeGeoKey

  26. [geotiffin-utm] geoTIFF does not contain a zone code

    Double check the geoTIFF file for the correct ProjectionGeoKey

  27. [geotiffin-invalid] Invalid specification of WINDOW

    There is a conflict in the number of values specified for either OUT or WINDOW/UNITS.

    OUT must specify one image file name to store all of the bands that are to be read, one image file name for each of the bands to be read, or one image file name for each entry in NBANDS.

    If the UNITS parameter is LS (line/sample), the WINDOW parameter must have 0, 2, or 4 parameters specified. For other values of UNITS, 0 or 4 WINDOW parameters must be specified.

  28. [geotiffin-fatal] geoTIFF linear units do not exist

    Double check geoTIFF file for the required GeoLinearUnitsGeoKey.

  29. [geotiffin-fatal] Invalid Landsat 7 sceneid

    If a landsat 7 file format was used, make sure the naming convention l7fppprrr_rrrYYYYMMDD is correct and contains 21 characters. See User note 3.

  30. [geotiffin-fatal] Invalid band number in geoTIFF file name

    Double check the geoTIFF file name. The file should have the _bXX.tif extension.

  31. [geotiffin-lines] Error retrieving number of lines

    Check the geoTIFF file permissions. Contact system administrator if the error persists.

  32. [geotiffin-config] Error retrieving Planar Configuration type

    Check the geoTIFF file permissions. Contact system administrator if the error persists.

  33. [geotiffin-samples] Error retrieving number of samples

    Check the geoTIFF file permissions. Contact system administrator if the error persists.

  34. [geotiffin-bands] Error retrieving total number of bands

    Check the geoTIFF file permissions. Contact system administrator if the error persists.

  35. [geotiffin-notsup] The image is a tiled, multiband image which is not supported

    The tiff spec does not give information on how to handle PLANARCONFIG_SEPARATE for multiple bands. Contact the system administrator.

  36. [geotiffin-key] Error retrieving key GTRasterTypeGeoKey

    The key GTRasterTypeGeoKey could not be retrieved.

User Notes:

  1. During the process of ingesting data, unique file names are generated to accommodate multiple resolutions and multiple volumes. The file names are generated by attaching "_r#" for different resolution numbers (where # is the number of the current resolution).

  2. The parameters BANDS, NBANDS, and OUT are related to each other. OUT specifies the output file names to use, BANDS indicates which bands should be taken from the input image, and NBANDS indicates the number of entries in BANDS that should be grouped into each OUT file specified. For example, if BANDS=(1,3,2,4) and NBANDS=(2,1,1), OUT must contain three file names (to match the number of entries in NBANDS) and the first output file will contain bands 1 and 3, the second will contain band 2, and the third will contain band 4. If NBANDS is specified, BANDS must be specified and the number of bands in BANDS must equal the sum of the bands in NBANDS. If NBANDS isn't specifed, OUT must contain a single file name.

  3. The file naming convention for Landsat 7 geoTIFF product is L7fppprrr_rrrYYYYMMDD_AAA.TIF where

          L7       = Landsat 7 mission.
          f        = ETM+ format (1 or 2)
          ppp      = starting path of the product
          rrr_rrr  = starting and ending rows of the product
          YYYYMMDD = acquisition date of the image
          AAA      = file type:
                      B10 = band 1
    		  B20 = band 2
                      B30 = band 3
                      B40 = band 4
                      B50 = band 5
                      B61 = band 6L  (format 1)
                      B62 = band 6H  (format 2) 
                      B70 = band 7   
                      B80 = band 8   
          TIF = geoTIFF file extension
    

  4. Tapes are not supported for procedure Geotiffin.

  5. If a multiple band image is created, the WINDOW only needs to be specified once.

  6. Space Oblique Mercator B currently does not have projection specific geoTIFF keys defined to support it. However, SOM can be defined in geoTIFF by User-Defined ASCII keys. NLAPS produces SOM products and uses the User-Defined keys. Geotiffin will search the User-Defined ASCII PCSCitationGeoKey for "somb" or "space oblique mercator b" and convert it to a LAS image.