Scipy: C Callback DLL failing to Load - python

I have been attempting to install scipy such that I can run it from IDLE. I have installed :
the proper numpy wheel via pip
the proper scipy wheel via pip
the visual C++ redistributable
I am using python 3.6.xx 32 bit and windows 10 pro. I have uninstalled and reinstalled everything multiple times. I am unsure how to move forward or where to look, it seems to me that the low level callable library has not installed properly given I am getting the error "Import Error: DLL load failed: the specified module could not be found"

Related

DLL Load Failed (Open cv2)

i tried many solutions for that error but didn't solved
ImportError: DLL load failed while importing cv2: The specified module could not be found.
Make sure you have installed right versions. Follow the below link for the compatible versions installed.
https://www.tensorflow.org/install/source_windows#gpu
https://www.drdataking.com/post/install-gpu-support-to-tensoflow-on-windows/
I was too getting similar issue:
DLL load failed while importing _multiarray_umath: The specified module could not be foundDLL load failed while importing _multiarray_umath: The specified module could not be found
Solution was the environment variable path was not set properly. Please find the image below:
Solution
in python 3.8 i fixed a similar error when compiling with cxfreeze cv2 dll load failed ,
the problem was that i had another version of python 3.6 installed and although environment variable path from python 3.8 was first, cxfreeze still loaded opencv from python 3.6 causing the error in the output file,
I fixed it by moving python 3.6 to another location so not get detected by cxfreeze, be careful with the environments variable path if you have other versions of python installed when compiling.
try miniconda with Python 3.6 is more stable ,
https://repo.continuum.io/miniconda/
Miniconda3-4.5.4 was the last Python 3.6 miniconda package.
Try to Install other versión of opencv
pip install opencv-contrib-python
Install Microsoft Visual C++ Redistributable for Visual Studio 2015, 2017 and 2019
https://support.microsoft.com/en-us/help/2977003/the-latest-supported-visual-c-downloads
Install media feature pack only if you use win10
https://www.microsoft.com/en-us/software-download/mediafeaturepack
this article may interest you
DLL load failed error when importing cv2

Installation of dtaidistance in python provides error

I am trying to install the module dtaidistance in Python to calculate the DTW distance matrix for a set of time series. But whenever I try to install the package using "pip install dtaidistance" a large error pops up and I don't know how to interpret it and what to do in order to make it function.
See the final few lines and the corresponding error message after running the install in the anaconda prompt in the screenshot below:
Error code screenshot:
The error says the cl.exe binary is not found. This probably means that you have not installed the Microsoft C compiler and linker (MSVC or Microsoft Visual Studio for Windows).
By the way, the current version of DTAIDistance should continue installing the Python implementation but the fast C-based versions will not be available.

Could not import cufflinks

Problem
I am trying to install both plotly and cufflinks. However I had a problem.
The installation of both plotly and cufflinks were successful. Although, I can't import cufflinks.
Below is a picture of the problem. It seems to be a dependency error:
I tried manually downloading and installing "talib" but I keep getting failures. (Shown below).
talib\common.c(240): fatal error C1083: Cannot open include file: 'ta_libc.h': No such file or directory
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\BIN\\x86_amd64\\cl.exe' failed with exit status 2
Any Ideas? I tried re-installing both modules and Anaconda. Nothing So far.
Other infos:
Cufflinks version: 0.11.0
Plotly version: 2.0.10
Anaconda version: 3-4.4.0 (But I don't think it have anything to do with it)
Python version: 3.6.1
try installing this version of cufflinks, it eliminated the error for me.
pip install cufflinks==0.8.2
From this link: github.com/mrjbq7/ta-lib#troubleshooting
Troubleshooting
Sometimes installation will produce build errors like this:
func.c:256:28: fatal error: ta-lib/ta_libc.h: No such file or directory
compilation terminated.
This typically means that it can't find the underlying TA-Lib library, a dependency which needs to be installed. On Windows, this could be caused by installing the 32-bit binary distribution of the underlying TA-Lib library, but trying to use it with 64-bit Python.
Windows
Download ta-lib-0.4.0-msvc.zip and unzip to C:\ta-lib
This is a 32-bit release. If you want to use 64-bit Python, you will need to build a 64-bit version of the library.
My Fix
So, for windows, we need a 64-bit version of the library? Luckly I found a lot of modules built for 32 and 64 bits python:
http://www.lfd.uci.edu/~gohlke/pythonlibs/
search for "ta-lib" and click on the module you need (In my case cp36 64 bits).
Then, open the command prompt.
Change to where you downloaded the file: cd path/to/file
Type: pip install NameOfFile (in my case pip install TA_Lib‑0.4.10‑cp36‑cp36m‑win_amd64.whl )
Now the 64-bits Ta-Lib module should be installed in your machine. I tested the previous line of codes and it worked!
Thanks for the help :)
I have now removed all dependencies on talib. All studies are pure python based now and you should not face any of this errors.

