[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: decoders] Bufr Decode Exception
- Subject: Re: decoders] Bufr Decode Exception
- Date: Mon, 17 Mar 2008 16:12:02 -0600 (MDT)
On Thu, 13 Mar 2008, Tatsuya Noyori wrote:
Hello,
I am tring to decode a bufr file and have had a Exception. The
exception is as follows:
D:\netcdfAll-2.2.22>java -Xmx256m ucar.bufr.BufrIndexer
ISSM41_RJTD_120000_KAA.bin >ISSM41_RJTD_120000_KAA.bin.indexer.txt
Exception in thread "main" java.lang.NullPointerException
at ucar.bufr.BufrIndexer.writeFileIndex(BufrIndexer.java:327)
at ucar.bufr.BufrIndexer.main(BufrIndexer.java:494)
And the index file that BufrIndexer outputs is as follows:
D:\netcdfAll-2.2.22> cat ISSM41_RJTD_120000_KAA.bin.indexer.txt
Unknown DDS DataType =48
type = BUFR
bufr_edition = 3
location = ISSM41_RJTD_120000_KAA.bin
length = 7441
created = 2008-03-13T04:45:34Z
index_version = 1.1
--------------------------------------------------------------------
It seems like a bug. if so, I would appreciate it if unidata team
would fix the bug.
Tatsuya,
Not a bug...
the DataType=48 in the file is wrong, it can only be values 0,64,128,196:
BUFR Documentation:
Bit 1 = 1 observed data = 0 other data
Bit 2 = 1 compressed data = 0 non-compressed data
Bit 3 - 8 set to zero (reserved)
I even remove 3-8 bit values that resulted in DataType =0 but then
the descriptors were outside the range ie 0-48-50, in table 12 the
highest 0 descriptor is 0-35-
Contact the data provider for more information.
if( dds.getDataType() == 192 || dds.getDataType() == 64 ) {
isCompressed = true;
compressed();
} else if( dds.getDataType() == 128 || dds.getDataType() == 0 ) {
isCompressed = false;
uncompressed();
} else {
System.out.println( "Unknown DDS DataType ="+ dds.getDataType()
);
return false;
Robb...
And I am attaching the bufr file that I tried to decode.
Best regards,
--
Tatsuya Noyori (^o^)/
===============================================================================
Robb Kambic Unidata Program Center
Software Engineer III Univ. Corp for Atmospheric Research
address@hidden WWW: http://www.unidata.ucar.edu/
===============================================================================