[ncl-talk] GOES16 netCDF files

Dennis Shea shea at ucar.edu
Wed Dec 13 12:39:29 MST 2017


A few comments:

[1]
The example file is netCDF-3 ("classic" netCDF)

%> *ncdump -k* goes11.2010.003.200014.BAND_01.nc
classic                      <=== response
===

[2] Golden rule of data processing: Look at ypur data file(s)

The example file overview can be seen via:

%> *ncdump -h* goes11.2010.003.200014.BAND_01.nc
or
%> *ncl_filedump* goes11.2010.003.200014.BAND_01.nc

The output is attached. An extract is:

netcdf goes11.2010.003.200014.BAND_01 {
dimensions:
    lines = 871 ;
    elems = 1912 ;
    bands = 1 ;o
[wnip]

    float *data*(bands, lines, elems) ;
        data :long_name = "data" ;
        data :type = "GVAR" ;
        data :units = "unitless" ;
    float latitude(lines, elems) ;
        latitude:long_name = "latitude" ;
        latitude:units = "degrees" ;
    float longitude(lines, elems) ;
        longitude:long_name = "longitude" ;
        longitude:units = "degrees" ;

===
Hence, NCL is reading the variables 'data, latitude and longitude' *which
are in the file*.

   diri = "./"
   fili = "goes11.2010.003.200014.BAND_01.nc"
   f    = addfile(diri+fili,"r")
   d    = f->*data*          ; data(bands, lines, elems)
                           ; data at type = "GVAR"

   d at lat2d = f->*latitude *  ; (lines, elems)
   d at lon2d = f->*longitude*

===

[3] The GOES16 file is netCDF-4

%> ncdump -k goes16.nc
netCDF-4                     <=== response


%> ncdump -h goes15.nc               [ ncdump -h goes16.nc >
ncdump_h.goes16 ]

As you can see from the file dumps, they are VERY different both in
contents and structure. Some of the variables are 'packed' (type short with
scale_factor and add_offset attributes.

dimensions:
        y = 500 ;
        x = 500 ;
        number_of_time_bounds = 2 ;
        band = 1 ;
        number_of_image_bounds = 2 ;
        num_star_looks = 24 ;
variables:
        *short* Rad(y, x) ;
                Rad:_FillValue = 1023s ;
                Rad:long_name = "ABI L1b Radiances" ;
                Rad:standard_name =
"toa_outgoing_radiance_per_unit_wavenumber" ;
                Rad:_Unsigned = "true" ;
                Rad:sensor_band_bit_depth = 10b ;
                Rad:valid_range = 0s, 1022s ;
                Rad:*scale_factor = 0.1760585f ;*
                Rad:*add_offset = -5.2392f *;
                Rad:units = "mW m-2 sr-1 (cm-1)-1" ;
                Rad:resolution = "y: 0.000056 rad x: 0.000056 rad" ;
                Rad:coordinates = "band_id band_wavelength t y x" ;
                Rad:grid_mapping = "goes_imager_projection" ;
                Rad:cell_methods = "t: point area: point" ;
                Rad:ancillary_variables = "DQF" ;
[SNIP]

If you want the variable 'Rad', it must be unpacked prior to usage:

    data = short2flt( f->Rad )    ; read/import and unpack ... on the 'fly'
    printVarSummary(data)
    printMinMax(data,0)

Further, there are no explicit, lat/lon variables. Rather,  georeferences
are provided.

geospatial_lat_lon_extent
                geospatial_lat_lon_extent:geospatial_westbound_longitude =
-81.80251f ;
                geospatial_lat_lon_extent:geospatial_northbound_latitude =
46.0514f ;
                geospatial_lat_lon_extent:geospatial_eastbound_longitude =
-65.13806f ;
                geospatial_lat_lon_extent:geospatial_southbound_latitude =
32.08946f ;
                geospatial_lat_lon_extent:geospatial_lat_center = 38.44252f
;
                geospatial_lat_lon_extent:geospatial_lon_center =
-74.89199f ;
                geospatial_lat_lon_extent:geospatial_lat_nadir = 0.f ;
                geospatial_lat_lon_extent:geospatial_lon_nadir = -89.5f ;
                geospatial_lat_lon_extent:geospatial_lat_units =
"degrees_north" ;
                geospatial_lat_lon_extent:geospatial_lon_units =
"degrees_east" ;
                geospatial_lat_lon_extent:long_name = "geospatial latitude
and longitude references" ;

====
*Someone else will have to do the graphics stuff. *

Good Luck


On Wed, Dec 13, 2017 at 12:02 PM, Tim Risner <trisner at awis.com> wrote:

> thanks Rick, others.
> version is 6.4.0
> running on Linux Amazon EC2 instance. x86_64 x86_64 x86_64 GNU/Linux
> testing GOES16 file attached.
> I obtained such file from the Amazon AWS bucket system that is now
> publicly accessible by the gov't/Amazon.
> Information on file lists it as a GOES16 netcdf file.
>
> I assumed I could simply replace the file in the example for GOES 11
> example here: http://www.ncl.ucar.edu/Applications/Scripts/goes_1.ncl
> and all would work if the files and datasets were exchangeable.
> Assumptions are likely my problem.
>
> Error output:
>
> fatal:["Execute.c":132]:variable (data) is not in file
> (/var/NCL/INPUT/GOES16.nc)
> fatal:["Execute.c":6381]:variable (data) is not in file (f)
> fatal:["Execute.c":8640]:Execute: Error occurred at or near line 4 in
> file /var/NCL/CODE/testgoes.nc
>
>
>
>
> *Tim Risner*
> *Operational Meteorologist*
> *(888) 798-9955 ext 1006 <(888)%20798-9955>*
>
> <http://www.awis.com>[image:
> https://www.facebook.com/AWISWeatherServices/]
> <https://www.facebook.com/AWISWeatherServices/>
> <https://twitter.com/awisweather>
>
> On Wed, Dec 13, 2017 at 9:02 AM, Rick Brownrigg <brownrig at ucar.edu> wrote:
>
>> Hi Tim,
>>
>> Do you have a dataset you could share?  I download some data from this
>> site:
>>
>> https://www.goes-r.gov
>>
>> but not knowing what I'm really looking for, I could not ascertain that
>> it was specifically GOES16. NCL was able to read it.
>>
>> I should also ask what version of NCL are you working with?
>>
>> If your dataset is too large to email, you can post it to our FTP site:
>>
>> http://ncl.ucar.edu/ftp_files.shtml
>>
>> Rick
>>
>> On Wed, Dec 13, 2017 at 7:35 AM, Tim Risner <trisner at awis.com> wrote:
>>
>>> Hello All,
>>> I am curious as to what the GOES16 netCDF plan is for NCL.
>>> I've attempted to ingest the new GOES16 netCDF into generic GOES code
>>> found on the examples pages, but am getting a variables not found error
>>> when attempting to produce an image. Variable not found is "data". I assume
>>> this is due to the differences between the GOES16 netCDF files and the
>>> older GOES products? or is it just operator error and GOES16 netcdf files
>>> should work?
>>>
>>> Thanks!!!
>>>
>>>
>>> *Tim Risner*
>>> *Operational Meteorologist*
>>> *(888) 798-9955 ext 1006 <(888)%20798-9955>*
>>>
>>> <http://www.awis.com>[image:
>>> https://www.facebook.com/AWISWeatherServices/]
>>> <https://www.facebook.com/AWISWeatherServices/>
>>> <https://twitter.com/awisweather>
>>>
>>> _______________________________________________
>>> ncl-talk mailing list
>>> ncl-talk at ucar.edu
>>> List instructions, subscriber options, unsubscribe:
>>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>>>
>>>
>>
>
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20171213/62e32c4f/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ncdump_h.goes11.2010.003.200014.BAND_01
Type: application/octet-stream
Size: 1917 bytes
Desc: not available
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20171213/62e32c4f/attachment-0002.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ncdump_h.goes16
Type: application/octet-stream
Size: 17402 bytes
Desc: not available
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20171213/62e32c4f/attachment-0003.obj>


More information about the ncl-talk mailing list