2017-05-29 133 views
0

我的配置是:openpose编译告诉libopenpose.so:到`运:: renderPartAffinityFieldGpu未定义的引用(... T)”

Openpose:latest(2017-05-29) master branch 
Caffe :latest(2017-05-29) master branch 
OpenCV :3.1 
Ubuntu 16.04 64bit 
GCC  :5.4.0 20160609 (Ubuntu 5.4.0-6ubuntu1~16.04.4) 

我想尝试openpose在我的笔记本电脑与AMD显卡,所以我禁用CUDA,并启用了OpenCV的3朱古力Makefile.config这样的:

CPU_ONLY := 1 
OPENCV_VERSION := 3 

编译朱古力后,

cp openpose/3rdparty/caffe/Makefile.config openpose/ 

然后

make all -j 10 

了这些:

CXX/LD -o .build_release/examples/tutorial_thread/1_openpose_read_and_display.bin 
CXX/LD -o .build_release/examples/tutorial_thread/3_user_input_processing_and_output.bin 
.build_release/lib/libopenpose.so: undefined references to `op::renderPartAffinityFieldGpu(float*, op::PoseModel, cv::Size_<int> const&, float const*, cv::Size_<int> const&, float, int, float)' 
.build_release/lib/libopenpose.so: undefined references to `op::renderBodyPartsGpu(float*, op::PoseModel, cv::Size_<int> const&, float const*, cv::Size_<int> const&, float, float)' 
.build_release/lib/libopenpose.so: undefined references to `void op::connectBodyPartsGpu<float>(op::Array<float>&, float*, float const*, float const*, op::PoseModel, cv::Size_<int> const&, int, int, float, int, float, float)' 
.build_release/lib/libopenpose.so: undefined references to `void op::connectBodyPartsGpu<double>(op::Array<double>&, double*, double const*, double const*, op::PoseModel, cv::Size_<int> const&, int, int, double, int, double, double)' 
.build_release/lib/libopenpose.so: undefined references to `op::renderBodyPartGpu(float*, op::PoseModel, cv::Size_<int> const&, float const*, cv::Size_<int> const&, float, int, float)' 
.build_release/lib/libopenpose.so: undefined references to `cudaGetErrorString' 
.build_release/lib/libopenpose.so: undefined references to `cudaFree' 
.build_release/lib/libopenpose.so: undefined references to `void op::resizeAndMergeGpu<double>(double*, double const*, std::array<int, 4ul> const&, std::array<int, 4ul> const&, double)' 
.build_release/lib/libopenpose.so: undefined references to `cudaPeekAtLastError' 
.build_release/lib/libopenpose.so: undefined references to `op::renderHandsGpu(float*, cv::Size_<int> const&, float const*, int, float)' 
.build_release/lib/libopenpose.so: undefined references to `void op::nmsGpu<float>(float*, int*, float const*, float, std::array<int, 4ul> const&, std::array<int, 4ul> const&)' 
.build_release/lib/libopenpose.so: undefined references to `cudaMalloc' 
.build_release/lib/libopenpose.so: undefined references to `cudaMemcpy' 
.build_release/lib/libopenpose.so: undefined references to `void op::resizeAndMergeGpu<float>(float*, float const*, std::array<int, 4ul> const&, std::array<int, 4ul> const&, float)' 
.build_release/lib/libopenpose.so: undefined references to `op::renderFaceGpu(float*, cv::Size_<int> const&, float const*, int, float)' 
.build_release/lib/libopenpose.so: undefined references to `void op::nmsGpu<double>(double*, int*, double const*, double, std::array<int, 4ul> const&, std::array<int, 4ul> const&)' 
.build_release/lib/libopenpose.so: undefined references to `op::renderPoseGpu(float*, op::PoseModel, int, cv::Size_<int> const&, float const*, bool, bool, float)' 
.build_release/lib/libopenpose.so: undefined references to `op::renderPartAffinityFieldsGpu(float*, op::PoseModel, cv::Size_<int> const&, float const*, cv::Size_<int> const&, float, float)' 
collect2: error: ld returned 1 exit status 
Makefile:492: die Regel für Ziel „.build_release/examples/tutorial_thread/3_user_input_processing_and_output.bin“ scheiterte 
make: *** [.build_release/examples/tutorial_thread/3_user_input_processing_and_output.bin] Fehler 1 
make: *** Auf noch nicht beendete Prozesse wird gewartet … 

看来,示例代码仍然使用CUDA/GPU相关的东西,是这样吗如何解决这个问题?

回答

0

很抱歉,您无法为OpenPose(或OpenPose将使用的Caffe)禁用GPU。

OpenPose的CPU代码尚未完成(并且由于速度非常慢,因此暂时不会完成)。你将不得不使用CUDA + cuDNN。因此,一台装有NVIDIA图形卡的机器。

相关问题