无法为 python 安装 pandas
Unable to install pandas for python
我正在尝试为 python 安装 pandas,但我不断收到很长的错误消息。所以我尝试了以下方法:
- 卸载并重新安装 python 版本 3.10.0
- 通过导航到目录的命令提示符安装 pandas
C:\Users\username\AppData\Local\Programs\Python\Python310\Scripts
和 运行 pip 安装 pandas
- 我也试过使用 pip3 install pandas
- 我尝试安装以前版本的 pandas 但仍然出现相同的错误
这里是错误:
Microsoft Windows [Version 10.0.19042.1288]
(c) Microsoft Corporation. All rights reserved.
C:\Users\motaz>cd .C:\Users\motaz\AppData\Local\Programs\Python\Python310\Scripts
The filename, directory name, or volume label syntax is incorrect.
C:\Users\motaz>cd C:\Users\motaz\AppData\Local\Programs\Python\Python310\Scripts
C:\Users\motaz\AppData\Local\Programs\Python\Python310\Scripts>pip install pandas
Collecting pandas
Using cached pandas-1.3.3.tar.gz (4.7 MB)
Installing build dependencies ... error
ERROR: Command errored out with exit status 1:
command: 'C:\Users\motaz\AppData\Local\Programs\Python\Python310\python.exe' 'C:\Users\motaz\AppData\Local\Temp\pip-standalone-pip-_jyoyc51\__env_pip__.zip\pip' install --ignore-installed --no-user --prefix 'C:\Users\motaz\AppData\Local\Temp\pip-build-env-qf94j_f0\overlay' --no-warn-script-location --no-binary :none: --only-binary :none: -i https://pypi.org/simple -- 'setuptools>=51.0.0' wheel 'Cython>=0.29.21,<3' 'numpy==1.17.3; python_version=='"'"'3.7'"'"' and (platform_machine!='"'"'arm64'"'"' or platform_system!='"'"'Darwin'"'"') and platform_machine!='"'"'aarch64'"'"'' 'numpy==1.18.3; python_version=='"'"'3.8'"'"' and (platform_machine!='"'"'arm64'"'"' or platform_system!='"'"'Darwin'"'"') and platform_machine!='"'"'aarch64'"'"'' 'numpy==1.19.3; python_version>='"'"'3.9'"'"' and (platform_machine!='"'"'arm64'"'"' or platform_system!='"'"'Darwin'"'"') and platform_machine!='"'"'aarch64'"'"'' 'numpy==1.19.2; python_version=='"'"'3.7'"'"' and platform_machine=='"'"'aarch64'"'"'' 'numpy==1.19.2; python_version=='"'"'3.8'"'"' and platform_machine=='"'"'aarch64'"'"'' 'numpy>=1.20.0; python_version=='"'"'3.8'"'"' and platform_machine=='"'"'arm64'"'"' and platform_system=='"'"'Darwin'"'"'' 'numpy>=1.20.0; python_version=='"'"'3.9'"'"' and platform_machine=='"'"'arm64'"'"' and platform_system=='"'"'Darwin'"'"''
cwd: None
Complete output (234 lines):
实际上,Python 3.10 已为 pandas
a few days ago 启用。但是,最后一个版本 (1.3.3) 是在 9 月 12 日发布的。
您必须等待 Pandas 的新版本才能使用 Python 3.10 安装它。在此之前,您可以继续使用较低版本的 Python(就像某些用户建议的那样)。
我遇到了和你一样的问题,我安装了旧版本的 python(即 python 3.7.7)。问题已解决。据我所知,pandas 和 numpy 包还没有为 3.10 python“准备好”。
所以检查旧版本。
您必须下载 3.9.7 版本,然后安装 pandas。
我卸载了 3.10 版(我使用了程序 revo 卸载程序)
我必须 3.9.7
然后安装 pandas。
我必须卸载版本 3.10
(我使用程序 revo 卸载程序)才能执行此操作。
然后,在 15 天前 (13rd October 2021),他们为 Python 3.10 启用了 pandas 的安装。
现在您可以简单地从 cmd.exe
/prompt
.
安装它
我正在尝试为 python 安装 pandas,但我不断收到很长的错误消息。所以我尝试了以下方法:
- 卸载并重新安装 python 版本 3.10.0
- 通过导航到目录的命令提示符安装 pandas C:\Users\username\AppData\Local\Programs\Python\Python310\Scripts 和 运行 pip 安装 pandas
- 我也试过使用 pip3 install pandas
- 我尝试安装以前版本的 pandas 但仍然出现相同的错误
这里是错误:
Microsoft Windows [Version 10.0.19042.1288]
(c) Microsoft Corporation. All rights reserved.
C:\Users\motaz>cd .C:\Users\motaz\AppData\Local\Programs\Python\Python310\Scripts
The filename, directory name, or volume label syntax is incorrect.
C:\Users\motaz>cd C:\Users\motaz\AppData\Local\Programs\Python\Python310\Scripts
C:\Users\motaz\AppData\Local\Programs\Python\Python310\Scripts>pip install pandas
Collecting pandas
Using cached pandas-1.3.3.tar.gz (4.7 MB)
Installing build dependencies ... error
ERROR: Command errored out with exit status 1:
command: 'C:\Users\motaz\AppData\Local\Programs\Python\Python310\python.exe' 'C:\Users\motaz\AppData\Local\Temp\pip-standalone-pip-_jyoyc51\__env_pip__.zip\pip' install --ignore-installed --no-user --prefix 'C:\Users\motaz\AppData\Local\Temp\pip-build-env-qf94j_f0\overlay' --no-warn-script-location --no-binary :none: --only-binary :none: -i https://pypi.org/simple -- 'setuptools>=51.0.0' wheel 'Cython>=0.29.21,<3' 'numpy==1.17.3; python_version=='"'"'3.7'"'"' and (platform_machine!='"'"'arm64'"'"' or platform_system!='"'"'Darwin'"'"') and platform_machine!='"'"'aarch64'"'"'' 'numpy==1.18.3; python_version=='"'"'3.8'"'"' and (platform_machine!='"'"'arm64'"'"' or platform_system!='"'"'Darwin'"'"') and platform_machine!='"'"'aarch64'"'"'' 'numpy==1.19.3; python_version>='"'"'3.9'"'"' and (platform_machine!='"'"'arm64'"'"' or platform_system!='"'"'Darwin'"'"') and platform_machine!='"'"'aarch64'"'"'' 'numpy==1.19.2; python_version=='"'"'3.7'"'"' and platform_machine=='"'"'aarch64'"'"'' 'numpy==1.19.2; python_version=='"'"'3.8'"'"' and platform_machine=='"'"'aarch64'"'"'' 'numpy>=1.20.0; python_version=='"'"'3.8'"'"' and platform_machine=='"'"'arm64'"'"' and platform_system=='"'"'Darwin'"'"'' 'numpy>=1.20.0; python_version=='"'"'3.9'"'"' and platform_machine=='"'"'arm64'"'"' and platform_system=='"'"'Darwin'"'"''
cwd: None
Complete output (234 lines):
实际上,Python 3.10 已为 pandas
a few days ago 启用。但是,最后一个版本 (1.3.3) 是在 9 月 12 日发布的。
您必须等待 Pandas 的新版本才能使用 Python 3.10 安装它。在此之前,您可以继续使用较低版本的 Python(就像某些用户建议的那样)。
我遇到了和你一样的问题,我安装了旧版本的 python(即 python 3.7.7)。问题已解决。据我所知,pandas 和 numpy 包还没有为 3.10 python“准备好”。 所以检查旧版本。
您必须下载 3.9.7 版本,然后安装 pandas。 我卸载了 3.10 版(我使用了程序 revo 卸载程序)
我必须 3.9.7
然后安装 pandas。
我必须卸载版本 3.10
(我使用程序 revo 卸载程序)才能执行此操作。
然后,在 15 天前 (13rd October 2021),他们为 Python 3.10 启用了 pandas 的安装。
现在您可以简单地从 cmd.exe
/prompt
.