[geotk] Error while reading netCDF file

Martin Desruisseaux martin.desruisseaux at geomatys.fr
Wed Sep 7 06:47:44 EDT 2011


Hello Hendy

I commited a fix which will hopefully avoid those exceptions. The 
NullPointerException occurred when a NetCDF file declares too few information 
for the variable to be read (no data type, no minimum or maximum value), as we 
can see from the "ncdump" you provided us:

>          byte Band1(y, x) ;
>                  Band1:grid_mapping = "lambert_conformal_conic" ;
>                  Band1:long_name = "GDAL Band Number 1" ;

The patch should infer minimum and maximum value from the data type, which is 
byte (0 to 255) in the above case.

The IndexOutOfBoundsException occurred when the absolute value of the fill value 
is equals or greater than 0x200000 (hexadecimal value). The patch should 
workaround that issue, at the cost of a slight risk of key collision if a NetCDF 
file declares more than one fill value and the modulo of those fill values by 
0x200000 produce the same result.

It will take 12 hours before the Hudson server generate a new bundle. If you can 
try again tomorrow, that would be appreciated.

Regards,

     Martin



More information about the Geotoolkit mailing list