8

我在为 matplotlib-venn 使用 easy_install 时遇到问题。我在使用 python2.7 的 Windows 计算机上。我怀疑路径不正确,但我不知道如何解决问题。有人可以帮我吗?我正在附加尝试在 CMD 提示器中运行 easy_install 命令的输出。

C:\Python27\Scripts>easy_install matplotlib-venn
Searching for matplotlib-venn
Reading https://pypi.python.org/simple/matplotlib-venn/
Download error on https://pypi.python.org/simple/matplotlib-venn/: [Errno 11004]
 getaddrinfo failed -- Some packages may not be found!
Couldn't find index page for 'matplotlib-venn' (maybe misspelled?)
Scanning index of all packages (this may take a while)
Reading https://pypi.python.org/simple/
Download error on https://pypi.python.org/simple/: [Errno 11004] getaddrinfo fai
led -- Some packages may not be found!
No local packages or download links found for matplotlib-venn
error: Could not find suitable distribution for Requirement.parse('matplotlib-ve
nn')
install for matplotlib-venn package

尝试 pip install 建议的输出:

C:\Python27\Scripts>easy_install pip
Searching for pip
Best match: pip 1.4.1
Adding pip 1.4.1 to easy-install.pth file
Installing pip-script.py script to C:\Python27\Scripts
Installing pip.exe script to C:\Python27\Scripts
Installing pip.exe.manifest script to C:\Python27\Scripts
Installing pip-2.7-script.py script to C:\Python27\Scripts
Installing pip-2.7.exe script to C:\Python27\Scripts
Installing pip-2.7.exe.manifest script to C:\Python27\Scripts
Using c:\python27\lib\site-packages
Processing dependencies for pip
Finished processing dependencies for pip
C:\Python27\Scripts>pip install matplotlib-venn
Downloading/unpacking matplotlib-venn
  Cannot fetch index base URL https://pypi.python.org/simple/
  Could not find any downloads that satisfy the requirement matplotlib-venn
Cleaning up...
No distributions at all found for matplotlib-venn
Storing complete log in C:\Users\jherman8\pip\pip.log
4

4 回答 4

18

基于

Download error on https://pypi.python.org/simple/matplotlib-venn/: [Errno 11004] getaddrinfo failed 

Cannot fetch index base URL https://pypi.python.org/simple/ 

看来你有网络问题。您是否在防火墙或代理后运行您的计算机?

为了easy_install在代理后面工作,您必须设置所需的环境,例如

set http_proxy="user:password@server:port"
set https_proxy="user:password@server:port"

对于 pip,您可以使用-proxy参数。有关代理后面的 pip 使用的更多详细信息,请参见此线程:如何在身份验证代理后面的 Windows 上使用 pip

于 2013-11-26T15:31:01.780 回答
2

我认为这是您的解决方案

easy_install pip
pip install matplotlib-venn

matplotlib-venneasy_install 中没有模块

并且对于将来,使用 pip 为 python 安装任何包。

于 2013-11-26T14:25:32.530 回答
0

如果您正在尝试使用 cloudera 框,那么这将在 bugzile 中实现。 https://bugzilla.redhat.com/show_bug.cgi?id=1510444 它适用于我的 cloudera 虚拟机,请按照说明操作,然后尝试通过 easy_install 安装。

# easy_install -i https://pypi.python.org/simple缝合 搜索缝合 阅读https://pypi.python.org/simple/stitches/最佳匹配:stitches 0.11 下载https://pypi.python.org/ packages/9d/73/681005f0f0fb9483f0d94547a35059c776144fc998780b9ef00167a50f3d/stitches-0.11.tar.gz#md5=0ac0b6e418767e6ec5cf684460d1972f Processing stitches-0.11.tar.gz Running stitches-0.11/setup.py -q bdist_egg --dist-dir /tmp/easy_install-ZMIU8w/针迹-0.11/egg-dist-tmp-82ctsZ zip_safe 标志未设置;分析存档内容...stitches.connection:模块引用文件将stitches 0.11添加到easy-install.pth文件

已安装 /usr/lib/python2.6/site-packages/stitches-0.11-py2.6.egg 处理缝合的依赖项...... 搜索 pynacl>=1.0.1 阅读https://pypi.python。 org/simple/pynacl/ Best match: PyNaCl 1.2.0 Downloading https://pypi.python.org/packages/fa/38/0f35ec4beb6562f1abfa07914db1cea978e93da409ba6293f810d9e677d6/PyNaCl-1.2.0.tar.gz#md5=7a31e95f5f457184b1660b71d6808b19 Processing PyNaCl-1.2. 0.tar.gz 运行 PyNaCl-1.2.0/setup.py -q bdist_egg --dist-dir /tmp/easy_install-a0vNJS/PyNaCl-1.2.0/egg-dist-tmp-QYvAk9 检查 .pth 文件支持。/usr/bin/python -E -c pass 搜索cffi>=1.4.1 阅读http://pypi.python.org/simple/cffi/找不到'cffi'的索引页面(可能拼写错误?)扫描所有包的索引(这可能需要一段时间)阅读http://pypi.python.org/simple/没有找到cffi的本地包或下载链接> =1.4.1 错误:找不到 Requirement.parse('cffi>=1.4.1') 的合适分布

所以唯一的解决方案是破解源代码:

sed -是,http://pypi.python.org,https: //pypi.python.org,/usr/lib/python2.6/site-packages/setuptools/command/easy_install.py

须藤

于 2018-12-16T04:26:18.470 回答
0
student@student-WIV68105-0080:~$ **sudo apt-cache search rtree**
libcneartree-dev - Library and headers for solving the Nearest Neighbor Problem
libcneartree5 - Library for solving the Nearest Neighbor Problem
student@student-WIV68105-0080:~$ **sudo apt-get install libcneartree-dev libcneartree5**
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following extra packages will be installed:
  libcvector2
The following NEW packages will be installed:
  libcneartree-dev libcneartree5 libcvector2

For me the same error occurred for rtree package and I did the cache search and installed the liraries

于 2016-02-01T06:20:41.390 回答