From aefa03bb235a8377e8561edafc0756e69c46d470 Mon Sep 17 00:00:00 2001 From: Yang Date: Wed, 15 Nov 2023 12:30:58 +0100 Subject: [PATCH] address review comments --- src/zampy/datasets/land_cover.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/zampy/datasets/land_cover.py b/src/zampy/datasets/land_cover.py index c399d82..66e8f13 100644 --- a/src/zampy/datasets/land_cover.py +++ b/src/zampy/datasets/land_cover.py @@ -195,10 +195,9 @@ def unzip_raw_to_netcdf( def extract_netcdf_to_zampy(file: Path) -> xr.Dataset: """Extract zipped data and convert to zampy format. - Since the original land cover field is too large to fit into - the memory in general, in this function the loaded land cover - data are regridded. They are regrid to a resoltuion of 0.25 - degree, same as the native resolution of ERA5 data. + Since the native resolution of land cover field is too high + in general, in this function the loaded land cover data + are regridded. They are regrid to a resoltuion of 0.05 degree. Args: file: Path to the land cover .zip archive. @@ -219,7 +218,6 @@ def extract_netcdf_to_zampy(file: Path) -> xr.Dataset: var_list.remove(raw_variable) ds = ds.drop_vars(var_list) # noqa: PLW2901 - # coarsen to fit into memory ds = ds.sortby(["lat", "lon"]) # noqa: PLW2901 ds = ds.rename({"lat": "latitude", "lon": "longitude"}) # noqa: PLW2901 new_grid = xarray_regrid.Grid(