Project

General

Profile

missing attributes using mergetime and splityear

Added by Laura Zamboni almost 12 years ago

Hello,

I have many 2.5 years Netcdf files that I need to re-arrange into yearly files.

By doing:
cdo mergetime file1.nc file2.nc tmp.nc #merges file1.nc and file2.nc (2.5-year files) in 1 file
cdo splityear tmp.nc Yatmos_month.tile1.nc #splits the tmp.nc (5-year file) in 5 yearly

I get the following warning:
Warning (cdfInqContents) : calendar >julian< unsupported!

and certain attributes on variable "time" are missing, as follows

INPUT FILE:
double time(time) ;
time:long_name = "time" ;
time:units = "days since 1950-01-01 00:00:00" ;
time:cartesian_axis = "T" ;
time:calendar_type = "JULIAN" ;
time:calendar = "JULIAN" ;

OUTPUT FILE:
double time(time) ;
time:units = "days since 1950-01-01 00:00:00" ;
time:calendar = "standard" ;
I am using cdo-1.4.7

Thank you!
Laura


Replies (5)

RE: missing attributes using mergetime and splityear - Added by Jaison-Thomas Ambadan almost 12 years ago

Hi Laura,

1. If you could upload a sample of your data, that would be great; it may help the CDO guys here to identify the problem a bit faster! If the file size is > 50MB, you may select a very small geographical region (1-2 time & levels) using "cdo -sellonlatbox".

2. Also, please post the output of "cdo -V"

Cheers,
J.

RE: missing attributes using mergetime and splityear - Added by Laura Zamboni almost 12 years ago

Hi Jaison,

yes, my files are way larger than 50MB. Following your suggestion I ran into the following problem:

cdo sellonlatbox,120,5,10,0 ../19500101/atmos_daily.tile1.nc atmos_daily_box.nc

Warning (cdfInqContents) : calendar >julian< unsupported!
cdo sellonlatbox: Unsupported grid type: generic

cdo sellonlatbox (Abort): Unsupported grid type!

-in the mean time I updated cdo, so I am now using version

the result of cdo -V is:

cdo -V

Climate Data Operators version 1.5.5 (http://code.zmaw.de/projects/cdo)
Compiler: gcc -std=gnu99 -g -O2 -pthread
version: gcc (GCC) 4.1.2 20070115 (SUSE Linux)
with: PTHREADS Z
Compiled: by acherry on login1 (x86_64-unknown-linux-gnu) May 23 2012 17:47:27
CDI library version : 1.5.5 of May 23 2012 17:47:16
CGRIBEX library version : 1.5.2 of May 11 2012 14:32:49
netCDF library version : 4.1.2-beta2-snapshot2010102020 of Mar 4 2011 23:33:30 $
HDF5 library version : 1.8.5
SERVICE library version : 1.3.0 of May 23 2012 17:47:01
EXTRA library version : 1.3.0 of May 23 2012 17:46:56
IEG library version : 1.3.0 of May 23 2012 17:46:59
FILE library version : 1.8.0 of May 23 2012 17:46:56

Thanks!
Laura

RE: missing attributes using mergetime and splityear - Added by Jaison-Thomas Ambadan almost 12 years ago

Hi Laura,

Unfortunately, it seems that CDO only support "standard, proleptic, 360days, 365days, 366days" calendars and NOT Julian at the moment (as far as I understand); so you may have to depend on other tools (such as GrADS or NCL) to convert the calendar and then use CDO

Cheers,
J.

PS: Neverthless, you may request a new "feature" to support Julian calender (in the "issues" section of this webpage - you have to login first)

RE: missing attributes using mergetime and splityear - Added by Laura Zamboni almost 12 years ago

To clarify, the grid is that of the climate model: cubed sphere.
(hopefully this makes sense to you)
Thanks!
Laura

RE: missing attributes using mergetime and splityear - Added by Jaison-Thomas Ambadan almost 12 years ago

Hi,

sorry, in my last-reply, I was referring to the warning message in your first post (regarding time attributes)

Warning (cdfInqContents) : calendar >julian< unsupported!

It looks like, although merge/split operation gave an output, it changed the calender type from Julian to standard.

Anyway since you mentioned that your data is from "cubed sphere" (unstructured grid?), sellonlatbox won't work on the original data. However, you may try converting your data to NetCDF cell (using "-setgridtype,cell") format and try the sellonlatbox again, i.e.,

cdo sellonlatbox,120,5,10,0 -setgridtype,cell ../19500101/atmos_daily.tile1.nc atmos_daily_box.nc

Cheers,
J.

    (1-5/5)