/[escript]/trunk/downunder/py_src/datasources.py
ViewVC logotype

Diff of /trunk/downunder/py_src/datasources.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 4014 by caltinay, Thu Oct 4 03:28:35 2012 UTC revision 4016 by caltinay, Tue Oct 9 03:50:27 2012 UTC
# Line 475  class NetCDFDataSource(DataSource): Line 475  class NetCDFDataSource(DataSource):
475              raise RuntimeError("Could not determine gravity variable")              raise RuntimeError("Could not determine gravity variable")
476    
477          # try to determine value for unused data          # try to determine value for unused data
478          try:          if hasattr(f.variables[grav_name], 'missing_value'):
479              maskval = float(f.variables[grav_name].missing_value)              maskval = float(f.variables[grav_name].missing_value)
480          except:          elif hasattr(f.variables[grav_name], '_FillValue'):
481                maskval = float(f.variables[grav_name]._FillValue)
482            else:
483                self.logger.debug("missing_value attribute not found, using default.")
484              maskval = 99999              maskval = 99999
485    
486          # see if there is a wkt string to convert coordinates          # see if there is a wkt string to convert coordinates

Legend:
Removed from v.4014  
changed lines
  Added in v.4016

  ViewVC Help
Powered by ViewVC 1.1.26