2014-07-17 45 views
1

计算点积我已经写在Theano下面简单的代码和我得到的错误,而编译函数f:错误而Theano

import theano.tensor as T 
x = T.dmatrix('x') 
w = T.dmatrix('w') 
y = T.dot(x,w) 

f = function([x,w],y) 

ImportError: ('The following error happened while compiling the node', Dot22(x, w), '\n', 'dlopen(../.theano/compiledir_Darwin-13.3.0-x86_64-i386-64bit-i386-2.7.8-64/tmpTqQ0iS/b6135ddd19d268ad3182850548638ec3.so, 2): Library not loaded: libmkl_intel_lp64.dylib\n Referenced from: ../.theano/compiledir_Darwin-13.3.0-x86_64-i386-64bit-i386-2.7.8-64/tmpTqQ0iS/b6135ddd19d268ad3182850548638ec3.so\n Reason: image not found', '[Dot22(x, w)]') 

什么是我身边的问题呢?

回答

3

从错误信息中可以看出,theano似乎找不到mkl库文件libmkl_intel_lp64.dylib。

你如何配置你的theano?特别是blas library

请检查安装手册的this section

+0

谢谢!如何检查Blas是否正确配置? – Lanc

+1

@Lanc阅读我链接到的安装手册。它在那里。 – Shai