Python 3.x Scipy不使用python 3,但使用2.6(默认)
我已经安装了Scipy,通过终端构建和安装。但当我尝试执行以下简单代码时,会出现以下错误:Python 3.x Scipy不使用python 3,但使用2.6(默认),python-3.x,scipy,Python 3.x,Scipy,我已经安装了Scipy,通过终端构建和安装。但当我尝试执行以下简单代码时,会出现以下错误: from scipy.stats.mstats_basic import gmean ab=[1,2,3,4,5,6] print(gmean(ab)) 这就是我得到的错误: Traceback (most recent call last): File "/home/prashanthb/workspace/rankalgo/rough1.py", line 2, in <module
from scipy.stats.mstats_basic import gmean
ab=[1,2,3,4,5,6]
print(gmean(ab))
这就是我得到的错误:
Traceback (most recent call last):
File "/home/prashanthb/workspace/rankalgo/rough1.py", line 2, in <module>
from scipy.stats.mstats_basic import gmean
File "/usr/local/lib/python3.1/dist-packages/scipy/stats/__init__.py", line 321, in <module>
File "/usr/local/lib/python3.1/dist-packages/scipy/stats/stats.py", line 194, in <module>
File "/usr/local/lib/python3.1/dist-packages/scipy/special/__init__.py", line 525, in <module>
ImportError: No module named _cephes
test()表明nose>=0.10.0是必需的。因为scipy有很多依赖项,所以可能需要为您的发行版安装一个打包的解决方案。您使用的是哪个发行版?你没有这个选择吗?Ubuntu 10.10。我检查了一下,没有发现任何scipy/numpy包。你说得对。Ubuntu 10.10上没有
python3scipy
软件包。如果你有这个选择,我建议将Ubuntu升级到12.04。这一款已经打包了python3scipy
,它将使您的生活更加轻松(Ubuntu 10.10目前不再受支持)。
DeprecationWarning)
customize GnuFCompiler
Could not locate executable g77
Could not locate executable f77
customize IntelFCompiler
Could not locate executable ifort
Could not locate executable ifc
customize LaheyFCompiler
Could not locate executable lf95
customize PGroupFCompiler
Could not locate executable pgfortran
customize AbsoftFCompiler
Could not locate executable f90
customize NAGFCompiler
Found executable /usr/bin/f95
customize VastFCompiler
customize CompaqFCompiler
Could not locate executable fort
customize IntelItaniumFCompiler
Could not locate executable efort
Could not locate executable efc
customize IntelEM64TFCompiler
customize Gnu95FCompiler
Found executable /usr/bin/gfortran
customize Gnu95FCompiler
customize Gnu95FCompiler using config
compiling '_configtest.c':