From 49a37142eff5538ebdc843ef6975eca5850d6f29 Mon Sep 17 00:00:00 2001 From: James Krieger Date: Thu, 19 Sep 2024 13:00:58 +0200 Subject: [PATCH] replace eigvals --- prody/utilities/eigtools.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/prody/utilities/eigtools.py b/prody/utilities/eigtools.py index 875439ebb..543e71c01 100644 --- a/prody/utilities/eigtools.py +++ b/prody/utilities/eigtools.py @@ -42,11 +42,11 @@ def _eigh(M, eigvals=None, turbo=True): if not issparse(M): try: values, vectors = linalg.eigh(M, turbo=turbo, eigvals=eigvals) - except AttributeError: + except TypeError: if turbo: - values, vectors = linalg.eigh(M, driver='evd', eigvals=eigvals) + values, vectors = linalg.eigh(M, driver='evd', subset_by_index=eigvals) else: - values, vectors = linalg.eigh(M, eigvals=eigvals) + values, vectors = linalg.eigh(M, subset_by_index=eigvals) else: try: from scipy.sparse import linalg as scipy_sparse_la