pyhon版faster-r-cnn搭建


1.https://github.com/rbgirshick/py-faster-rcnn

参考本链接,下载相应的Makefile.config,如果使用CPU则uncomment CPU := 1

注意python的版本,及以来的python第三方库。

如果使用Anaconda Python,还需要安装python-opencv,easydict,protobuf

Linux下安装python-opencv  http://blog.csdn.net/llp1992/article/details/50066983

Linux下安装easydict  下载https://pypi.python.org/pypi/easydict, python setup.py install

python版protobuf安装, http://www.cnblogs.com/chegnshi-coding/p/4457738.html

2. faster r-cnn CPU版本编译与运行

http://blog.sina.com.cn/s/blog_679f93560102wpyf.html

http://blog.csdn.net/wuzuyu365/article/details/51895255

(cpu版本容易出现如下错误:

ImportError: No module named gpu_nms
修改nms_wrapper.py,改 force_cpu = True
[root@localhost py-faster-rcnn]# vi lib/fast_rcnn/nms_wrapper.py
def nms ( dets , thresh , force_cpu = True ):

3.Export设置python caffe路径,参考官网python caffe教程

vim /etc/profile
profile最后添加: export PYTHONPATH=/root/$CAFFE_ROOT/python:$PYTHONPATH source /etc/profile


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM