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
