python – pip install hyperopt和hyperas失败
发布时间:2021-02-20 20:47:40 所属栏目:Python 来源:互联网
导读:我试图安装hyperopt,但是我收到以下错误: Collecting hyperoptUsing cached hyperopt-0.0.2.tar.gzComplete output from command python setup.py egg_info:DEBUG:root:distribute_setup.py not found, defaulting to system se
我试图安装hyperopt,但是我收到以下错误: Collecting hyperopt Using cached hyperopt-0.0.2.tar.gz Complete output from command python setup.py egg_info: DEBUG:root:distribute_setup.py not found,defaulting to system setuptools Traceback (most recent call last): File "<string>",line 1,in <module> File "/tmp/pip-build-gmhldfe7/hyperopt/setup.py",line 119,in <module> if package_data is None: package_data = find_package_data(packages) File "/tmp/pip-build-gmhldfe7/hyperopt/setup.py",line 102,in find_package_data for subdir in find_subdirectories(package): File "/tmp/pip-build-gmhldfe7/hyperopt/setup.py",line 73,in find_subdirectories subdirectories = os.walk(package_to_path(package)).next()[1] AttributeError: 'generator' object has no attribute 'next' ---------------------------------------- Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-gmhldfe7/hyperopt/ 并且在安装hyperas时我得到了同样的错误.但是我可以使用pip命令成功安装ggplot.我使用的是Ubuntu 14.04和Python 3.5. 谢谢. 解决方法这是hyperopt中的一个错误. generator.next被重命名为generator .__ next__,可以在Python3中使用next(生成器)调用.这是the PEP详细说明了这一变化. 看起来它是在master中修复但从未发布过.您可以通过执行以下操作从git(也就是github)安装: pip install git+https://github.com/hyperopt/hyperopt.git (编辑:甘南站长网) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
相关内容
- python – 没有模型的Django.contrib.flatpages
- Pythonic从包中导入模块的方法
- python – 使用lxml.html提取文本
- python – OS X UDP发送错误:55没有可用的缓冲区空间
- python – 为Django应用程序中的用户添加动作的日志条目
- python – ElementTree find()/ findall()找不到带命名空间
- 版本控制 – Mercurial日志界面
- python-2.7 – 如何在python中使用webdriver选择下拉列表值
- python – Pyro4:找不到名称服务器
- python – 如何在mac中安装setuptools