[caffe笔记001]:caffe依赖库安装(非root)
来源:互联网 发布:92game 极客网源码 编辑:程序博客网 时间:2024/05/22 09:42
[========]
1. caffe介绍
caffe是一个训练卷积神经网络的工具,其能够非常好的支持CNN,最新版本整合了RNN。caffe提供python和matlab的借口,能够简单有效地进行编程和使用。
2. caffe安装
2.1 caffe版本选择
- 官网版本
版本随时更新
https://github.com/BVLC/caffe - R-CNN
caffe v0.999版
https://github.com/BVLC/caffe/archive/v0.999.tar.gz - FCN
caffe-future
https://github.com/longjon/caffe/tree/future - DSN
不清楚其版本号
https://github.com/s9xie/DSN
2.2 依赖库安装
2.2.1 有root权限
网上教程很多。
2.2.2 非root权限
在已经安装好cuda和python以及各种常用的python依赖包之后,caffe在编译之前只需要安装以下依赖库:
- protobuf
- snappy
- leveldb
- openCV
- boost
- lbdb
- gflags
- glog
- hdf5
- openblas, atlas, mkl三选一
Install protobuf:
版本:2.5.0
安装python版
下载完成之后
$ cd protobuf/ $ cd python $ python setup.py build $ python setup.py install --user
$ cd ~/temp/ $ git clone https://github.com/google/protobuf.git $ cd protobuf/ $ ./autogen.sh $ ./configure --prefix=$HOME/local $ make $ make install
Install snappy:
$ cd ~/temp/ $ git clone https://github.com/google/snappy.git $ cd snappy $ ./autogen.sh $ ./configure --prefix=$HOME/local $ make $ make install
Install leveldb:
$ cd ~/temp/ $ git clone https://github.com/google/leveldb.git $ cd leveldb $ make $ cp -av libleveldb.* $HOME/local/lib/ $ cp -av include/leveldb $HOME/local/include/
最后两步可以直接手动拷贝
Install OpenCV:
版本:2.4.8
http://stackoverflow.com/questions/28010399/build-opencv-with-cuda-support
$ cd ~/temp/ $ wget 'https://github.com/Itseez/opencv/archive/2.4.8.tar.gz' $ tar xzf 2.4.8.tar.gz $ cd opencv-2.4.8/ $ cmake -D CMAKE_BUILD_TYPE=RELEASE -D CMAKE_INSTALL_PREFIX=$HOME/local -D BUILD_opencv_gpu=OFF -D CUDA_GENETATION=AUTO .. $ make $ make install
Install Boost:
版本:1.55.0
$ cd ~/temp/ $ wget “http://sourceforge.net/projects/boost/files/boost/1.55.0/boost_1_55_0.tar.gz” $ tar xzf boost_1_55_0.tar.gz $ cd boost_1_55_0 ($ ./bootstrap.sh --prefix=$HOME/local) $ ./bootstrap.sh --prefix=$HOME/local --with-python=python2.7 $ ./b2 -j 32 $ ./b2 install ...failed updating 2 targets... ...skipped 6 targets... ...updated 62 targets...
Install lmdb:
$ cd ~/temp $ git clone https://github.com/LMDB/lmdb $ cd mdb/libraries/liblmdb $ make $ mkdir $HOME/local/man/man1 $ make prefix=$HOME/local install
Install gflags:
版本:1.7,需要先安装gflags,再安装glog,其它依赖库可以并行安装
$ cd ~/temp/ $ git clone https://github.com/gflags/gflags/release/ $ mkdir build && cd build $ bash $ export CXXFLAGS="-fPIC" $ ./configure --prefix=$HOME/local .. $ make -j $ make install
版本:2.1.1
$ cd ~/temp/ $ git clone https://github.com/gflags/gflags/release/ $ mkdir build && cd build $ bash $ CXXFLAGS="-fPIC" cmake -D CMAKE_INSTALL_PREFIX=$HOME/local .. $ make -j $ make install
版本2.1.2后需要较高版本的CMake。
Install glog:
版本:0.3.3
$ cd ~/temp/ $ wget https://google-glog.googlecode.com/files/glog-0.3.3.tar.gz $ tar zxvf glog-0.3.3.tar.gz $ cd glog-0.3.3 $ ./configure --prefix=$HOME/local $ make && make install
Install hdf5:
matlab会自带hdf5,最好和matlab的版本号一致)。如果不一致,可以在linux设置环境变量
export HDF5_DISABLE_VERSION_CHECK=1
最新版版本号需要https://www.hdfgroup.org/ftp/HDF5/current/src/ 确认
$ cd ~/temp $ wget "https://www.hdfgroup.org/ftp/HDF5/current/src/hdf5-1.8.14.tar" $ tar -xf hdf5-1.8.14.tar $ cd hdf5-1.8.14 $ ./configure --prefix=$HOME/local $ make $ make check # run test suite. $ make install $ make check-install # verify installation.</pre>
OpenBlas:
$ cd ~/temp/$ git clone git://github.com/xianyi/OpenBLAS$ cd OpenBlas$ make FC=gfortran$ make PREFIX=$HOME/local install
- [caffe笔记001]:caffe依赖库安装(非root)
- ubuntu安装-Caffe依赖
- caffe依赖项安装
- CentOS 安装caffe步骤(非root、仅CPU、OpenBLAS、Intel MKL)
- caffe学习笔记(一)——caffe环境安装
- caffe学习笔记(八)caffe+MATLAB2016接口安装
- Caffe安装笔记二:Caffe安装过程
- 笔记:ubuntu 14.04/16.04(linux)下离线批量安装依赖库,caffe,cuda8.0
- Caffe安装笔记
- caffe安装笔记
- Caffe&&pycaffe安装笔记
- Caffe安装笔记
- caffe安装笔记
- Caffe Installation安装笔记
- caffe下python依赖库的安装及问题
- caffe安装笔记(Ubuntu,CPU)
- caffe install at centos 依赖软件包安装
- 纯备忘 caffe依赖包安装
- ActiveMQ中Producer特性详解
- 粒子群算法详解
- Spring Boot 过滤器、监听器
- Android开发省时神器--JRebel
- JQ选择器详解
- [caffe笔记001]:caffe依赖库安装(非root)
- unity linght
- TortoiseGit教程(简单粗暴版)
- 盘点:国内外军工行业(固态硬盘)数据销毁方式
- 贪心入门1(完美字符串)
- MyXls导出Excel的各种设置
- 每日一题(18): poj1159
- css3中webkit-box的用法
- 判断101-200之间有多少个素数,并输出所有素数。