0

运行时遇到错误

make -j`sysctl -n hw.logicalcpu`

在 maxos catalina 上构建 openpose:

[ 40%] Linking CXX shared library libopenpose.dylib
Undefined symbols for architecture x86_64:
  "caffe::Net<float>::CopyTrainedLayersFrom(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >)", referenced from:
      op::NetCaffe::initializationOnThread() in netCaffe.cpp.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[5]: *** [src/openpose/libopenpose.1.5.1.dylib] Error 1
make[4]: *** [src/openpose/CMakeFiles/openpose.dir/all] Error 2
make[3]: *** [all] Error 2
make[2]: *** [openpose_lib] Error 2
make[1]: *** [CMakeFiles/openpose_lib.dir/all] Error 2
make: *** [all] Error 2

如果你们对此有所了解,请帮助我...

4

1 回答 1

0

问题解决了。事实证明,openpose 内置的 caffe 效果不佳。首先在openpose之外独立安装CAFFE。其次,在构建openpose时,在cmake中将BUILD_CAFFE标志设置为false,并在cmake中手动指定CMAKE_INCLUDE目录和CMAKE_LIBS文件的路径。

于 2020-03-07T11:56:55.230 回答