Tag: pip

无法在Python 3.4上升级pip

我看到已发布大量post; 但是,他们都没有完全相同的错误。 所以我想重新发布这个。 我正在运行以下命令: pip3 install –upgrade pip 我收到以下错误: Downloading/unpacking pip from https://pypi.python.org/packages/b6/ac/7015eb97dc749283ffdec1c3a88ddb8ae03b8fad0f0e611408f196358da3/pip-9.0.1-py2.py3-none-any.whl#md5=297dbd16ef53bcef0447d245815f5144 Downloading pip-9.0.1-py2.py3-none-any.whl (1.3MB): 1.3MB downloaded Installing collected packages: pip Found existing installation: pip 1.5.4 Not uninstalling pip at /usr/lib/python3/dist-packages, owned by OS Can’t roll back pip; was not uninstalled Cleaning up… Exception: Traceback (most recent call last): File “/usr/lib/python3/dist-packages/pip/basecommand.py”, line 122, in […]

ImportError:没有名为easydict的模块

我正在尝试基于这个GitHub页面运行py-faster-rcnn的演示。 我已经完成了之前的所有步骤。 但是当我尝试使用python ./tools/demo.py –gpu 0 –net vgg16运行演示时python ./tools/demo.py –gpu 0 –net vgg16我收到此错误: Traceback (most recent call last): File “./tools/demo.py”, line 17, in from fast_rcnn.config import cfg File “/home/hadi/Software/py-faster-rcnn/tools/../lib/fast_rcnn/config.py”, line 23, in from easydict import EasyDict as edict ImportError: No module named easydict 我用这两个命令安装了easydict: sudo pip install easydict pip install easydict 这与python路径有关吗? 我已经安装了python 2.7和3.5。 从那时起,我得到了所有这些与python相关的错误。 […]

在Ubuntu上打破Python3 pip3安装

我在我的Ubuntu16.04上成功安装了python3和pip3,但pip3安装已损坏。 我该如何解决这个问题? pip3 install的错误信息如下: # pip3 install xlwt Traceback (most recent call last): File “/usr/bin/pip3”, line 9, in from pip import main File “/usr/lib/python3/dist-packages/pip/__init__.py”, line 21, in from pip._vendor.requests.packages.urllib3.exceptions import DependencyWarning ModuleNotFoundError: No module named ‘pip._vendor.requests’ 输出sudo -H pip3 install –upgrade pip sudo -H pip3 install –upgrade pip Traceback (most recent call last): File “/usr/bin/pip3”, […]

无法让spyder使用python3(正确*)

我试图迁移到python3(参见从python2切换到python3 )继续; 试图用pip3安装spyder我到达了一个正常工作的工作区(虽然没有nautilus访问它,只能通过终端)。 更新系统然后重新启动它(由于某种未知原因)不再可访问; 在终端输入spyder会导致: Traceback (most recent call last): File “/usr/local/lib/python3.5/dist-packages/qtpy/__init__.py”, line 119, in from PySide import __version__ as PYSIDE_VERSION # analysis:ignore ImportError: No module named ‘PySide’ During handling of the above exception, another exception occurred: Traceback (most recent call last): File “/usr/local/bin/spyder”, line 11, in sys.exit(main()) File “/usr/local/lib/python3.5/dist-packages/spyder/app/start.py”, line 103, in main from […]

Ubuntu 16:pip install安装到python 3而不是2

我升级到Ubuntu 16.04。 我知道它只安装了python 3,但不知何故python 2进入那里(我猜作为依赖)。 那没关系,因为无论如何我都会添加它。 两个python版本都存在,可以看到: $ python –version Python 2.7.11+ $ python3 –version Python 3.5.1+ 我的问题是pip和pip3都默认为python3(并且也没有pip2)。 例如: $ sudo -H pip install numpy Requirement already satisfied (use –upgrade to upgrade): numpy in /usr/local/lib/python3.5/dist-packages $ sudo -H pip3 install numpy Requirement already satisfied (use –upgrade to upgrade): numpy in /usr/local/lib/python3.5/dist-packages 对于它的价值,他们指的是不同的fodler: $ which pip […]

在Snappy Ubuntu Core上安装pip的推荐方法是什么?

我想在Ansible上配置在Ubuntu Core上运行的Docker。 为此,我需要在机器上获得docker-py 。 Snappy已经安装了Python,但是没有提供pip 。 从https://bootstrap.pypa.io/get-pip.py运行通常的脚本会导致错误: OSError:[Errno 30]只读文件系统:’/ usr / local / lib / python2.7 / dad-packages / patch8.1.0.dist-info’ (考虑到操作系统的体系结构,这当然是有意义的) 是否有推荐的方法来在Snappy Ubuntu Core上安装pip / docker-py (或其他Python库)?

当apt-installed软件包存在时,使用pip3安装的python 3软件包?

我在/ usr / lib / python3 / dist-packages(通过apt)中安装了numpy 1.8.2,在/usr/local/lib/python3.4/dist-packages中安装了最新版本(1.9.2)(通过PIP)。 这两个路径都在sys.path中(按此顺序),但只有较旧的apt版本在python3中导入。 ➜ ~ sudo pip3 install –upgrade numpy [sudo] password for naught101: Real name of requirement numpy is numpy Requirement already up-to-date: numpy in /usr/local/lib/python3.4/dist-packages Cleaning up… ➜ ~ ipython3 Python 3.4.0 (default, Apr 11 2014, 13:05:11) Type “copyright”, “credits” or “license” for more information. IPython […]

sudo工作不正常

The directory ‘/home/user/.cache/pip/http’ or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo’s -H flag. The directory ‘/home/user/.cache/pip’ or its parent directory is not owned by the current user and […]

美丽的汤4不使用Python 3.4.0

我使用的是Ubuntu 14.04 64位操作系统。 我使用这个命令安装了Beautiful Soup 4 : sudo apt-get install python-bs4 使用Python 2.7.6 ,我可以bs4导入bs4模块。 但是当我使用Python 3.4.0时它向我展示了这个错误。 >>>import bs4 Traceback (most recent call last): File “”, line 1, in ImportError: No module named ‘bs4’ 我也尝试使用pip安装它。 sudo pip install beautifulsoup4 但是它再次与Python 3.4.0无关。 现在我已经卸载了pip并且还卸载了Beautiful Soup 4 sudo apt-get remove python-bs4 sudo apt-get remove python-pip 接下来我应该怎么做才能为Python 2.7.6和Python 3.4.0正确安装Beautiful Soup […]

pipinstall给出“命令”python setup.py egg_info“失败,错误代码为1”

我试图在Ubuntu 16.04上使用pip install安装python包rpy2 : pip install rpy2==2.2.7 但得到错误信息(见下面的完整输出): Command “python setup.py egg_info” failed with error code 1 in /tmp/pip-build-EuOI6K/unroll/ 其他软件包pip2发生同样的事情,例如pip install unroll或使用pip2 。 我认为这篇文章是同一个问题,但它通过使用sudo解决了。 解决了尝试 我在这篇文章中尝试过解决方案,例如: pip install –upgrade setuptools , (sudo) easy_install -U setuptools ,或sudo apt-get install python-setuptools ,但无济于事。 python / pip信息 有人建议我可能有一个奇怪的python / pip安装,这里有一些信息: sudo which python pip pip2 | xargs -rd ‘\n’ […]