我正在尝试编译最新版本(v0.8.5)的mediapipe库,在我的MacBook Pro上运行High Sierra,使用的是gcc 11.1.0版和bazel 3.7.2版。
按照mediapipe GitHub站点上提到的所有安装步骤进行操作后,我能够成功地运行HelloWorld示例,如下所示。
bazel run --define MEDIAPIPE_DISABLE_GPU=1 \
mediapipe/examples/desktop/hello_world:hello_world然后,我按照步骤运行YouTube-8M特征提取图,当我尝试运行mediapipe二进制文件来提取特征时,如下所示,它编译失败。
bazel build -c opt --linkopt=-s \
--define MEDIAPIPE_DISABLE_GPU=1 --define no_aws_support=true \
mediapipe/examples/desktop/youtube8m:extract_yt8m_features我得到的错误如下
ERROR: /Users/xxx/Documents/ml-projects/FeatureExtraction/mediapipe/mediapipe/examples/desktop/youtube8m/BUILD:17:10 C++ compilation of rule '@org_tensorflow//tensorflow/core/platform:tensor_coding' failed (Exit 1): cc_wrapper.sh failed: error executing command external/local_config_cc/cc_wrapper.sh -U_FORTIFY_SOURCE -fstack-protector -Wall -Wthread-safety -Wself-assign -fcolor-diagnostics -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG ... (remaining 69 argument(s) skipped)
Use --sandbox_debug to see verbose messages from the sandbox cc_wrapper.sh failed: error executing command external/local_config_cc/cc_wrapper.sh -U_FORTIFY_SOURCE -fstack-protector -Wall -Wthread-safety -Wself-assign -fcolor-diagnostics -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG ... (remaining 69 argument(s) skipped)
Use --sandbox_debug to see verbose messages from the sandbox
INFO: Elapsed time: 13.351s, Critical Path: 8.50s
INFO: 333 processes: 130 internal, 203 darwin-sandbox.
FAILED: Build did NOT complete successfully有没有人能帮我提供解决这个问题的建议?
我试过使用较老的gcc版本-- 10和4--但没有成功。我还尝试使用旧版本0.8.1的mediapipe,但再次没有成功。
还安装了安装步骤中提到的所有必需的python库。
发布于 2021-06-27 22:53:50
TL;DR - MediaPipe不支持高塞拉
正如我的博客MediaPipe install fails on OS X所述,我在High Sierra (10.13.6)上安装MediaPipe时也遇到了很多问题。这些问题都存在于2010和2011年的MacBook Pro(仅限于高塞拉(10.13.6) )。
为了运行与MediaPipe兼容的OS版本,我不得不买了一个稍新的2012 MBP (13英寸i7) --它运行小牛(10.14)和卡特琳娜(10.15)。
显然,MediaPipe只适用于Catalina 10.15.x和更高版本,请参阅:
MediaPipe PyPI支持macOS 10.15及更高版本。参见https://github.com/google/mediapipe/blob/master/docs/getting_started/troubleshooting.md#python-pip-install-failure。
然而,你可以在High Sierra上使用Docker镜像-同样来自我的博客:
还有一个媒体接口的Docker安装,请参阅Installing using Docker。另请参阅Docker for High Sierra。
https://stackoverflow.com/questions/67932240
复制相似问题