cdo remapbil (Abort): Unsupported grid type: generic
Added by Laura Jackson almost 7 years ago
I'm trying to remap a 2 dimensional field with 2d lat and lon coordinates to a regular 0.5x0.5 degree field using
cdo remapbil,r720x360 filein.nc fileout.nc
but am getting the error
cdo remapbil (Abort): Unsupported grid type: generic
I've added the lat and lon to the coordinates (which seems to be the first thing that comes up with a google search of this error) so the file contents (with a ncdump -h) are
netcdf filein {
dimensions:
i = 360 ;
j = 270 ;
variables:
double barotropic_streamfunction(j, i) ;
barotropic_streamfunction:coordinates = "Lon Lat" ;
double Lon(j, i) ;
double Lat(j, i) ;
// global attributes:
:history = "Mon Mar 26 17:18:23 2018: /project/ukmo/rhel6/nco/bin/ncatted -a coordinates,barotropic_streamfunction,c,c,Lon Lat ECCO_Btp_streamf_avg_small.nc" ;
}
but it's still giving the same error. I'm attaching the file - any suggestions of how to fix this please? Thanks
Replies (3)
RE: cdo remapbil (Abort): Unsupported grid type: generic - Added by Ralf Mueller almost 7 years ago
Hi Laura!
although you use the coordinates
attribute for your data variable, you need to follow the CF-convention for coordinates, too. A good example can be found here: http://cfconventions.org/Data/cf-conventions/cf-conventions-1.7/build/ch05.html
basically lon and lat need to have the right units
and long_name
. you can add them using ncatted
just like you did it for coordinates
.
hth
ralf
RE: cdo remapbil (Abort): Unsupported grid type: generic - Added by Laura Jackson almost 7 years ago
Great thanks! That's fixed it
RE: cdo remapbil (Abort): Unsupported grid type: generic - Added by Ralf Mueller almost 7 years ago
well, then happy CDOing to the UK ;-)