ubuntu16.04下py-faster-rcnn安裝

来源:互联网 发布:mybatis sql使用别名 编辑:程序博客网 时间:2024/06/05 00:59

請注意,本類僅僅是記錄開發過程中遇到對問題,可能會亂貼代碼,亂貼圖,亂貼報錯信息,不保證能解決問題,以及有優美的排版,後面有時間我會重新整理的。
主要還是參考GitHub上的README.md
我這裏只填坑
安裝依賴

sudo pip install easydict --upgrade -i http://pypi.douban.com/simple sudo apt install python-opencvsudo apt install python-tk 

報錯信息

ImportError: No module named easydictImportError: No module named cv2ImportError: No module named _tkinter, please install the python-tk packageTraceback (most recent call last):  File "./tools/demo.py", line 135, in <module>    net = caffe.Net(prototxt, caffemodel, caffe.TEST)AttributeError: can't set attribute

最後一個AttributeError: can't set attribute
需要注釋掉源碼中的一行,重新編譯。
include/caffe/layers/python_layer.hpp 中,注釋掉

self_.attr("phase") = static_cast(this->phase_);

方法我也是從GitHub上找的
GitHub的解決請點這裏

原创粉丝点击