Notes on extracting information from geotiff. i.e. Entries for OLAF

The below was written prior to utilizing gdalwarp to make the geotiffs. See "Grid to GeoTIF" section for details, but if you use gdalwarp to make the geotiff you can also output a sample xml label that has most (all?) of the information below.

To get the pixel size of a geotiff, use gdalinfo. Command and output of a rectangular pixel size are shown below. Number of pixels is shown by the "Size is 501, 100" where 501 is px and 100 is line. Pixel size (in deg) is given by "Pixel Size = (0.036126000000000,-0.181000000000000)". Note you can also get this number by using the "Corner Coordinates:" of (292.297 - 274.198) / 501 = 0.036126, or (3.115 - -14.984) / 100 = 0.181. GDAL outputs a negative sign in front of the 0.181, I am not sure why.

<rand> test$ gdalinfo -stats LEADEQ-radius-v1.tif
Driver: GTiff/GeoTIFF
Files: LEADEQ-radius-v1.tif
       LEADEQ-radius-v1.tif.aux.xml
Size is 501, 100
Coordinate System is:
GEOGCRS["Tethys 2000",
    DATUM["D_Tethys_2000",
        ELLIPSOID["Tethys_2000_IAU_IAG",535600,54.6530612244898,
            LENGTHUNIT["metre",1,
                ID["EPSG",9001]]]],
    PRIMEM["Greenwich",0,
        ANGLEUNIT["degree",0.0174532925199433,
            ID["EPSG",9122]]],
    CS[ellipsoidal,2],
        AXIS["latitude",north,
            ORDER[1],
            ANGLEUNIT["degree",0.0174532925199433,
                ID["EPSG",9122]]],
        AXIS["longitude",east,
            ORDER[2],
            ANGLEUNIT["degree",0.0174532925199433,
                ID["EPSG",9122]]]]
Data axis to CRS axis mapping: 2,1
Origin = (274.197937000000024,3.115500000000000)
Pixel Size = (0.036126000000000,-0.181000000000000)
Metadata:
  AREA_OR_POINT=Area
  lat#actual_range={-14.894,3.025}
  lat#axis=Y
  lat#long_name=latitude
  lat#standard_name=latitude
  lat#units=degrees_north
  lon#actual_range={274.216,292.279}
  lon#axis=X
  lon#long_name=longitude
  lon#standard_name=longitude
  lon#units=degrees_east
  NC_GLOBAL#Conventions=CF-1.7
  NC_GLOBAL#GMT_version=6.2.0 [64-bit]
  NC_GLOBAL#history=sphinterpolate -R274.216/292.279/-14.894/3.025 -I501+n/100+n -Gtmp.nc
  z#actual_range={525616.3125,530976.5625}
  z#long_name=z
  z#_FillValue=nan
Image Structure Metadata:
  INTERLEAVE=BAND
Corner Coordinates:
Upper Left  (     274.198,       3.115) (274d11'52.57"E,  3d 6'55.80"N)
Lower Left  (     274.198,     -14.984) (274d11'52.57"E, 14d59' 4.20"S)
Upper Right (     292.297,       3.115) (292d17'49.43"E,  3d 6'55.80"N)
Lower Right (     292.297,     -14.984) (292d17'49.43"E, 14d59' 4.20"S)
Center      (     283.248,      -5.934) (283d14'51.00"E,  5d56' 4.20"S)
Band 1 Block=501x4 Type=Float32, ColorInterp=Gray
  Minimum=525616.312, Maximum=530976.562, Mean=528625.394, StdDev=890.336
  NoData Value=nan
  Metadata:
    actual_range={525616.3125,530976.5625}
    long_name=z
    NETCDF_VARNAME=z
    STATISTICS_MAXIMUM=530976.5625
    STATISTICS_MEAN=528625.39353917
    STATISTICS_MINIMUM=525616.3125
    STATISTICS_STDDEV=890.33610412375
    STATISTICS_VALID_PERCENT=100
    _FillValue=nan

attachment:HexFiend2.png