The forum is locked.

The Ocean Color Forum has transitioned over to the Earthdata Forum (https://forum.earthdata.nasa.gov/). The information existing below will be retained for historical reference. Please sign into the Earthdata Forum for active user support.

Up Topic Products and Algorithms / Satellite Data Products & Algorithms / Building a Grid from Geo File (locked)
- By Pina Date 2004-05-31 23:16
Hi

I developed a simple Fortran/HDF program to open a L2.Lac file and the correspondent .Geo File to build a grid and look into the results. The number of columns and lines are the same in Geophysical Data Fields in L2 file and in the Latitude and Longitude Data fields in the Geo File.

Does this means that the Latitude and Longitude values are established in the center of the hypothetical grid cells in the some place where the geophysical values are established?

Thus to establish a grid can I assume that the grid cells boundaries are between (middle) two consecutive Latitude and Longitude values?

Pina
- By bryanfranz Date 2004-06-01 13:29
Yes.  The positions in the geo file are the positions of the view vector from the sensor to the ground for each geophysical observation.  In effect they are the center positions of each observation.

However, you don't really need the geo file to get this information.  The longitude and latitude information from the geo file has been included in the Level-2 file.  The only difference is that it has been subsampled along scan (every 8th pixel) to save space.  The subsampled position is indicated by the control-point SDS in the hdf file.  A simple cubic spline interpolation can accurately recover the full longitude and latitude arrays.  The relevant SDSes are:

  Number of Scan Lines = 2030 ;
  Number of Pixel Control Points = 170 ;
  Pixels per Scan Line = 1354 ;

        float longitude(Number of Scan Lines, Number of Pixel Control Points) ;
    longitude:long_name = "Longitudes at control points" ;
    longitude:valid_range = -180.f, 180.f ;
    longitude:units = "degrees" ;

  float latitude(Number of Scan Lines, Number of Pixel Control Points) ;
    latitude:long_name = "Latitudes at control points" ;
           latitude:valid_range = -90.f, 90.f ;
    latitude:units = "degrees" ;

  long cntl_pt_cols(Number of Pixel Control Points) ;
    cntl_pt_cols:long_name = "Pixel control points" ;
    cntl_pt_cols:units = "none" ;

This information gives longitude and latitude for every scan, at the pixel control points.  For each scanline, simply interpolate from the control-point array to an array of 1...1354 for longitude and latitude, and you'll get the full lon/lat arrays.  This is what SeaDAS does.

Of course, if you have the geo file it saves you some trouble, but you don't need the geo file to navigate the Level-2 data.
Up Topic Products and Algorithms / Satellite Data Products & Algorithms / Building a Grid from Geo File (locked)