Project

General

Profile

sellonlatbox fails in setting correct time to grib files - cdo 1.5.3

Added by Marco Galli almost 12 years ago

Dear all,
I'm writing to report what, in my opinion, is a very strange behaviour of cdo.
I'm trying to select a spatial subdomain of a grib file, using the command:

cdo sellonlatbox,23,31,-25,-31 t2m_ei_1979.grb tagliato_t2m_ei_1979.grb

The input file consists of some t2m fields valid at different forecast times (from +3 to +12 hours), starting from different reference times (every 12 hours).
If I execute the above command with cdo 1.5.3, I get as output a file containing the spatial subset which I expect, but the information of the forecast time is completely lost. In fact, what I get in output contains the same number of fields, but all valid at the same reference time (the one of the analysis of the forecast of the input file); moreover, the output grib messages are reported as analysis rather than forecasts.
The problem is not encountered when the sameabove command is executed using an older version of cdo (I tried the 1.4.6); the output, in this case, is exactly what I expected to be, with the time information unchanged.
I checked these issues using wgrib and the grib_api tools. Here I'm posting a sample output of the wgrib command in the 1.5.3 case and in the 1.4.6 one:

1.5.3:
1:0:D=1979010100:2T:sfc:kpds=167,1,0:anl:type=analysis:winds are N/S:"2 metre temperature [K]
2:1758:D=1979010100:2T:sfc:kpds=167,1,0:anl:type=analysis:winds are N/S:"2 metre temperature [K]
3:3516:D=1979010100:2T:sfc:kpds=167,1,0:anl:type=analysis:winds are N/S:"2 metre temperature [K]
4:5274:D=1979010100:2T:sfc:kpds=167,1,0:anl:type=analysis:winds are N/S:"2 metre temperature [K]
5:7032:D=1979010112:2T:sfc:kpds=167,1,0:anl:type=analysis:winds are N/S:"2 metre temperature [K]
6:8790:D=1979010112:2T:sfc:kpds=167,1,0:anl:type=analysis:winds are N/S:"2 metre temperature [K]
7:10548:D=1979010112:2T:sfc:kpds=167,1,0:anl:type=analysis:winds are N/S:"2 metre temperature [K]
8:12306:D=1979010112:2T:sfc:kpds=167,1,0:anl:type=analysis:winds are N/S:"2 metre temperature [K]

1.4.6:
1:0:D=1979010100:2T:sfc:kpds=167,1,0:3hr fcst:winds are N/S:"2 metre temperature [K]
2:1736:D=1979010100:2T:sfc:kpds=167,1,0:6hr fcst:winds are N/S:"2 metre temperature [K]
3:3472:D=1979010100:2T:sfc:kpds=167,1,0:9hr fcst:winds are N/S:"2 metre temperature [K]
4:5208:D=1979010100:2T:sfc:kpds=167,1,0:12hr fcst:winds are N/S:"2 metre temperature [K]
5:6944:D=1979010112:2T:sfc:kpds=167,1,0:3hr fcst:winds are N/S:"2 metre temperature [K]
6:8680:D=1979010112:2T:sfc:kpds=167,1,0:6hr fcst:winds are N/S:"2 metre temperature [K]
7:10416:D=1979010112:2T:sfc:kpds=167,1,0:9hr fcst:winds are N/S:"2 metre temperature [K]
8:12152:D=1979010112:2T:sfc:kpds=167,1,0:12hr fcst:winds are N/S:"2 metre temperature [K]

Does anyone has any idea about that? Is it possible this is a bug in cdo? Does it exist a new release of cdo without this bug?
Thanks for the help.

Best regards
Marco

t2m_ei_1979.grb (36.8 MB) t2m_ei_1979.grb Original big domain datafile
tagliato_t2m_ei_1979_cdo-1.4.6.grb (4.83 MB) tagliato_t2m_ei_1979_cdo-1.4.6.grb cdo 1.4.6 cut file - time information correct
tagliato_t2m_ei_1979_cdo-1.5.3.grb (4.9 MB) tagliato_t2m_ei_1979_cdo-1.5.3.grb cdo 1.5.3 cut file - time information lost

