From e557c9b54d3eb1bd522ea440b7f56fab05c071c2 Mon Sep 17 00:00:00 2001 From: Fabian Joswig Date: Mon, 9 May 2022 14:14:26 +0100 Subject: [PATCH] feat: runtime warning added when ts is used in combination with sorted_list="Eigenvalue" in Corr.GEVP --- pyerrors/correlators.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pyerrors/correlators.py b/pyerrors/correlators.py index 3ca4ee58..3c1b8a75 100644 --- a/pyerrors/correlators.py +++ b/pyerrors/correlators.py @@ -279,6 +279,8 @@ class Corr: sp_vec = sp_vecs[state] return sp_vec elif sorted_list in ["Eigenvalue", "Eigenvector"]: + if sorted_list == "Eigenvalue" and ts is not None: + warnings.warn("ts has no effect when sorting by eigenvalue is chosen.", RuntimeWarning) all_vecs = [] for t in range(self.T): try: