简体   繁体   English

setup.py egg_info错误代码3221225477

[英]setup.py egg_info error code 3221225477

I've been trying to install IMGAUG package for an ML project. 我一直在尝试为ML项目安装IMGAUG软件包。 But the installation gets stuck when it tries to install scikit-image 但是在尝试安装scikit-image时安装被卡住了

My input: pip install scikit-image 我的输入: pip install scikit-image

output: 输出:

Collecting imgaug
Using cached 
https://files.pythonhosted.org/...
Requirement already satisfied: scipy in 
c:\users\*<username>*\appdata\local\programs\python\python37\lib\site- 
packages (from imgaug) (1.1.0)
Collecting scikit-image>=0.11.0 (from imgaug)
Using cached https://files.pythonhosted.org/packages/...
Complete output from command python setup.py egg_info:
----------------------------------------
Command "python setup.py egg_info" failed with error code 3221225477 in 
C:\Users\<name>~1.<name2>\AppData\Local\Temp\pip-install-qmdp6ysz\scikit-image\

Note: I've already tried installing other versions of it, upgrading setuptools and pip. 注意:我已经尝试安装它的其他版本,升级setuptools和pip。 Error persists. 错误仍然存​​在。

PS: Now it's showing up on everything I try to install. PS:现在它显示在我尝试安装的所有内容上。

(Scroll down to a horizontal line to skip explanation and go straight to the suggested solution if you wish) (向下滚动至水平线可跳过说明,并根据需要直接转到建议的解决方案)

3221225477 is 0xC0000005 which is NTSTATUS STATUS_ACCESS_VIOLATION ; 32212254770xC0000005 ,它是NTSTATUS STATUS_ACCESS_VIOLATION ; the corresponsing error message is The instruction at 0x%08lx referenced memory at 0x%08lx. The memory could not be %s. 相应的错误消息是The instruction at 0x%08lx referenced memory at 0x%08lx. The memory could not be %s. The instruction at 0x%08lx referenced memory at 0x%08lx. The memory could not be %s. .

In Windows, a process usually quits with this exit code if it tries to access an invalid memory address and Windows terminates it as a result . 在Windows中,如果进程尝试访问无效的内存地址,则该进程通常会使用此退出代码退出,并且Windows最终将其终止 If you install Visual Studio, you'll be able to pinpoint the exact module at fault as shown on the link. 如果安装了Visual Studio,则可以按链接上的说明查明发生故障的确切模块。

Now, this error means a bug in or an incompatibility between some of your installed extension modules (or in Python engine itself, but this is very unlikely in comparison). 现在,此错误意味着某些已安装的扩展模块存在错误或彼此之间不兼容(或Python引擎本身,但是相比之下,这种可能性很小)。

The easiest way to fix is to clean up any problems with the involved modules' installation and (if that isn't enough) update them to the latest versions, hoping that whatever is causing that is fixed in them. 修复最简单的方法是清除所涉及模块的安装问题,并(如果还不够的话)将其更新为最新版本,希望能解决导致此问题的任何原因。

  • In particular, scipy in c:\\users\\*<username>*\\appdata\\local\\programs\\python\\python37\\lib\\site-packages looks suspicious: you aren't using --user in your pip command 特别是scipy in c:\\users\\*<username>*\\appdata\\local\\programs\\python\\python37\\lib\\site-packages看起来很可疑:您在pip命令中没有使用--user

    • which suggests that your didn't pay attention to this flag when using pip before ( it's official that it CAN lead to version conflicts ), and some of your installed packages are installed both into %ProgramFiles%\\Python37\\Lib\\site-packages and %APPDATA%\\Python\\Python37\\ib\\site-packages , with different versions in these two locations. 这表明您以前使用pip时没有注意此标志( 官方可能会导致版本冲突 ),并且您已安装的某些软件包已安装到%ProgramFiles%\\Python37\\Lib\\site-packages%APPDATA%\\Python\\Python37\\ib\\site-packages ,在这两个位置具有不同的版本。

I hereby suggest you to: 我在此建议您:

  • decide where you want your 3rd-party modules to be 决定您希望第三方模块在哪里
    • %ProgramFiles% is system-wide and requires elevation to manage, %APPDATA% is per-user and doesn't require elevation %ProgramFiles%是系统范围的,需要提升权限来管理, %APPDATA%是每位用户且不需要提升权限
    • Unless you don't have administrative rights at your machine (you do, judging by the command you gave) or have special needs, keep everything in the system-wide location for simplicity 除非您没有对计算机的管理权限(通过给定的命令来判断是否具有管理权限)或有特殊需求,否则为了简化起见,请将所有内容都保留在系统范围内
  • uninstall all the modules in the other location ( pip uninstall <name(s)> with or without --user ) 卸载其他位置的所有模块( pip uninstall <name(s)>带有或不带有--user
  • reinstall them to the desired location, updating existing versions ( -U pip flag) 将它们重新安装到所需位置,更新现有版本( -U pip标志)
  • if that wasn't enough to solve the problem (very unlikely), update all packages to the latest versions 如果那还不足以解决问题(极不可能), 请将所有软件包更新为最新版本

This happened to me also. 这也发生在我身上。 However I resolved it by uninstalling the package (pip uninstall ), then installing it using conda rather than pip (conda install ). 但是我通过卸载软件包(pip uninstall),然后使用conda而不是pip来安装它(conda install)来解决。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM