安装相关依赖包
1.sudo apt-get install git
2.sudo apt-get instasudo apt-get install libprotobuf-dev libleveldb-dev libsnappy-dev libopencv-dev libhdf5-serial-dev protobuf-compilerll libprotobuf-dev libleveldb libsnappy libopencv libhdf5-serial protobuf-compiler
3. install --no-install-recommends libboost-all-dev
4. install libopenblas liblapack libatlas-base-dev
5. install libgflags libgoogle-glog liblmdb-dev
获取caffe
git clone https://github.com/bvlc/caffe.git
cd caffe/
准备好一些配置
具体可以使用sudo find / name <>来查找
开始编译
make -j8
原文链接:https://www.f2er.com/ubuntu/351990.html