[Thread Prev][Thread Next][Index]

netCDF file errors



Ferreters,

I'm a bit stomped with ferret complaining about a netCDF file
produced by a fortran program (which took days to write if I
remember correctly...) I've used this code in the past to read
binary dumps from model output. However, until now the domain
of my runs was of the North Pacific whereas the data I'm
using now is from a global domain. I should also mention that
the binary dumps are produced by a little endian machine. 
Previouly, I compiled the fortran code under DEC UNIX and 
asked the compiler to do byte swapping (since DEC is big endian).
This worked fine for the Pacific domains. Nonetheless, I have
had no luck running the same code on the same machine for the
global data dumps (A segmentation fault occurrs immediately). 

I decided that it might be best anyway to compile and run the code
on a SUN (little endian) with no byte swapping. This would read the
binary dumps produced by a machine of the same architecture (a
CM500). Compilation and running proceeds without error messages
leaving me with the desired netCDF file.

BUT... here's the catch. Upon asking ferret to read the netCDF
file I get the following:

yes? use global
 error in netCDF file
 More than one record dimension in "slab_min_index": ub

ub is a barotropic variable and has dimension k=1:1. Although
its grid definition is 4D, there is only one layer in these
variables. Here's the header info from an ncdump:

netcdf tmp {
dimensions:
        xz = 1080 ;
        xh = 1080 ;
        yh = 384 ;
        yz = 384 ;
        layer = 10 ;
        time = UNLIMITED ; // (1 currently)
        grid_definition = 1 ;
variables:
        float xz(xz) ;
                xz:units = "degrees" ;
                xz:point_spacing = "even" ;
        float xh(xh) ;
                xh:units = "degrees" ;
                xh:point_spacing = "even" ;
        float yh(yh) ;
                yh:units = "degrees" ;
                yh:point_spacing = "even" ;
        float yz(yz) ;
                yz:units = "degrees" ;
                yz:point_spacing = "even" ;
        float layer(layer) ;
                layer:units = "layer~" ;
                layer:positive = "down" ;
        float time(time) ;
                time:units = "days" ;
        char u_grid(grid_definition) ;
                u_grid:axes = "xz yh layer time" ;
        char v_grid(grid_definition) ;
                v_grid:axes = "xh yz layer time" ;
        char h_grid(grid_definition) ;
                h_grid:axes = "xh yh layer time" ;
        char z_grid(grid_definition) ;
                z_grid:axes = "xz yz layer time" ;
        char ub_grid(grid_definition) ;
                ub_grid:axes = "xz yh normal time" ;
        char vb_grid(grid_definition) ;
                vb_grid:axes = "xh yz normal time" ;
        char hb_grid(grid_definition) ;
                hb_grid:axes = "xh yh normal time" ;
        float up(time, layer, yh, xz) ;
                up:long_name = "Baroclinic zonal velocity" ;
                up:units = "m/sec" ;
                up:slab_min_index = 0s, 1s, 0s, 1s ;
                up:slab_max_index = 0s, 1080s, 0s, 384s ;
...
        float ub(time, yh, xz) ;
                ub:long_name = "Barotropic zonal velocity" ;
                ub:units = "m/sec" ;
                ub:parent_grid = "ub_grid@" ;
                ub:slab_min_index = 0s, 1s, 0s, 1s ;
                ub:slab_max_index = 0s, 1080s, 0s, 384s ;



The dilemma: Does this seem like an error in the netCDF libraries? What
else could this be caused by? Any ideas on why the DEC compiled binary
would produce a segmentation fault at runtime (it happens immediately)?

Any advice or tips would be appreciated.

Thanks, David.

*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*
David Oxilia			Tel: (541) 737-2368
COAS:Oregon State University	Fax: (541) 737-2064
Ocean Admin. Bldg. 104		Email: oxilia@oce.orst.edu
Corvallis, OR 97331-5503	WWW: http://www.oce.orst.edu/po
*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*


[Thread Prev][Thread Next][Index]

Dept of Commerce / NOAA / OAR / PMEL / TMAP

Contact Us | Privacy Policy | Disclaimer | Accessibility Statement