提问人:Aayush Mishra 提问时间:4/19/2023 更新时间:4/19/2023 访问量:94
在 Windows 上安装“recordlinkage”模块
Install "recordlinkage" module on Windows
问:
我正在尝试用于安装记录链接库。到目前为止,此命令适用于我下载的所有其他模块,例如 pandas、arrow 等。pip install recordlinkage
但是,自从我运行以来,我开始出现一系列错误。我正在使用 Python 3.11.1pip install recordlinkage
最初,我收到错误 -
PS C:\Users\x_AMishra\Documents\VA Scripts> pip install recordlinkage
Collecting recordlinkage
Using cached recordlinkage-0.15-py3-none-any.whl (926 kB)
Collecting jellyfish>=0.8.0 (from recordlinkage)
Using cached jellyfish-0.11.2-cp311-none-win32.whl (205 kB)
Requirement already satisfied: numpy>=1.13.0 in c:\users\x_amishra\lib\site-packages (from recordlinkage) (1.24.2)
Collecting pandas<2,>=1 (from recordlinkage)
Using cached pandas-1.5.3.tar.gz (5.2 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... done
Collecting scipy>=1 (from recordlinkage)
Using cached scipy-1.10.1.tar.gz (42.4 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Installing backend dependencies ... done
Preparing metadata (pyproject.toml) ... error
error: subprocess-exited-with-error
× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [37 lines of output]
+ meson setup --prefix=C:\Users\x_AMishra C:\Users\x_AMishra\AppData\Local\Temp\pip-install-g2nk2241\scipy_cf7f5cd1633b4b07aaf120b334d5ff77 C:\Users\x_AMishra\AppData\Local\Temp\pip-install-g2nk2241\scipy_cf7f5cd1633b4b07aaf120b334d5ff77\.mesonpy-jp4kzikw\build --native-file=C:\Users\x_AMishra\AppData\Local\Temp\pip-install-g2nk2241\scipy_cf7f5cd1633b4b07aaf120b334d5ff77\.mesonpy-native-file.ini -Ddebug=false -Doptimization=2
The Meson build system
Version: 1.1.0
Source dir: C:\Users\x_AMishra\AppData\Local\Temp\pip-install-g2nk2241\scipy_cf7f5cd1633b4b07aaf120b334d5ff77
Build dir: C:\Users\x_AMishra\AppData\Local\Temp\pip-install-g2nk2241\scipy_cf7f5cd1633b4b07aaf120b334d5ff77\.mesonpy-jp4kzikw\build
Build type: native build
Project name: SciPy
Project version: 1.10.1
Activating VS 17.4.2
C compiler for the host machine: cl (msvc 19.34.31935 "Microsoft (R) C/C++ Optimizing Compiler Version 19.34.31935 for x64")
C linker for the host machine: link link 14.34.31935.0
C++ compiler for the host machine: cl (msvc 19.34.31935 "Microsoft (R) C/C++ Optimizing Compiler Version 19.34.31935 for x64")
C++ linker for the host machine: link link 14.34.31935.0
Cython compiler for the host machine: cython (cython 0.29.34)
Host machine cpu family: x86_64
Host machine cpu: x86_64
Compiler for C supports arguments -Wno-unused-but-set-variable: NO
Compiler for C supports arguments -Wno-unused-function: NO
Compiler for C supports arguments -Wno-conversion: NO
Compiler for C supports arguments -Wno-misleading-indentation: NO
Compiler for C supports arguments -Wno-incompatible-pointer-types: NO
Library m found: NO
..\..\meson.build:63:0: ERROR: Unknown compiler(s): [['ifort'], ['gfortran'], ['flang'], ['pgfortran'], ['g95']]
The following exception(s) were encountered:
Running `ifort --version` gave "[WinError 2] The system cannot find the file specified"
Running `ifort -V` gave "[WinError 2] The system cannot find the file specified"
Running `gfortran --version` gave "[WinError 2] The system cannot find the file specified"
Running `gfortran -V` gave "[WinError 2] The system cannot find the file specified"
Running `flang --version` gave "[WinError 2] The system cannot find the file specified"
Running `flang -V` gave "[WinError 2] The system cannot find the file specified"
Running `pgfortran --version` gave "[WinError 2] The system cannot find the file specified"
Running `pgfortran -V` gave "[WinError 2] The system cannot find the file specified"
Running `g95 --version` gave "[WinError 2] The system cannot find the file specified"
Running `g95 -V` gave "[WinError 2] The system cannot find the file specified"
A full log can be found at C:\Users\x_AMishra\AppData\Local\Temp\pip-install-g2nk2241\scipy_cf7f5cd1633b4b07aaf120b334d5ff77\.mesonpy-jp4kzikw\build\meson-logs\meson-log.txt
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
据我所知,在安装依赖于 recordlinkage 的“scipy”时,我似乎遇到了错误。由此,我认为需要安装一个 gcc 编译器。我这样做了,我得到的新错误是这样的 -ERROR: Unknown compiler(s): [['ifort'], ['gfortran'], ['flang'], ['pgfortran'], ['g95']]
PS C:\Users\x_AMishra\Documents\VA Scripts> pip install recordlinkage
Collecting recordlinkage
Using cached recordlinkage-0.15-py3-none-any.whl (926 kB)
Collecting jellyfish>=0.8.0 (from recordlinkage)
Using cached jellyfish-0.11.2-cp311-none-win32.whl (205 kB)
Requirement already satisfied: numpy>=1.13.0 in c:\users\x_amishra\lib\site-packages (from recordlinkage) (1.24.2)
Collecting pandas<2,>=1 (from recordlinkage)
Using cached pandas-1.5.3.tar.gz (5.2 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... done
Collecting scipy>=1 (from recordlinkage)
Using cached scipy-1.10.1.tar.gz (42.4 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Installing backend dependencies ... done
Preparing metadata (pyproject.toml) ... error
error: subprocess-exited-with-error
× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [12 lines of output]
+ meson setup --prefix=C:\Users\x_AMishra C:\Users\x_AMishra\AppData\Local\Temp\pip-install-i4ll3fah\scipy_50446030ddc0489785aefbfe1a690e40 C:\Users\x_AMishra\AppData\Local\Temp\pip-install-i4ll3fah\scipy_50446030ddc0489785aefbfe1a690e40\.mesonpy-m4vblvlb\build --native-file=C:\Users\x_AMishra\AppData\Local\Temp\pip-install-i4ll3fah\scipy_50446030ddc0489785aefbfe1a690e40\.mesonpy-native-file.ini -Ddebug=false -Doptimization=2
The Meson build system
Version: 1.1.0
Source dir: C:\Users\x_AMishra\AppData\Local\Temp\pip-install-i4ll3fah\scipy_50446030ddc0489785aefbfe1a690e40
Build dir: C:\Users\x_AMishra\AppData\Local\Temp\pip-install-i4ll3fah\scipy_50446030ddc0489785aefbfe1a690e40\.mesonpy-m4vblvlb\build
Build type: native build
Project name: SciPy
Project version: 1.10.1
..\..\meson.build:1:0: ERROR: Could not invoke sanity test executable: [WinError 5] Access is denied.
A full log can be found at C:\Users\x_AMishra\AppData\Local\Temp\pip-install-i4ll3fah\scipy_50446030ddc0489785aefbfe1a690e40\.mesonpy-m4vblvlb\build\meson-logs\meson-log.txt
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
现在主要错误似乎是这样的,除此之外,我还收到此弹出消息 - 弹出消息ERROR: Could not invoke sanity test executable: [WinError 5] Access is denied.
有没有更好的方法来安装记录链接?或者有没有办法解决这个错误?
答:
0赞
Brock Brown
4/19/2023
#1
在 Python 3.11 更新中,对 Faster cPython 的大力推动,因此整体行为可能会大不相同。我记得当 3.11 出来时,我什至不能,因为在他们更新软件包之前它是不兼容的。我建议回过头来尝试一下。pip install pygame
pygame
Python 3.10
评论
1赞
Aayush Mishra
4/19/2023
我卸载了python 3.11并下载了3.10,工作起来就像一个魅力,谢谢!
0赞
Brock Brown
4/19/2023
@AayushMishra 没问题,玩得开心!:)
评论