Install Scipy with MKL through PIP

2019-02-11 16:44发布

I am using PIP to install Scipy with MKL to accelerate the performance. My OS is Ubuntu 64 bit. Using the solution from this question, I create a file .numpy-site.cfg

[mkl]
library_dirs=/opt/intel/composer_xe_2013_sp1/mkl/lib/intel64/
include_dirs=/opt/intel/mkl/include/
mkl_libs=mkl_intel_lp64,mkl_intel_thread,mkl_core,mkl_rt
lapack_libs=

This file helps me to install Numpy with MKL successfully. However, using the same above file, installing Scipy prompts the error

ImportError: libmkl_rt.so: cannot open shared object file: No such file or directory

I also use

export LD_LIBRARY_PATH=/opt/intel/composer_xe_2013_sp1/mkl/lib/intel64

but the problem is still the same.

Anyone know how to fix this problem? I don't want to install Scipy manually so anyone give me some hints to fix it.

7条回答
Melony?
2楼-- · 2019-02-11 17:12

For me, MKL came with Scipy library by conda install scipy

@rscohn2 solution gave me a hint for using packages.

For the reference, my environment is included Ubuntu, Anaconda, Python 3.6, Scipy 1.1 and MKL 2018.0.

查看更多
登录 后发表回答