Python 3 installing javabridge, DLL load failed error

I want to use python-weka-wrapper3 for my project. To install it, first I should install javabridge. But when I try pip install javabridge-1.0.14-cp35-cp35m-win_amd64.whl I got javabridge-1.0.14-cp35-cp35m-win_amd64.whl is not a supported wheel on this platform. For this I've tried this solution and dowloaded 32 bit version of javabridge (Note: I'm using python 3.5.2). After running program, I got an error like ImportError: DLL load failed: %1 is not a valid Win32 application. and tried this solution. But it doesn't solve the problem.

scipy.linalg DLL load failed (Python 3.4, Windows 8.1) [duplicate]

I have been trying to install Scipy onto my Python 3.5 (32-bit) install on my Windows 7 machine using the pre-built binaries from:
http://www.lfd.uci.edu/~gohlke/pythonlibs
I have, in order, installed the following libraries
numpy‑1.10.1+mkl‑cp35‑none‑win32.whl
scipy‑0.16.1‑cp35‑none‑win32.whl
Then, when trying to use the installed packages I get the following erros
from scipy import sparse
< ... Complete error trace ommitted ... >
packages\scipy\sparse\csr.py", line 13, in <module>
from ._sparsetools import csr_tocsc, csr_tobsr, csr_count_blocks, \
ImportError: DLL load failed: The specified module could not be found.
However, if i follow the same process for Python 3.4 replacing the installers with:
numpy‑1.10.1+mkl‑cp35‑none‑win32.whl
scipy‑0.16.1‑cp35‑none‑win32.whl
Everything seems to work. Are there additional dependencies or install packages that I am missing for the Python 3.5 install?
Make sure you pay attention to this line from the link you provided:
Many binaries depend on NumPy-1.9+MKL and the Microsoft Visual C++
2008 (x64, x86, and SP1 for CPython 2.6 and 2.7), Visual C++ 2010
(x64, x86, for CPython 3.3 and 3.4), or the Visual C++ 2015 (x64 and
x86 for CPython 3.5) redistributable packages.
Download the corresponding Microsoft Visual C++ Redistributable Package which should be this one based on your description.
I had a similar problem, can't recall the exact issue, and I download the one for my system and it worked fine. Let me know otherwise.
Possibly helpful: trying to pip install scipy-0.18.0rc2-cp35-cp35m-win_amd64.whl (downloaded from http://www.lfd.uci.edu/~gohlke/pythonlibs/) on 64-bit windows 7 with Python 3.5 failed with a "file does not exist/not a valid wheel filename" error.
From various hints obtained from here and elsewhere I found that renaming the file to: scipy-0.16.1-cp35-none-win_amd64.whl allowed it to install.
Pull up the command window (search for it in the start button), then enter
pip install numpy
and
pip install scipy‑0.16.1‑cp35‑none‑win32.whl
then it should let you know in the command window if it was successfully downloaded, if you have python 3.5.
I had a question that turned out to be a duplicate of this one here:
ImportError: DLL load failed: when importing statsmodels
I actually solved this and other issues related to installing packages (such as statsmodels) by using Anaconda installer for Python 3.5.

Categories