[seetaface] installation log

来源:互联网 发布:手机万能遥控器软件 编辑:程序博客网 时间:2024/06/06 12:53

环境
Ubuntu 16.04
opencv 2.4.13.2
seetaface Detection installation log@2017.10.15

step 0

没有装opencv的先装opencv
参考
https://docs.opencv.org/2.4/doc/tutorials/introduction/linux_install/linux_install.html

opencv2.4 确定可用

step 1

安装seetaface

seetaface在github的仓库中有源码 git clone 到本地以后
会发现有三个子仓库,三个需要分别make 按照官方给的.md的说明就可以

error1

seetaface Detection编译的过程中可能会遇到这种错误

/usr/bin/ld: cannot find -lopencv_dep_cudart

参考[1]

pi@pi:~/projects/seetaface/SeetaFaceEngine/FaceDetection/build$ cmake ..-- C++11 support has been enabled by default.-- Use SSE-- Use OpenMP-- Build with examples.-- Configuring done-- Generating done-- Build files have been written to: /home/pi/projects/seetaface/SeetaFaceEngine/FaceDetection/buildpi@pi:~/projects/seetaface/SeetaFaceEngine/FaceDetection/build$ make -j${nproc}[ 85%] Built target seeta_facedet_lib[ 92%] Linking CXX executable facedet_test/usr/bin/ld: cannot find -lopencv_dep_cudartcollect2: error: ld returned 1 exit statusCMakeFiles/facedet_test.dir/build.make:118: recipe for target 'facedet_test' failedmake[2]: *** [facedet_test] Error 1CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/facedet_test.dir/all' failedmake[1]: *** [CMakeFiles/facedet_test.dir/all] Error 2Makefile:83: recipe for target 'all' failedmake: *** [all] Error 2pi@pi:~/projects/seetaface/SeetaFaceEngine/FaceDetection/build$

解决方法

可能出现/usr/bin/ld: cannot find -lopencv_dep_cudart 解决方法,在执行cmake的时候加入下面的参数CUDA_USE_STATIC_CUDA_RUNTIME=OFF,例如cmake -D CUDA_USE_STATIC_CUDA_RUNTIME=OFF ..

error2

编译完成以后运行

cd imgwget http://xx./1.jpgcd .../build/facedet_test img/1.jpg ./model/seeta_fd_frontal_v1.0.bin 

的时候可能会出现别的问题

(gedit:9625): Gtk-WARNING **: cannot open display: localhost:10.0

检查一下是不是自己vnc的问题
再看看是不是用的screen
切换到vnc的shell运行 不要用screen
如果还没有解决 参考[[2]]

(https://superuser.com/questions/310197/how-do-i-fix-a-cannot-open-display-error-when-opening-an-x-program-after-sshi)

error3

编译文件的默认环境是PC,而在ARM平台上,比如TX1运行的时候会出现编译错误:

c++: error: unrecognized command line option ‘-msse4.1’

这是由于CmakeList.txt文件中默认开启了对Intel的SSE支持(参考[3])

解决方案
编辑CMakeLists.txt
找到SSE支持 关闭
USE_SSE:BOOL=OFF
rm -r build 重新编译

恩…安装完成

reference

http://m.blog.csdn.net/u012336567/article/details/52746024

原创粉丝点击