2

I try to use Intel mkl from python. The only document I have found suggested the following:

from ctypes import *

# Load the share library
mkl = cdll.LoadLibrary("./libmkl_rt.so")
# For Intel MKL prior to version 10.3 us the created .so as below
# mkl = dll.LoadLibrary("./libmkl4py.so")
cblas_dgemm = mkl.cblas_dgemm

I am on anaconda3. The code above does not work on anaconda3,

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

but I can use

import mkl 

directly. Yet I do not find any documents on what to do next after import mkl. For example, how can I get the cblas_dgemm function as in the example above. Calling mkl.cblas_dgemm directly does not work on my anaconda (after import mkl). Any idea? In the end, I hope to invoke Intel MKL's pardiso solver but really have no idea although import mkl works on my anaconda.

zell
  • 9,830
  • 10
  • 62
  • 115

0 Answers0