diff --git a/nlmod/dims/base.py b/nlmod/dims/base.py index a53fa7c4..6c980741 100644 --- a/nlmod/dims/base.py +++ b/nlmod/dims/base.py @@ -387,7 +387,7 @@ def _get_structured_grid_ds( ) if crs is not None: - ds.rio.set_crs(crs) + ds.rio.write_crs(crs, inplace=True) return ds @@ -513,7 +513,7 @@ def _get_vertex_grid_ds( ds["icvert"].attrs["nodata"] = nodata if crs is not None: - ds.rio.set_crs(crs) + ds.rio.write_crs(crs, inplace=True) return ds @@ -707,5 +707,5 @@ def check_variable(var, shape): transport=transport, **kwargs, ) - ds.rio.set_crs(crs) + ds.rio.write_crs(crs, inplace=True) return ds