Closed GoogleCodeExporter closed 9 years ago
Confirmed. Should be easy to fix. In the meantime, here's a workaround
v = file.variables[variable]
v.set_auto_maskandscale(False)
grid = v[:]
Original comment by whitaker.jeffrey@gmail.com
on 19 Sep 2012 at 7:45
The missing value attribute in that netCDF file is a string. The error occurs
when checking for the occurence of a missing value in the data retrieved from
the variable - numpy issues this warning
Unicode equal comparison failed to convert both arguments to Unicode -
interpreting them as being unequal
and fails silently. I've committed a fix for this - I cast the missing_value
attribute to the type of the netcdf variable before doing the comparison.
Original comment by whitaker.jeffrey@gmail.com
on 19 Sep 2012 at 8:05
Thanks!
Original comment by antipod...@gmail.com
on 19 Sep 2012 at 9:57
That's really a bug in your netcdf file - if that's a file you created you
should probably fix it so the missing_value attribute is a float not a string.
Other netcdf clients will probably have trouble with that as well.
Original comment by whitaker.jeffrey@gmail.com
on 19 Sep 2012 at 9:59
Original comment by whitaker.jeffrey@gmail.com
on 7 Mar 2013 at 11:46
Original issue reported on code.google.com by
antipod...@gmail.com
on 19 Sep 2012 at 7:25Attachments: