Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Python Intel MKL FATAL ERROR: Cannot load mkl_intel_thread.dll

Using Anaconda, Python has a problem whenever I import Pandas, Numpy, Matplotlib, etc.:

python.exe - Ordinal Not Found

The ordinal 242 could not be located in the dynamic link library

C:\Programs\Anaconda\pkgs\mkl-2019.1-144\Library\bin\mkl_intel_thread.dll.

This notification pops up in a dialog box. I also get the following error in the console itself:

Intel MKL FATAL ERROR: Cannot load mkl_intel_thread.dll.

The issue does not occur when importing modules from the standard library (e.g. re, datetime). It happens when I use any version of Python (e.g. iPython, Jupyter Notebook, python.exe).

The .dll itself is located in the place that it's looking, so I honestly have no idea what the issue is. I've tried uninstalling and reinstalling to no avail, and have scoured the Internet for assistance without finding any answers. Please help!

like image 761
bill Avatar asked Dec 08 '22 12:12

bill


2 Answers

pip uninstall numpy
pip install numpy

it's work for me,uninstall conda environment package "numpy" and reinstall latest edition.

like image 137
Jackwang Avatar answered Apr 02 '23 01:04

Jackwang


It's known DLL version conflict. There is workaround described in anaconda's docs: https://conda.io/projects/conda/en/latest/user-guide/troubleshooting.html#numpy-mkl-library-load-failed

On windows, just run set CONDA_DLL_SEARCH_MODIFICATION_ENABLE=1 in command prompt before using python.

like image 20
Ivan Sveshnikov Avatar answered Apr 02 '23 01:04

Ivan Sveshnikov