首页 > 其他 > 详细

scipy.optimize ImportError: cannot import name '_zeta'

时间:2017-01-19 13:05:05      阅读:740      评论:0      收藏:0      [点我收藏+]

最近开发同事让我装几个包,scipy、gensim、theano、sklearn.....几个包装完后,发现导入报错,具体如下:

from ._ufuncs import (ellipkm1, mathieu_a, mathieu_b, iv, jv, gamma,
ImportError: cannot import name ‘_zeta‘

通过某度搜了好久愣是没发现解决办法,后来直接出去,用Google搜索,直接提示scipy版本问题,更新即可,

Sounds like you have an old version of special._ufuncs--the function zeta in there was renamed to_zeta somewhat recently. What happens if you completely uninstall SciPy and then reinstall a fresh version? (Also, what version of SciPy are you using?)

这里真的不得不吐槽一把....

[root@localhost~]# pip uninstall scipy

[root@localhost~]# pip install -U scipy

后面的安装过程大概需要10分钟左右,最终结果为:

  Could not find .egg-info directory in install record for scipy from https://pypi.python.org/packages/22/41/b1538a75309ae4913cdbbdc8d1cc54cae6d37981d2759532c1aa37a41121/scipy-0.18.1.tar.gz#md5=5fb5fb7ccb113ab3a039702b6c2f3327 in /usr/local/lib/python2.7/site-packages

Successfully installed scipy

Cleaning up...

[root@localhost~]# python

Python 2.7.10 (default, Dec 22 2016, 14:45:25) 

[GCC 4.8.2] on linux2

Type "help", "copyright", "credits" or "license" for more information.

>>> import scipy

>>> import gensim

>>> import theano

>>> import sklearn

>>> exit

Use exit() or Ctrl-D (i.e. EOF) to exit

>>> exit()

[root@localhost ~]#


本文出自 “平平淡淡才是真” 博客,请务必保留此出处http://ucode.blog.51cto.com/10837891/1893119

scipy.optimize ImportError: cannot import name '_zeta'

原文:http://ucode.blog.51cto.com/10837891/1893119

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!