[gradsusr] PyGrADS cannot open NetCDF files

Arlindo da Silva dasilva at alum.mit.edu
Mon Mar 14 17:21:04 EDT 2011


On Mon, Mar 14, 2011 at 5:09 AM, Wang Jun <daxiawj at gmail.com> wrote:

> Hello, Everyone,
>
>     When I tried to test the eof example at
> http://opengrads.org/wiki/index.php?title=PyGrADS_Interactive_Shell
>
>     There was an error said I cannot open the netcdf file.
>
>  Can anybody tell my how to solve this problem?
>
>
Strange, it almost looks like you are loading the wrong version of udunits.
Try starting the regular grads and openbing this file:

% grads
...
ga-> sdfopen slp_djf.nc

and see if you have the same error message. Also, find the grads binary you
are using

% which grads

and run ldd on it

% ldd `which grads`

this will tell you which external libraries are being linked during runtime.
Please send us this output.


   Arlindo









> My PyGrADS is 1.1.4 and my grads is 2.0.a8 with python version 2.6.6.
>
> The error info is as follows, Thanks!:
>
> ============================================
>
> $ pygrads slp_djf.nc
>
>   Welcome to PyGrADS, a GrADS-based iPython environment.
>
> Using existing pygrads rc file <~/.pygrads/pygradsrc>
> /usr/local/lib/python2.6/dist-packages/grads/gacore.py:42:
> DeprecationWarning: The popen2 module is deprecated.  Use the subprocess
> module.
>   from popen2 import popen2
> Grid Analysis and Display System (GrADS) Version 2.0.a8
> Copyright (c) 1988-2010 by Brian Doty and the
> Institute for Global Environment and Society (IGES)
>
> Config: v2.0.a8 little-endian readline netcdf hdf5
> Issue 'q config' command for more information.
> GX Package Initialization: Size = 11 8.5
>
>    Welcome to PyGrADS, a GrADS-based iPython environment.
>    For more information, type 'help(ipygrads)'
>
> Definition of "kt" in "/usr/share/xml/udunits/udunits2-common.xml", line
> 90, overrides prefixed-unit "1000000 kilogram"
> Definition of "microns" in "/usr/share/xml/udunits/udunits2-common.xml",
> line 308, overrides prefixed-unit "1e-15 second"
> Definition of "ft" in "/usr/share/xml/udunits/udunits2-common.xml", line
> 405, overrides prefixed-unit "1e-12 kilogram"
> Definition of "yd" in "/usr/share/xml/udunits/udunits2-common.xml", line
> 413, overrides prefixed-unit "8.64e-20 second"
> Definition of "pt" in "/usr/share/xml/udunits/udunits2-common.xml", line
> 634, overrides prefixed-unit "1e-09 kilogram"
> Definition of "at" in "/usr/share/xml/udunits/udunits2-common.xml", line
> 1031, overrides prefixed-unit "1e-15 kilogram"
> Definition of "ph" in "/usr/share/xml/udunits/udunits2-common.xml", line
> 1549, overrides prefixed-unit "3.6e-09 second"
> Definition of "nt" in "/usr/share/xml/udunits/udunits2-common.xml", line
> 1556, overrides prefixed-unit "1e-06 kilogram"
> ut_get_converter(): Units not convertible
> Success
> ut_get_converter(): Couldn't get converter from seconds
> ut_get_converter(): Units in different unit-systems
> Success
> ut_get_converter(): Couldn't get converter from seconds
> ut_get_converter(): Units not convertible
> Success
> ut_get_converter(): Couldn't get converter from seconds
> Failed to open GrADS file <slp_djf.nc>
>
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr
>



-- 
Arlindo da Silva
dasilva at alum.mit.edu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20110314/0371f15f/attachment-0003.html 


More information about the gradsusr mailing list