s1:
git clone
cd caffe
git checkout ssd
s2:
cp Makefile.config.example Makefile.config
make -j8
make py
make test -j12
make runtest –j12
出现问题:
缺少-lopenblas
sudo apt-get install openblas-dev
fatal error:caffe/proto/caffe/caffe.pb.h:No such file or directory
#include "caffe/proto/caffe.pb.h"
cd src/caffe/proto
protoc --cpp_out=/home/fp/sotware/ssd/caffe/incude/caffe caffe.proto
libstdc++.so版本问题
首先将所有不是最新的libstdc++.so.6都设置为libstdc++.so.6_
其次更行anaconda的libgcc
s3:下载数据
cd $HOME/data
wget http://host.robots.ox.ac.uk/pascal/VOC/voc2012/VOCtrainval_11-May-2012.tar
wget http://host.robots.ox.ac.uk/pascal/VOC/voc2007/VOCtrainval_06-Nov-2007.tar
wget http://host.robots.ox.ac.uk/pascal/VOC/voc2007/VOCtest_06-Nov-2007.tar
# Extract the data.
tar -xvf VOCtrainval_11-May-2012.tar
tar -xvf VOCtrainval_06-Nov-2007.tar
tar -xvf VOCtest_06-Nov-2007.tar
处理数据:
./data/VOC0712/create_list.sh
./data/VOC0712/create_data.sh
出现问题:
AttributeError: 'module' object has no attribute 'LabelMap'
导出caffe-ssd的python
export PYTHONPATH=/home/fp/caffe-ssd/caffe/python
s4:
训练
python examples/ssd/ssd_pascal.py
下在训练好的模型
https://drive.google.com/file/d/0BzKzrI_SkD1_WVVTSmQxU0dVRzA/view
测试
python examples/ssd/score_ssd_pascal.py
web cam测试
python examples/ssd/ssd_pascal_webcam.py