ywangd / pybufrkit

Pure Python toolkit to work with WMO BUFR messages
http://pybufrkit.readthedocs.io/
MIT License
72 stars 28 forks source link

BUFR message with year of 0 #34

Closed akrherz closed 5 months ago

akrherz commented 5 months ago

Like in #33, I have an example BUFR file for your consideration. This yields a year value of zero

example.zip

ywangd commented 5 months ago

I see the following in the output of pybufrkit decode -a example.bufr

...
    307072 (Monthly normals for a land station)
        004001 YEAR 71
        004001 YEAR 0
        004002 MONTH 2
        004003 DAY 1
        004004 HOUR 0
...

Is this what you referred to as "year value of zero"? The decoding seems to be correct in this case. The result is consistent with DWD's online decoder. I am not sure how to interpret the result though. Maybe the first year (71) is the number of years used for average and the second year (0) is the offset relative to 2024 (reported as part of the preceding 307071 descriptor)? These are just my wild guesses. You may need to consult with someone who is familiar with this particular data descriptor (307072).

akrherz commented 5 months ago

Thank you for investigating this @ywangd , seems to be in order then...