Replies (4)

RE: sellonlatbox fails in setting correct time to grib files - cdo 1.5.3 - Added by Uwe Schulzweida almost 12 years ago

Dear Marco,

We can't reproduce this bug. I checked your example with CDO version 1.4.6, 1.5.2, 1.5.3, 1.5.4 and 1.5.5 on different machines and got always the same correct result. So there is nothing what we can do to solve this problem. Could you please sent us also the result of "cdo -V". Maybe we find a machine with the same compiler as yours.

Best regards,
Uwe

RE: sellonlatbox fails in setting correct time to grib files - cdo 1.5.3 - Added by Marco Galli almost 12 years ago

Dear Uwe, I'm actually using two different combinations of machines and compilers.

The output of "cdo -V" in the 1.5.3 case is:

Climate Data Operators version 1.5.3 (http://code.zmaw.de/projects/cdo)
Compiler: mpicc -std=gnu99 -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -Werror=format-security -fPIC
version: gcc: error: unrecognized option '-V'
with: PTHREADS Z JASPER PROJ.4
Compiled: by buildd on roseapple (i686-pc-linux-gnu) Dec 12 2011 14:14:57
CDI library version : 1.5.3 of Dec 12 2011 14:14:52
GRIB_API library version : 1.9.9
netCDF library version : 4.1.1 of Nov 7 2011 11:30:05 $
HDF5 library version : 1.8.4
SERVICE library version : 1.3.0 of Dec 12 2011 14:14:39
EXTRA library version : 1.3.0 of Dec 12 2011 14:14:35
IEG library version : 1.3.0 of Dec 12 2011 14:14:38
FILE library version : 1.7.1 of Dec 12 2011 14:14:35

used on a machine whose characteristics are:
Linux ubuntu 3.2.0-25-generic-pae #40-Ubuntu SMP Wed May 23 22:11:24 UTC 2012 i686 i686 i386 GNU/Linux

In the other case, for the 1.4.6 installation, the cdo characteristics are:

Climate Data Operators version 1.4.6 (http://code.zmaw.de/projects/cdo)
Compiler: gcc -std=gnu99 -g -O2
version: gcc (Debian 4.3.2-1.1) 4.3.2
with: PTHREADS Z
Compiled: by mmanfrin on ph74xl (i686-pc-linux-gnu) Dec 13 2010 11:08:00
CDI library version : 1.4.6 of Dec 13 2010 11:07:48
CGRIBEX library version : 1.4.6 of Sep 15 2010 08:38:12
netCDF library version : 4.1.1 of Nov 5 2010 15:04:56 $
SERVICE library version : 1.2.0 of Dec 13 2010 11:07:33
EXTRA library version : 1.2.0 of Dec 13 2010 11:07:28
IEG library version : 1.2.0 of Dec 13 2010 11:07:32
FILE library version : 1.7.0 of Dec 13 2010 11:07:29

This installation has been performed on a computer that is:
Linux debian 2.6.26-2-686-bigmem #1 SMP Sun Mar 4 23:05:22 UTC 2012 i686 GNU/Linux

I really have no clues why my problem comes out...

Best regards
Marco

RE: sellonlatbox fails in setting correct time to grib files - cdo 1.5.3 - Added by Uwe Schulzweida almost 12 years ago

Dear Marco,

Your CDO version 1.5.3 is not using the CDO internal GRIB1 library CGRIBEX. I'm sure thats the reason for the different results.
If the internal GRIB1 library is disabled with the configure option "--disable-cgribex" than the GRIB_API is used to encode/decode GRIB1 messages. Unfortunately the support for GRIB1 with GRIB_API in CDO is only in an experimental state.
The solution for this problem is to create a CDO version with "--enable-cgribex".

Best regards,
Uwe

RE: sellonlatbox fails in setting correct time to grib files - cdo 1.5.3 - Added by Marco Galli almost 12 years ago

Dear Uwe,
thank you very much for the hint. Sorry for replying so late...

Best regards,
Marco

    (1-4/4)