Project

General

Profile

cdo sinfov

Added by e ddc almost 13 years ago

Hello,

I get this message when using cdo sinfov on the file sic_O1b_BCM2_20c3m_r1_1850-1999_190001-199912.nc

+ cdo sinfov sic_O1b_BCM2_20c3m_r1_1850-1999_190001-199912.nc
Warning (scanVarAttributes) : NetCDF: Variable not found - time_bnds
cdo sinfon: Open failed on >sic_O1b_BCM2_20c3m_r1_1850-1999_190001-199912.nc<
Unsupported file structure

is that the expected behaviour or can it be considered a bug?

Thanking you in advance.

Have a nice day.

Regards

Eduardo

ncdump -h sic_O1b_BCM2_20c3m_r1_1850-1999_190001-199912.nc gives

netcdf sic_O1b_BCM2_20c3m_r1_1850-1999_190001-199912 {
dimensions:
time = UNLIMITED ; // (1200 currently)
variables:
double time(time) ;
time:long_name = "time" ;
time:units = "days since 1800-01-01 00:0.0" ;
time:calendar = "gregorian" ;
time:standard_name = "time" ;
time:bounds = "time_bnds" ;
time:axis = "T" ;

// global attributes:
:title = "BCCR model output prepared for IPCC Fourth\n",
"Assessment Report climate of the 20th Century\n",
"experiment (20C3M)" ;
:history = "Wed May 11 09:42:20 2011: ncks O -C -v time -d time,1900-1-1,1999-12-31 /disks/fuse/cmip3_drs_1/output/BCCR/BCM2/20c3m/mon/sea
Ice/sic/r1/v1/sic_O1b_BCM2_20c3m_r1_1850-1999.nc sic_O1b_BCM2_20c3m_r1_1850-1999_190001-199912.nc\n",
"Created from MICOM output using BCM post
\n",
"processing tools:sigma2z > vertical interpolation\n",
"(linear) from isopycnic layer coordinates to\n",
"standard levels.uvrot -> vector rotation to east,\n",
"north directions.gen2reg -> horizontal\n",
"interpolation (linear, gaussian weights) from\n",
"original curvlinear grid to regular longitude/\n",
"latitude grid." ;
:source = "BCM2.0, (2005): atmosphere: ARPEGE V3 T63L31\n",
"(cy 22b+); ocean : NERSC-MICOM V1.0 (based on\n",
"MICOM V2.8), 35 vertical layers, 1.5(E-W) X\n",
"0.5(N-S) deg. res. near equator with gradual\n",
"transformation to square grid cells away from\n",
"equator; sea ice : NERSC Sea Ice Model (Viscous
\n",
"plastic + thermodynamic), 4 gridcells per ocean\n",
"grid cell; land : ISBA ARPEGE V3 version" ;
:references = "www.bcm.uib.no" ;
:comment = "Experiment was initiated from model year 85\n",
"(nominal year 1850) of the control simulation\n",
"(with bcm_experiment_name: PC3). The time varying\n",
"forcing agents were varied based upon observations\n",
"and reconstructions for the late 19th and 20th\n",
"centuries. Varying forcing agents: CO2,CH4,N2O,\n",
"CFC11,CFC12 and\n",
"sulfate aerosols (Boucher data, only direct\n",
"effect). Non-varying forcing agents: Background\n",
"aerosols: black carbon,sea salt,desert dust,\n",
"stratospheric and tropospheric ozone, solar\n",
"irradiance (1368 W/m2) and the distribution of\n",
"land cover types. No volcanic aerosols. No heat or\n",
"fresh water adjustments." ;
:project_id = "IPCC Fourth Assessment" ;
:experiment_id = "climate of the 20th Century experiment (20C3M)" ;
:realization = 1 ;
:bcm_experiment_name = "PT3" ;
:institution = "BCCR (Bjerknes Centre for Climate Research)\n",
"University of Bergen, Norway (www.bjerknes.uib.no)\n",
"NERSC (Nansen Environmental and Remote Sensing\n",
"Center, Norway (www.nersc.no)" ;
:contact = "Email: bcm@uib.no, WWW: www.bcm.uib.no" ;
:acknowledgment = "Use of BCM data should acknowledge the\n",
"contribution of the BCM project and BCM sponsor\n",


Replies (6)

RE: cdo sinfov - Added by Uwe Schulzweida almost 13 years ago

Hi Eduardo,

Yes, thats the expected behaviour!
CDO can process only data variables and all associated coordinate variables of a netCDF file. This file does not contain a data variable and therefore it can't be opened/processed with CDO.

Best regards,
Uwe

RE: cdo sinfov - Added by e ddc almost 13 years ago

Hi Uwe,

Ok.
However, ncdump shows that time is a variable even with attributes ;).
Best regards

Eduardo

RE: cdo sinfov - Added by Uwe Schulzweida almost 13 years ago

Yes, time is a coordinate variable but there is no data variable which uses this coordinate variable.

RE: cdo sinfov - Added by e ddc almost 13 years ago

Hi Uwe

I am sorry to insist.
In fact I do not want to take your time with such a minor point.
Fell free to do not answer. I will try to sort out this for myself.

If you have some time to help me to improve my understanding of netCDF, please continue to read.

I am probably misunderstanding the difference between data and coordinate variables, but, for the file above, in my view, there are both, even if they have the same name (shown by the ncdump (first post)).
Suppose I rename time using :

ncrename -v time,temps

I then get using ncdump :

dimensions:
time = UNLIMITED ; // (1200 currently)
variables:
double temps(time) ;

Now, do you agree that
1)temps is a data variable
2)time a coordinate
3)temps is a data variable that uses the coordinate named time
or am i missing something ?

Regards

Eduardo

RE: cdo sinfov - Added by Uwe Schulzweida almost 13 years ago

The name of a variables is not always decisive. The attributes of the variable usually makes the difference between coordinates and data variables. In your example all attributes (expecially: units and axis) of the variable temps indicates a time coordinate variable. The name of the dimensions is irrelevant in this context. temps would be a data variable if you delete also the attributes.

Best regards,
Uwe

RE: cdo sinfov - Added by e ddc almost 13 years ago

Hi Uwe
Thank you for your reply.
I think I have put some time discussing this minor point because I have some scripts that relies on CDO sinfov and is annoying when CDO is unable to describe what it is in the netcdf file.
Suppose you delete all attributes of the variable temps. I have done it using nccated. In some sense there is no way to know if temps is a data variable or a coordinate. Even then the cdo sinfov output is "Unsupported file structure". I know that it is hard to be at the same time flexible allowing users a lot of freedom and respecting standards insuring cross compatibility. I think that the solution here is using anther tool and not to demand to cdo sinfov to give a result for which it is not design to: even if I have the filling that cdo sinfov might be improved providing some information about the netcdf file even if that file is not standard.
Thanking you again,
Best regards
Eduardo

    (1-6/6)