简体   繁体   English

无法获取python3 numpy来查看BLAS / LAPACK

[英]Can't get Python3 numpy to see BLAS/LAPACK

I'm running Linaro Debian Stretch on a Tinkerboard and I can't seem to be able to get numpy on Python3 to see any installed BLAS/LAPACK resources. 我在Tinkerboard上运行Linaro Debian Stretch ,但似乎无法在Python3上获取numpy的功能 ,以查看任何已安装的BLAS / LAPACK资源。

Running np.__config__.show() under python3 gives NOT AVAILABLE for every single entry. python3下运行np.__config__.show()会为每个条目提供NOT AVAILABLE

I've installed the BLAS/LAPACK via sudo apt-get install libblas-dev liblapack-dev , and python3-numpy and python3-scipy via apt-get as well. 我已经通过sudo apt-get install libblas-dev liblapack-devpython3-numpypython3-scipy通过apt-get安装了BLAS / LAPACK Numpy and scipy both run perfectly fine. Numpyscipy都运行得很好。 I've also installed ATLAS and OpenBLAS without luck, and have tried manual compilation of OpenBLAS and numpy too. 我还没有运气就安装了ATLASOpenBLAS ,也尝试过手动编译OpenBLASnumpy Nothing changes the output of np.__config__.show() . 什么也不会改变np.__config__.show()的输出。

Python2 , however, shows that these resources are installed. 但是, Python2显示已安装了这些资源。

How can I get Python3 to see these resources too? 我怎样才能让Python3也看到这些资源?

If anyone's interested in the answer, I managed to finally get OpenBLAS recognized in numpy, and received a decent speed boost. 如果有人对答案感兴趣,我最终以numpy获得了OpenBLAS的认可,并获得了不错的速度提升。

To do it you must first uninstall python3-numpy and any numpy installed via pip3. 为此,您必须首先卸载python3-numpy和通过pip3安装的所有numpy。 Then manually compile OpenBLAS and numpy as explained in Compiling numpy with OpenBLAS integration . 然后按照使用OpenBLAS集成编译numpy中所述手动编译OpenBLAS和numpy。

Installing the default packages via apt-get or pip apparently doesn't seem to link in any BLAS library by default, at least not on the TinkerBoard Linaro OS... 默认情况下,似乎似乎没有通过apt-get或pip安装默认软件包的任何BLAS库中都没有链接,至少在TinkerBoard Linaro OS上没有。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM