How to regrid a netCDF using bilinear interpolation?

此生再无相见时 提交于 2020-01-17 04:28:06

问题


I am looking for a procedure to apply bilinear interpolation to change the resolution of netCDF file (1.5°x1.5°) ---> (1.25°x0.9375°)

Edit:

I have been reading some pages and I found a function called remapbil. It comes from Climate Data Operator (CDO). I tried to do the regrid but it did not work. This is my netCDF file info:

    File format: netCDF
    -1 : Institut Source   Ttype    Levels Num  Gridsize Num Dtype : Parameter name
     1 : unknown  unknown  instant       1   1       180   1  I16  : tp            
   Grid coordinates :
     1 : lonlat       > size      : dim = 180  nx = 12  ny = 15
                        longitude : first = 279  last = 295.5  inc = 1.5  degrees_east
                        latitude  : first = 15  last = -6  inc = -1.5  degrees_north
   Vertical coordinates :
     1 : surface                  : 0 
   Time coordinate :  324 steps
     RefTime =  1900-01-01 00:00:00  Units = hours  Calendar = standard
  YYYY-MM-DD hh:mm:ss  YYYY-MM-DD hh:mm:ss  YYYY-MM-DD hh:mm:ss  YYYY-MM-DD hh:mm:ss
  1979-01-01 03:00:00  1979-02-01 03:00:00  1979-03-01 03:00:00  1979-04-01 03:00:00
  1979-05-01 03:00:00  1979-06-01 03:00:00  1979-07-01 03:00:00  1979-08-01 03:00:00
  1979-09-01 03:00:00  1979-10-01 03:00:00  1979-11-01 03:00:00  1979-12-01 03:00:00
  1980-01-01 03:00:00  1980-02-01 03:00:00  1980-03-01 03:00:00  1980-04-01 03:00:00
  1980-05-01 03:00:00  1980-06-01 03:00:00  1980-07-01 03:00:00  1980-08-01 03:00:00
  1980-09-01 03:00:00  1980-10-01 03:00:00  1980-11-01 03:00:00  1980-12-01 03:00:00
  1981-01-01 03:00:00  1981-02-01 03:00:00  1981-03-01 03:00:00  1981-04-01 03:00:00
  1981-05-01 03:00:00  1981-06-01 03:00:00  1981-07-01 03:00:00  1981-08-01 03:00:00
  1981-09-01 03:00:00  1981-10-01 03:00:00  1981-11-01 03:00:00  1981-12-01 03:00:00
  1982-01-01 03:00:00  1982-02-01 03:00:00  1982-03-01 03:00:00  1982-04-01 03:00:00
  1982-05-01 03:00:00  1982-06-01 03:00:00  1982-07-01 03:00:00  1982-08-01 03:00:00
  1982-09-01 03:00:00  1982-10-01 03:00:00  1982-11-01 03:00:00  1982-12-01 03:00:00
  1983-01-01 03:00:00  1983-02-01 03:00:00  1983-03-01 03:00:00  1983-04-01 03:00:00
  1983-05-01 03:00:00  1983-06-01 03:00:00  1983-07-01 03:00:00  1983-08-01 03:00:00
  1983-09-01 03:00:00  1983-10-01 03:00:00  1983-11-01 03:00:00  1983-12-01 03:00:00
  1984-01-01 03:00:00  1984-02-01 03:00:00  1984-03-01 03:00:00  1984-04-01 03:00:00
  1984-05-01 03:00:00  1984-06-01 03:00:00  1984-07-01 03:00:00  1984-08-01 03:00:00
  1984-09-01 03:00:00  1984-10-01 03:00:00  1984-11-01 03:00:00  1984-12-01 03:00:00
  1985-01-01 03:00:00  1985-02-01 03:00:00  1985-03-01 03:00:00  1985-04-01 03:00:00
  1985-05-01 03:00:00  1985-06-01 03:00:00  1985-07-01 03:00:00  1985-08-01 03:00:00
  1985-09-01 03:00:00  1985-10-01 03:00:00  1985-11-01 03:00:00  1985-12-01 03:00:00
  1986-01-01 03:00:00  1986-02-01 03:00:00  1986-03-01 03:00:00  1986-04-01 03:00:00
  1986-05-01 03:00:00  1986-06-01 03:00:00  1986-07-01 03:00:00  1986-08-01 03:00:00
  1986-09-01 03:00:00  1986-10-01 03:00:00  1986-11-01 03:00:00  1986-12-01 03:00:00
  1987-01-01 03:00:00  1987-02-01 03:00:00  1987-03-01 03:00:00  1987-04-01 03:00:00
  1987-05-01 03:00:00  1987-06-01 03:00:00  1987-07-01 03:00:00  1987-08-01 03:00:00
  1987-09-01 03:00:00  1987-10-01 03:00:00  1987-11-01 03:00:00  1987-12-01 03:00:00
  1988-01-01 03:00:00  1988-02-01 03:00:00  1988-03-01 03:00:00  1988-04-01 03:00:00
  1988-05-01 03:00:00  1988-06-01 03:00:00  1988-07-01 03:00:00  1988-08-01 03:00:00
  1988-09-01 03:00:00  1988-10-01 03:00:00  1988-11-01 03:00:00  1988-12-01 03:00:00
  1989-01-01 03:00:00  1989-02-01 03:00:00  1989-03-01 03:00:00  1989-04-01 03:00:00
  1989-05-01 03:00:00  1989-06-01 03:00:00  1989-07-01 03:00:00  1989-08-01 03:00:00
  1989-09-01 03:00:00  1989-10-01 03:00:00  1989-11-01 03:00:00  1989-12-01 03:00:00
  1990-01-01 03:00:00  1990-02-01 03:00:00  1990-03-01 03:00:00  1990-04-01 03:00:00
  1990-05-01 03:00:00  1990-06-01 03:00:00  1990-07-01 03:00:00  1990-08-01 03:00:00
  1990-09-01 03:00:00  1990-10-01 03:00:00  1990-11-01 03:00:00  1990-12-01 03:00:00
  1991-01-01 03:00:00  1991-02-01 03:00:00  1991-03-01 03:00:00  1991-04-01 03:00:00
  1991-05-01 03:00:00  1991-06-01 03:00:00  1991-07-01 03:00:00  1991-08-01 03:00:00
  1991-09-01 03:00:00  1991-10-01 03:00:00  1991-11-01 03:00:00  1991-12-01 03:00:00
  1992-01-01 03:00:00  1992-02-01 03:00:00  1992-03-01 03:00:00  1992-04-01 03:00:00
  1992-05-01 03:00:00  1992-06-01 03:00:00  1992-07-01 03:00:00  1992-08-01 03:00:00
  1992-09-01 03:00:00  1992-10-01 03:00:00  1992-11-01 03:00:00  1992-12-01 03:00:00
  1993-01-01 03:00:00  1993-02-01 03:00:00  1993-03-01 03:00:00  1993-04-01 03:00:00
  1993-05-01 03:00:00  1993-06-01 03:00:00  1993-07-01 03:00:00  1993-08-01 03:00:00
  1993-09-01 03:00:00  1993-10-01 03:00:00  1993-11-01 03:00:00  1993-12-01 03:00:00
  1994-01-01 03:00:00  1994-02-01 03:00:00  1994-03-01 03:00:00  1994-04-01 03:00:00
  1994-05-01 03:00:00  1994-06-01 03:00:00  1994-07-01 03:00:00  1994-08-01 03:00:00
  1994-09-01 03:00:00  1994-10-01 03:00:00  1994-11-01 03:00:00  1994-12-01 03:00:00
  1995-01-01 03:00:00  1995-02-01 03:00:00  1995-03-01 03:00:00  1995-04-01 03:00:00
  1995-05-01 03:00:00  1995-06-01 03:00:00  1995-07-01 03:00:00  1995-08-01 03:00:00
  1995-09-01 03:00:00  1995-10-01 03:00:00  1995-11-01 03:00:00  1995-12-01 03:00:00
  1996-01-01 03:00:00  1996-02-01 03:00:00  1996-03-01 03:00:00  1996-04-01 03:00:00
  1996-05-01 03:00:00  1996-06-01 03:00:00  1996-07-01 03:00:00  1996-08-01 03:00:00
  1996-09-01 03:00:00  1996-10-01 03:00:00  1996-11-01 03:00:00  1996-12-01 03:00:00
  1997-01-01 03:00:00  1997-02-01 03:00:00  1997-03-01 03:00:00  1997-04-01 03:00:00
  1997-05-01 03:00:00  1997-06-01 03:00:00  1997-07-01 03:00:00  1997-08-01 03:00:00
  1997-09-01 03:00:00  1997-10-01 03:00:00  1997-11-01 03:00:00  1997-12-01 03:00:00
  1998-01-01 03:00:00  1998-02-01 03:00:00  1998-03-01 03:00:00  1998-04-01 03:00:00
  1998-05-01 03:00:00  1998-06-01 03:00:00  1998-07-01 03:00:00  1998-08-01 03:00:00
  1998-09-01 03:00:00  1998-10-01 03:00:00  1998-11-01 03:00:00  1998-12-01 03:00:00
  1999-01-01 03:00:00  1999-02-01 03:00:00  1999-03-01 03:00:00  1999-04-01 03:00:00
  1999-05-01 03:00:00  1999-06-01 03:00:00  1999-07-01 03:00:00  1999-08-01 03:00:00
  1999-09-01 03:00:00  1999-10-01 03:00:00  1999-11-01 03:00:00  1999-12-01 03:00:00
  2000-01-01 03:00:00  2000-02-01 03:00:00  2000-03-01 03:00:00  2000-04-01 03:00:00
  2000-05-01 03:00:00  2000-06-01 03:00:00  2000-07-01 03:00:00  2000-08-01 03:00:00
  2000-09-01 03:00:00  2000-10-01 03:00:00  2000-11-01 03:00:00  2000-12-01 03:00:00
  2001-01-01 03:00:00  2001-02-01 03:00:00  2001-03-01 03:00:00  2001-04-01 03:00:00
  2001-05-01 03:00:00  2001-06-01 03:00:00  2001-07-01 03:00:00  2001-08-01 03:00:00
  2001-09-01 03:00:00  2001-10-01 03:00:00  2001-11-01 03:00:00  2001-12-01 03:00:00
  2002-01-01 03:00:00  2002-02-01 03:00:00  2002-03-01 03:00:00  2002-04-01 03:00:00
  2002-05-01 03:00:00  2002-06-01 03:00:00  2002-07-01 03:00:00  2002-08-01 03:00:00
  2002-09-01 03:00:00  2002-10-01 03:00:00  2002-11-01 03:00:00  2002-12-01 03:00:00
  2003-01-01 03:00:00  2003-02-01 03:00:00  2003-03-01 03:00:00  2003-04-01 03:00:00
  2003-05-01 03:00:00  2003-06-01 03:00:00  2003-07-01 03:00:00  2003-08-01 03:00:00
  2003-09-01 03:00:00  2003-10-01 03:00:00  2003-11-01 03:00:00  2003-12-01 03:00:00
  2004-01-01 03:00:00  2004-02-01 03:00:00  2004-03-01 03:00:00  2004-04-01 03:00:00
  2004-05-01 03:00:00  2004-06-01 03:00:00  2004-07-01 03:00:00  2004-08-01 03:00:00
  2004-09-01 03:00:00  2004-10-01 03:00:00  2004-11-01 03:00:00  2004-12-01 03:00:00
  2005-01-01 03:00:00  2005-02-01 03:00:00  2005-03-01 03:00:00  2005-04-01 03:00:00
  2005-05-01 03:00:00  2005-06-01 03:00:00  2005-07-01 03:00:00  2005-08-01 03:00:00
  2005-09-01 03:00:00  2005-10-01 03:00:00  2005-11-01 03:00:00  2005-12-01 03:00:00

Then, my problem is that I don not know how to type the target grid such this:

cdo remapbil,r180x360 input_file.nc output_file.nc

I will really appreciate your help.

来源:https://stackoverflow.com/questions/33268588/how-to-regrid-a-netcdf-using-bilinear-interpolation

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!