From 7398300520f1859ba95da56db399358be2a300d9 Mon Sep 17 00:00:00 2001 From: Carsten Ehbrecht Date: Mon, 6 Nov 2023 17:43:13 +0100 Subject: [PATCH] updated concat to use realization variable --- rook/utils/concat_utils.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/rook/utils/concat_utils.py b/rook/utils/concat_utils.py index 848510a..cd07233 100644 --- a/rook/utils/concat_utils.py +++ b/rook/utils/concat_utils.py @@ -80,8 +80,9 @@ def _calculate(self): dims = dimension_parameter.DimensionParameter( self.params.get("dims", None) ).value - standard_name = dims[0] - dim = coord_by_standard_name.get(standard_name, None) + # standard_name = dims[0] + # dim = coord_by_standard_name.get(standard_name, None) + dim = dims[0] processed_ds = xr.concat( datasets, @@ -90,7 +91,7 @@ def _calculate(self): processed_ds = processed_ds.assign_coords( {dim: (dim, np.array(processed_ds[dim].values, dtype="int32"))} ) - processed_ds.coords[dim].attrs = {"standard_name": standard_name} + # processed_ds.coords[dim].attrs = {"standard_name": standard_name} # optional: average if self.params.get("apply_average", False): processed_ds = average(processed_ds, dims=["realization"])