[SciPy-User] scipy.linalg cannot find OpenBLAS

Alex Leach beamesleach@gmail....
Mon Nov 26 10:03:12 CST 2012


On Saturday 24 Nov 2012 10:36:57 Eric Hunsberger wrote:
 > I recently compiled my numpy/scipy to use OpenBLAS, and it seemed to be
> working fine (i.e., normal numpy functions seem to use it). However, when I
> try to import scipy.linalg, I get an error that libopenblas.so.0 cannot be
> found:
> 

<snip>

> 
> /usr/local/lib/python2.7/dist-packages/scipy/linalg/misc.py in <module>()
>       1 import numpy as np
>       2 from numpy.linalg import LinAlgError
> ----> 3 import fblas
>       4
>       5 __all__ = ['LinAlgError', 'norm']
> 
> ImportError: libopenblas.so.0: cannot open shared object file: No such file
> or directory

This error's coming from scipy/linalg/fblas.so, so looks like this module was 
linked incorrectly.
(I assume you're on Linux). Can you run:-

ldd /usr/local/lib/python2.7/dist-packages/scipy/linalg/fblas.so

On Mac OS X, it's:-

otool -L .../fblas.so


If there is a line saying 'not found', then you probably want to add 
/opt/OpenBLAS/lib to your LD_LIBRARY_PATH, (or to a file in /etc/ld.so.conf.d/ 
and run `sudo ldconfig`).

Cheers,
Alex
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/scipy-user/attachments/20121126/3f98f3b1/attachment.html 


More information about the SciPy-User mailing list