gpt4 book ai didi

python - cython_bbox.so : undefined symbol: _Py_ZeroStruct

转载 作者:太空宇宙 更新时间:2023-11-03 14:52:49 24 4
gpt4 key购买 nike

我尝试执行所有这些步骤,因为我想要在 Linux 上使用不同版本的 Python 3.5 来运行此示例中的代码 https://learn.microsoft.com/en-us/cognitive-toolkit/Object-Detection-using-Fast-R-CNN

如果您需要不同的版本,您可以按照以下步骤进行编译:

git clone --recursive https://github.com/rbgirshick/fast-rcnn.git
cd $FRCN_ROOT/lib
make
python setup.py build_ext --inplace.
copy the generated cython_bbox and cython_nms binaries from
$FRCN_ROOT/lib/utils to $CNTK_ROOT/Examples/Image/Detection/FastRCNN/fastRCNN/utils
**Error**
Traceback (most recent call last):
File "C1_DrawBboxesOnImages.py", line 10, in <module>
from cntk_helpers import *
File "/home/tftuts/Desktop/tensorflow/CNTK-master/Examples/Image/Detection/FastRCNN/cntk_helpers.py", line 13, in <module>
from fastRCNN.nms import nms as nmsPython
File "/home/tftuts/Desktop/tensorflow/CNTK-master/Examples/Image/Detection/FastRCNN/fastRCNN/__init__.py", line 7, in <module>
from .imdb import imdb
File "/home/tftuts/Desktop/tensorflow/CNTK-master/Examples/Image/Detection/FastRCNN/fastRCNN/imdb.py", line 16, in <module>
from .utils.cython_bbox import bbox_overlaps
ImportError: /home/tftuts/Desktop/tensorflow/CNTK-master/Examples/Image/Detection/FastRCNN/fastRCNN/utils/cython_bbox.so: undefined symbol: _Py_ZeroStruct

请任何人帮助我。什么意思

cython_bbox.so: undefined symbol: _Py_ZeroStruct 

以及如何解决这个问题。

最佳答案

当 Python 模块中存在版本不匹配时,此错误消息很典型。它可能像 cython_bbox.so 是针对 Python 2.7 编译和链接的,CNTK 是针对 Python 3.5 编译的。很难说到底是什么原因,但您可以尝试在与您的 CNTK 版本相匹配的 python 环境中执行 make,看看是否可行。

关于python - cython_bbox.so : undefined symbol: _Py_ZeroStruct,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44737063/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com