Problems reading BUFR file

Jennifer M. Adams jma at COLA.IGES.ORG
Fri Sep 22 11:24:56 EDT 2006


On Sep 21, 2006, at 11:14 AM, dan.swank wrote:

> Jennifer reminded me that part of my problem was the flag in the
> header
> section of my BUFR files was not set to properly indicate the
> compression was in use. (yikes)  May want to beware of that as well.
>
> This also caused bufrscan to throw out incoherent metadata values
> (dates, etc.), in the messages when the compression was in use.
>
> Hopefully Jennifer can verify for sure that GrADS can/can't handle
> this
> compression.  If I remember right, it wasn't implemented.  Could be
> wrong.

Here's my opinion: Data providers that waste precious human resources
figuring out a way to further compress an already highly compressed
data format and then don't bother to leave a trace of their efforts
ought to be punished. I'm doing my part by not supporting such
pathological data in GrADS.
Jennifer


>
> -Dan
>
>
> Bob Kuligowski wrote the following on 9/21/2006 9:10 AM:
>> Diane et al.,
>>
>>    That didn't work, but it did get me looking more closely at the
>> time
>> information.  The header information suggests that the Julian day
>> is in
>> 0-04-043, the hour is in 0-04-004, and the minute in 0-04-005.
>> However,
>> when I dump the full bufrscan output into a file called
>> 'everything.exe'
>> and do 'grep 0-04-043 everything.exe' to try to extract the Julian
>> day
>> information, I get all kinds of numbers including values above
>> 365.  The
>> same happens when doing 'grep 0-04-004' to get the hour information;
>> some of the values are above 23.  This tells me that either (a)
>> the BUFR
>> file is really messed up; or (b) somehow bufrscan isn't able to
>> read it
>> correctly (which could be related to (a)).
>>
>>    So I'm going to try to contact the source of said file to see
>> what's
>> going on...thanks for your help!
>>
>> Cheers,
>> Bob
>>> Guess #2:
>>>
>>> If your ob times are not exactly 13:00Z01SEP2006, try a time
>>> window, eg:
>>>
>>> set time 12:30Z01sep2006 13:30z01sep2006
>>>
>>> If that doesn't work, hope that someone more knowledgeable chimes in
>>> soon.
>>>
>>>    Diane
>>>
>>> Bob Kuligowski wrote:
>>>> Diane,
>>>>
>>>>    Good catch...though, unfortunately, I still get the same result.
>>>> Another of those cases where the process of debugging reveals
>>>> bugs that
>>>> one wasn't looking for in the first place :-)  Thanks!
>>>>
>>>> Cheers,
>>>> Bob
>>>>> Here's a quick guess...
>>>>>
>>>>> You have in your gribscan output:
>>>>>
>>>>>   0 05 002  (numeric) CLAT     Latitude (coarse accuracy)
>>>>>   0 06 002  (numeric) CLON     Longitude (coarse accuracy)
>>>>>
>>>>>
>>>>> but in your ctl file:
>>>>>
>>>>> xvar 6,1
>>>>> yvar 5,2
>>>>>
>>>>>
>>>>> Try changing that xvar definition in your ctl file to:
>>>>>
>>>>> xvar 6,2
>>>>>
>>>>>
>>>>>    Diane
>>>>>
>>>>>
>>>>> Bob Kuligowski wrote:
>>>>>>    I am attempting to read and display a BUFR file in GrADS.
>>>>>> When I
>>>>>> run 'bufrscan' the output is the attached 'headers.txt' file.
>>>>>> I tried
>>>>>> to follow the directions in the BUFR entry of
>>>>>> http://www.iges.org/grads/gadoc/gadocindex.html to produce a
>>>>>> GrADS
>>>>>> control file, which is attached as 'testbufr.ctl'.  I can open
>>>>>> the
>>>>>> .ctl
>>>>>> file in GrADS with no problem, but when I try 'set gxout print'
>>>>>> followed
>>>>>> by 'd ' of any of the variables in the .ctl file, I always get
>>>>>> "Printing
>>>>>> stations -- 0 Reports -- Undef = -979".  My presumption is
>>>>>> that the
>>>>>> variables in the .ctl file are pointing at the wrong X and Y,
>>>>>> but I'm
>>>>>> using the files that I found in headers.txt.
>>>>>>
>>>>>>    Any thoughts?  Thanks in advance...
>>>>>>
>>>>>> Cheers,
>>>>>>
>>>>>> --
>>>>>> Bob Kuligowski, Ph.D.
>>>>>> Meteorologist
>>>>>> NOAA/NESDIS/Center for Satellite Applications and Research (STAR)
>>>>>>
>>>>>> Mailing Address:
>>>>>> E/RA2   RM 712 WWBG
>>>>>> 5200 Auth Rd.
>>>>>> Camp Springs, MD  20746-4304
>>>>>>
>>>>>> Phone:  (301) 763-8251x192
>>>>>> Fax:    (301) 763-8580
>>>>>>
>>>>>> http://www.orbit.nesdis.noaa.gov/smcd/emb/bobk/
>>>>>>
>>>>>>
>>>>>> -----------------------------------------------------------------
>>>>>> -------
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>    < top of gribscan output snipped - dcs >
>>>>>
>>>>>> 3 61 118  (sequence)
>>>>>>   0 04 043  (numeric) JULDAY   JULIAN DAY
>>>>>>   0 04 004  (numeric) HOUR     Hour
>>>>>>   0 04 005  (numeric) MINU     Minute
>>>>>>   0 60 006  (numeric) SCSTTM   SCAN START TIME
>>>>>>   0 60 003  (numeric) SCANUM   SCAN NUMBER
>>>>>>   0 60 004  (numeric) NUMSCEN  NUMBER OF SCENES IN SCAN
>>>>>>   0 05 002  (numeric) CLAT     Latitude (coarse accuracy)
>>>>>>   0 06 002  (numeric) CLON     Longitude (coarse accuracy)
>>>>>>   0 60 005  (numeric) SCENEN   SCENE NUMBER
>>>>>>   0 60 093  (numeric) RF1      Rain Flag 1 (Odd Scan)
>>>>>>   0 60 094  (numeric) RF2      Rain Flag 2 (Odd Scan)
>>>>>>   0 60 162  (numeric) RR       Rain Rate
>>>>>>   0 60 090  (numeric) SURFTG   SURFACE TAG
>>>>>>   0 60 163  (numeric) LSURFTY  L Surface Type
>>>>>>   0 60 175  (numeric) SNWDPTH  SNOW DEPTH
>>>>>>   0 60 165  (numeric) LSOILM   L Soil Moisture
>>>>>>   0 60 166  (numeric) LSURFTM  L Surface Temp
>>>>>>   0 60 167  (numeric) ICSNEDG  Ice/Snow Edge
>>>>>>   0 60 168  (numeric) ICONC    Ice Concentration
>>>>>>   0 60 169  (numeric) ICEAGE   Ice Age
>>>>>>   0 60 170  (numeric) OSWSF    Ocean Surface Wind Speed Flag
>>>>>>   0 60 171  (numeric) OWV      Ocean Water Vapor
>>>>>>   0 60 172  (numeric) OSWS     Ocean Surface Wind Speed
>>>>>>   0 60 173  (numeric) OCW      Ocean Cloud Water
>>>>>>   0 60 174  (numeric) OCA      Ocean Cloud Amount
>>>>>>   0 60 164  (numeric) SSWC     Surf Snow Water Content
>>>>>>
>>>>>
>>>>>    < bulk of gribscan output snipped - dcs >
>>>>>
>>>>>>
>>>>>> -----------------------------------------------------------------
>>>>>> -------
>>>>>>
>>>>>>
>>>>>>
>>>>>> dset ^../Data/NPR.EDEB.SA.D06263.S0549.E0735.B1508081.NS
>>>>>> title Test BUFR description file
>>>>>> undef -979
>>>>>> dtype bufr
>>>>>> stid 1,198
>>>>>> xvar 6,1
>>>>>> yvar 5,2
>>>>>> tvar yr 4,1 mo 4,2 dy 4,3 hr 4,4 mn 4,5
>>>>>> stid 1 1
>>>>>> tdef 1 LINEAR 13:00Z01SEP2006 1hr
>>>>>> vars 20
>>>>>> slon 0 6,2 Station longitude
>>>>>> slat 0 5,2 Station latitude
>>>>>> scenen   0 60,005 Scene number
>>>>>> rf1      0 60,093 Rain flag 1
>>>>>> rf2      0 60,094 Rain flag 2
>>>>>> rainrate 0 60,162 Rain Rate
>>>>>> surftg   0 60,090 Surface tag
>>>>>> lsurty   0 60,163 L Surface type
>>>>>> snwdpth  0 60,175 Snow depth
>>>>>> lsoilm   0 60,165 L Soil moisture
>>>>>> lsurftm  0 60,166 L Surface temp
>>>>>> icsnedg  0 60,167 Ice/snow edge
>>>>>> iconc    0 60,168 Ice concentration
>>>>>> iceage   0 60,169 Ice age
>>>>>> oswsf    0 60,170 Ocean surface wind speed flag
>>>>>> owv      0 60,171 Ocean water vapor
>>>>>> osws     0 60,172 Ocean surface wind speed
>>>>>> ocw      0 60,173 Ocean cloud water
>>>>>> oca      0 60,174 Ocean cloud amount
>>>>>> sswc     0 60,164 Surf cnow water content
>>>>>> endvars
>>>>>
>>>>> --
>>>>> Diane Stokes
>>>>> Environmental Modeling Center
>>>>> National Weather Service/NOAA
>>>>
>>>>
>>>> --
>>>> Bob Kuligowski, Ph.D.
>>>> Meteorologist
>>>> NOAA/NESDIS/Center for Satellite Applications and Research (STAR)
>>>>
>>>> Mailing Address:
>>>> E/RA2   RM 712 WWBG
>>>> 5200 Auth Rd.
>>>> Camp Springs, MD  20746-4304
>>>>
>>>> Phone:  (301) 763-8251x192
>>>> Fax:    (301) 763-8580
>>>>
>>>> http://www.orbit.nesdis.noaa.gov/smcd/emb/bobk/
>>>
>>> --
>>> Diane Stokes
>>> Environmental Modeling Center
>>> National Weather Service/NOAA
>>
>>
>> --
>> Bob Kuligowski, Ph.D.
>> Meteorologist
>> NOAA/NESDIS/Center for Satellite Applications and Research (STAR)
>>
>> Mailing Address:
>> E/RA2   RM 712 WWBG
>> 5200 Auth Rd.
>> Camp Springs, MD  20746-4304
>>
>> Phone:  (301) 763-8251x192
>> Fax:    (301) 763-8580
>>
>> http://www.orbit.nesdis.noaa.gov/smcd/emb/bobk/
>
> --
> Dan Swank <dan.swank at noaa.gov>
> NOMADS Project:  Software & Data Management
> Contractor - STG, Incorporated
> Veach-Baley Federal Building
> 151 Patton Avenue
> Asheville, NC 28801-5001
> Phone: 828-271-4007
>

Jennifer M. Adams
IGES/COLA
4041 Powder Mill Road, Suite 302
Beltsville, MD 20705
jma at cola.iges.org



-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20060922/af39fd6c/attachment.html 


More information about the gradsusr mailing list