Scipy安装需要BLAS

由于自己使用的是Ubuntu12.04,直接使用apt-get安装的scipy的版本比较底,所以采用了源码安装的方式安装scipy 0.13.2版本,但是安装时报错。错误如下:

numpy.distutils.system_info.BlasNotFoundError:
Blas(http://www.netlib.org/blas/) libraries not found.
Directories to search for the libraries can be specified in the numpy/distutils/site.cfg file (section [blas])or by setting the BLAS environment variable.
 

  发现安装需要BLAS,于是在StackOverflow上找到了对应的解决办法。

sudo apt-get install gfortran libopenblas-dev liblapack-dev

  先安装 gfortran linbipenblas-dev liblapack-dev,然后再安装需要的scipy

sudo python setup.py install

  就可以成功安装了。那么,这三个东西是什么呢?

gfortran的wiki

而BLAS就是一个基础的线性代数接口

LAPACK也是一个线性代数接口

其实这三个库,都是线性代数计算库,是scipy需要依赖的。

 

posted @ 2013-12-17 15:31  Dengchao  阅读(625)  评论(0)    收藏  举报