[netcdfgroup] Failure accessing an HYRAX OpenDAP server...

Hi all,

We're trying to use the netCDF4 python lib to access data on an what I
thikn is a HYRAX server. It can create the Dataset object seemingly fine,
and creates a variabel object fine -- but then gives me:

RuntimeError: NetCDF: file not found

when I try to extract some data from the variable.

Noett hat this seems to work fien with PyDAP -- so maybe that means that
it's a netcdf lib problem, rather than a HYRAX problem.

But I have no idea how to debug this

I'm using a pretty recent version of the netcdf lib:

In [8]: netCDF4.getlibversion()
Out[8]: u'4.4.1 of Aug 10 2016 18:32:53 $'

though the failure is the same with older versions as well. (and both on
Windows and OS-X so far...)

I've enclosed a small python script that demonstrates the problem -- the
problem url is in the script.

Thanks for any hints!

-CHB



-- 

Christopher Barker, Ph.D.
Oceanographer

Emergency Response Division
NOAA/NOS/OR&R            (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

Chris.Barker@xxxxxxxx
# Example of  failed requet from a HYRAX server

from netCDF4 import Dataset
nc = 
Dataset('http://ingria.coas.oregonstate.edu:80/opendap/aggregation/ocean_time_aggregation.ncml')

print("Dataset loaded OK")

u = nc.variables['u']

print("Successfully Extracted a varaible object:")
print(u)

u_shape = u.shape  # this works ok
print("The variable object is seemingly valid:")
print("the shape is %s" % (u_shape,))

print("but I can't extract the actual data")

u_data = u[0, 0, 0:10, 0:10:]  # this does not work--"RuntimeError: NetCDF: 
file not found"
  • 2016 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the netcdfgroup archives: