解决 Python 扩展模块编译期间无法解析的外部符号错误

问题描述 投票:0回答:1

我正在尝试运行这个项目 https://github.com/CMU-SAFARI/Sibyl 我按照 github 存储库中提到的步骤进行操作。在我的命令提示符下运行命令

python setup.py develop
后,它弹出了这个错误。 我正在使用 cython 0.29.21 非常感谢任何解决此问题的帮助。

 Creating library build\temp.win-amd64-cpython-310\Release\pandas\_libs\internals.cp310-win_amd64.lib and object build\temp.win-amd64-cpython-310\Release\pandas\_libs\internals.cp310-win_amd64.exp
internals.obj : error LNK2001: unresolved external symbol _PyGen_Send
build\lib.win-amd64-cpython-310\pandas\_libs\internals.cp310-win_amd64.pyd : fatal error LNK1120: 1 unresolved externals
error: Setup script exited with error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2022\\BuildTools\\VC\\Tools\\MSVC\\14.38.33130\\bin\\HostX86\\x64\\link.exe' failed with exit code 1120

我尝试使用各种版本的 TensorFlow 和 pandas 库。我已经安装了 Visual Studio C++ 工具 2022。

python pandas visual-studio error-handling cython
1个回答
0
投票

您想要更新 Cython。该函数已从 Python 中删除。 Cython 0.29.22 是第一个适应更改的版本:https://github.com/cython/cython/commit/b37607f46b165e81f7af2b4eec2ae7f76f7717df.

© www.soinside.com 2019 - 2024. All rights reserved.