Python Forum

Full Version: ImportError:DLL Load Failed after importing scipy.sparse.linalg
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello,

I am attempting to create a build of python2.7 along side a build of python3.8 since I require both for a project that I need to complete. I have currently installed Python 2.7.11 and Python 3.8.5 and have them working well. However, I encountered many issues when trying to install NumPy and SciPy for Python 2.7. I was finally able to install NumPy 1.16.1 and SciPy 0.16.1; to make sure that they were functioning, I entered the Python 2 interpreter and imported each library. This seemed to work.

However, when I began using the library (OpenCavity) which required NumPy, SciPy, Python 2.7, I encountered the following when the library attempted to import scipy.sparse.linalg:
Traceback (most recent call last): File "<stdin>", line 1, in <module> File "C:\Python27\lib\site-packages\scipy\sparse\linalg\__init__.py", line 109, in <module> from .isolve import * File "C:\Python27\lib\site-packages\scipy\sparse\linalg\isolve\__init__.py", line 6, in <module> from .iterative import * File "C:\Python27\lib\site-packages\scipy\sparse\linalg\isolve\iterative.py", line 7, in <module> from . import _iterative ImportError: DLL load failed: The specified module could not be found.

I attempted to uninstall and reinstall SciPy but the error persisted. Is there a way to fix this error?

Thanks