Error :"Unsupported generic coordinates (Variable: lon)!" in changing the projection.
Added by ibomcha meitei over 3 years ago
I am trying to change the projection having lambert-conformal conic projection to regular lat-lon. I used the following codes. Here, 0.44 is the resolution of my Netcdf data
gridtype = lonlat
xsize = 148
ysize = 140
xfirst = 0
xinc = 0.44
yfirst = 0
yinc = 0.44
cdo -f nc -remapbil,new_grid.txt infile outfile
With this, I got an error as given above.
Its description is given as I couldn't attach the file [[https://tds.ucar.edu/thredds/fileServer/datazone/cordex/data/raw/NAM-44/1hr/WRF/GFDL-ESM2M/hist/pr/pr.hist.GFDL-ESM2M.WRF.1hr.NAM-44.raw.nc]]
dimensions:
y = 140;
x = 148;
time = UNLIMITED; // (490560 currently)
bnds = 2;
variables:
double lon(y=140, x=148);
:FieldType = 104; // int
:MemoryOrder = "XY ";
:description = "LONGITUDE, WEST IS NEGATIVE";
:long_name = "longitude";
:standard_name = "longitude";
:units = "degree_east";
char Lambert_Conformal;
:grid_mapping_name = "lambert_conformal_conic";
:longitude_of_central_meridian = -97.0; // double
:latitude_of_projection_origin = 46.000003814697266; // double
:standard_parallel = 35.0, 60.0; // double
double lat(y=140, x=148);
:standard_name = "latitude";
:long_name = "latitude";
:units = "degree_north";
:FieldType = 104; // int
:MemoryOrder = "XY ";
:description = "LATITUDE, SOUTH IS NEGATIVE";
float pr(time=490560, y=140, x=148);
:standard_name = "precipitation_flux";
:long_name = "Precipitation";
:units = "kg m-2 s-1";
:grid_type = "lcc2";
:grid_mapping = "Lambert_Conformal";
:_FillValue = 1.0E20f; // float
:missing_value = 1.0E20f; // float
:FieldType = 104; // int
:MemoryOrder = "XY ";
:cell_methods = "time: mean(interval: 1h)";
:description = "(var(time) - var(time-1))/1800.";
:original_name = "RAINC+RAINNC";
:original_units = "mm";
double time(time=490560);
:standard_name = "time";
:long_name = "time";
:bounds = "time_bnds";
:units = "days since 1949-12-1 00:00:00";
:calendar = "standard";
:axis = "T";
:cell_methods = "time: mean";
double time_bnds(time=490560, bnds=2);
:cell_methods = "time: mean";
double x(x=148);
:long_name = "x-coordinate in Cartesian system";
:units = "m";
:axis = "X";
double y(y=140);
:long_name = "x-coordinate in Cartesian system";
:units = "m";
:axis = "Y";
I will be grateful if anyone could help me out.
Thanks
Replies (1)
RE: Error :"Unsupported generic coordinates (Variable: lon)!" in changing the projection. - Added by Uwe Schulzweida over 3 years ago
You should add the coordinates attribute to use the existing geographic coordinates lon and lat for the interpolation:
ncatted -a coordinates,pr,c,c,"lon lat" filename.nc