Skip to content

Commit

Permalink
cordex GERICS REMO2015 lon differences above 10e-4 (#2334)
Browse files Browse the repository at this point in the history
Co-authored-by: Valeriu Predoi <[email protected]>
  • Loading branch information
mwjury and valeriupredoi authored Feb 19, 2024
1 parent 4d705ab commit da20e0b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions esmvalcore/cmor/_fixes/cordex/cordex_fixes.py
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,10 @@ def _fix_geographical_coords(self, cube, domain):
units=Unit(domain[aux_coord].units),
bounds=bounds,
)
if aux_coord == 'lon' and new_coord.points.min() < 0.:
lon_inds = (new_coord.points < 0.) & (old_coord.points > 0.)
old_coord.points[lon_inds] = old_coord.points[lon_inds] - 360.

self._check_grid_differences(old_coord, new_coord)
aux_coord_dims = (cube.coord(var_name='rlat').cube_dims(cube) +
cube.coord(var_name='rlon').cube_dims(cube))
Expand Down

0 comments on commit da20e0b

Please sign in to comment.