diff --git a/prody/utilities/eigtools.py b/prody/utilities/eigtools.py index ef8b141af..543e71c01 100644 --- a/prody/utilities/eigtools.py +++ b/prody/utilities/eigtools.py @@ -40,7 +40,13 @@ def _eigh(M, eigvals=None, turbo=True): if eigvals: turbo = False if not issparse(M): - values, vectors = linalg.eigh(M, turbo=turbo, eigvals=eigvals) + try: + values, vectors = linalg.eigh(M, turbo=turbo, eigvals=eigvals) + except TypeError: + if turbo: + values, vectors = linalg.eigh(M, driver='evd', subset_by_index=eigvals) + else: + values, vectors = linalg.eigh(M, subset_by_index=eigvals) else: try: from scipy.sparse import linalg as scipy_sparse_la diff --git a/pyproject.toml b/pyproject.toml index 6301b1948..3c81264ad 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,2 +1,2 @@ [build-system] -requires = ["setuptools", "wheel", "numpy>=1.10,<2", "pyparsing<=3.1.1", "scipy<=1.13.1"] +requires = ["setuptools", "wheel", "numpy>=1.10,<2", "pyparsing<=3.1.1", "scipy"] diff --git a/setup.py b/setup.py index 9f2075f19..784677874 100644 --- a/setup.py +++ b/setup.py @@ -16,7 +16,7 @@ if sys.version_info[:2] == (2, 7) or sys.version_info[:2] <= (3, 5): INSTALL_REQUIRES=['numpy>=1.10', 'biopython<=1.76', 'pyparsing', 'scipy'] else: - INSTALL_REQUIRES=['numpy>=1.10,<2', 'biopython', 'pyparsing<=3.1.1', 'scipy<=1.13.1', 'setuptools'] + INSTALL_REQUIRES=['numpy>=1.10,<2', 'biopython', 'pyparsing<=3.1.1', 'scipy', 'setuptools'] if sys.version_info[0] == 3 and sys.version_info[1] < 6: sys.stderr.write('Python 3.5 and older is not supported\n')