From 6422e30f1d4772b905900c00da127a74e84649d1 Mon Sep 17 00:00:00 2001 From: Florian Pinault Date: Wed, 20 Nov 2024 12:33:34 +0000 Subject: [PATCH] cutout must return ints for shape. not np.int64 --- src/anemoi/datasets/data/grids.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/anemoi/datasets/data/grids.py b/src/anemoi/datasets/data/grids.py index 15915f13..fd574136 100644 --- a/src/anemoi/datasets/data/grids.py +++ b/src/anemoi/datasets/data/grids.py @@ -324,7 +324,8 @@ def shape(self): """ shapes = [np.sum(mask) for mask in self.masks] global_shape = np.sum(self.global_mask) - return tuple(self.lams[0].shape[:-1] + (sum(shapes) + global_shape,)) + total_shape = sum(shapes) + global_shape + return tuple(self.lams[0].shape[:-1] + (int(total_shape),)) def check_same_resolution(self, d1, d2): # Turned off because we are combining different resolutions