Project

General

Profile

Using CDO to regrid from a high-resolution grid to a low resolution grid

Added by Friedrich Burger 3 months ago

Hi all,
is there a good way to use CDO for regridding from a high-resolution grid to a low resolution grid? I often use remapbil. However, as far as I can see, bilinear remapping will only take into account the four closest grid cells to the center of a grid cell on the new grid - which will result in a lot of data unused when the difference in grid resolution is large. For example, when regridding a field on a 1/20° x 1/20° grid to 1° x 1° resolution, this will result in 396 of 400 cells of the high-resolution grid not being used for regridding. Is there a good solution in CDO to circumvent this problem, for example by using another regridding method or by first binning the high resolution grid to a resolution similar to that of the low resolution grid? I hope this topic has not been discussed elsewhere in the forum.

Looking forward to your thoughts.

Best,
Friedrich


Replies (4)

RE: Using CDO to regrid from a high-resolution grid to a low resolution grid - Added by Estanislao Gavilan 3 months ago

Hi Friedrich,

If you could smooth the field with the command "smooth" (see Documentation 2.15.5 Smooth) and then apply bilinear remapping.

Kind regards,

Estanislao

RE: Using CDO to regrid from a high-resolution grid to a low resolution grid - Added by Friedrich Burger 2 months ago

Dear Estanislao,
thanks for your thoughts. I haven't been aware of cdo smooth yet, thanks for pointing me to it. I am not sure whether using smooth and then some remapping is optimal though - rather thinking that a simple binning to a lower grid resolution prior to remapping would be preferable, such as for example implemented in xarrays coarsen method (https://docs.xarray.dev/en/stable/generated/xarray.DataArray.coarsen.html).

Best regards,
Friedrich

RE: Using CDO to regrid from a high-resolution grid to a low resolution grid - Added by Elio Campitelli about 1 month ago

Does remapavg do what you want? From the docs:

This module maps source points to target cells by calculating a statistical value from the source points. Each target cell contains the statistical value from all source points within that target cell. If there are no source points within a target cell, it gets a missing value. The target grid must be regular lon/lat or Gaussian. Depending on the chosen operator the minimum, maximum, range, sum, average, variance, standard deviation, skewness, kurtosis or median of source points is computed

RE: Using CDO to regrid from a high-resolution grid to a low resolution grid - Added by Friedrich Burger about 1 month ago

Hi Elio,
thanks! exactly what I have been looking for. Haven't been aware of remapavg or remapmean yet. These (differing in the treatment of NaNs in the source points) also lead to very similar results to the xarray method coarsen mentioned above.

Given that regridding from some finer-resolved grid to a more standard coarse grid is something quite common, it should be remembered that such an operation may be necessary to avoid a loss of information, which occurs under bilinear interpolation.

    (1-4/4)