python - 使用 pip 安装 SciPy 和 NumPy

我正在尝试在我分发的包中创建所需的库。它需要 SciPy和 NumPy图书馆。 在开发过程中,我都安装了使用

apt-get install scipy

它安装了 SciPy 0.9.0 和 NumPy 1.5.1,并且运行良好。

我想使用 pip install 做同样的事情 - 为了能够在我自己的包的 setup.py 中指定依赖项。

问题是,当我尝试时:

pip install 'numpy==1.5.1'

效果很好。

然后

pip install 'scipy==0.9.0'

惨遭失败,

raise self.notfounderror(self.notfounderror.__doc__)

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.

如何让它工作?

最佳答案

这在 Ubuntu 14.04 上对我有用:

sudo apt-get install libblas-dev liblapack-dev libatlas-base-dev gfortran
pip install scipy

https://stackoverflow.com/questions/11114225/

相关文章:

python - Python Web 框架、WSGI 和 CGI​​ 如何组合在一起

c - 如何从Linux中的C获取当前时间(以毫秒为单位)?

linux - 尝试在 Windows 上使用 bash 并没有收到已安装的发行版消息

python - django MultiValueDictKeyError 错误,我该如何处理

linux - 无法通过 HTTPS 在 Linux 上克隆 github 存储库

python - 如何使 python 命令行程序自动完成任意事物而不是解释器

bash - 在 bash 脚本中模拟 ENTER 按键

python - 如何单步调试 Python 代码以帮助调试问题?

python - 检查字符串是否包含数字

python - 如何检索 Pandas 数据框中的列数?