From aabac9d430486c3203b9f8a5b74102b808914b64 Mon Sep 17 00:00:00 2001 From: Fabian Joswig Date: Fri, 5 Nov 2021 12:19:23 +0000 Subject: [PATCH] correlate now also tests if idl for ensembles are identical --- pyerrors/pyerrors.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pyerrors/pyerrors.py b/pyerrors/pyerrors.py index e7ecfe8b..81ee81f9 100644 --- a/pyerrors/pyerrors.py +++ b/pyerrors/pyerrors.py @@ -1162,6 +1162,8 @@ def correlate(obs_a, obs_b): for name in obs_a.names: if obs_a.shape[name] != obs_b.shape[name]: raise Exception('Shapes of ensemble', name, 'do not fit') + if obs_a.idl[name] != obs_b.idl[name]: + raise Exception('idl of ensemble', name, 'do not fit') if obs_a.reweighted is True: warnings.warn("The first observable is already reweighted.", RuntimeWarning)