Win 10 安裝caffe

Procedure for installing caffe deep learning framework on windows

  1. install vs 2013 or 2015.

  2. install CMake 3.4 or higher from https://cmake.org/ and add to system path of computer

  3. install python 2.7.13 and add to system path of computer (install miniconda 2.7 would be better)

  4. install matlab for using the matlab interface (if you prefer python interface, skip this step)

  5. Install CUDA Tookkit from https://developer.nvidia.com/cuda-downloads \
    (note: using cuda 8.0 if you use the visual studio 2015)

  6. Download cuDNN v6.0 from https://developer.nvidia.com/cudnn; Extract and copy to the install directory of CUDA ToolKit. (i.e.,C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0)

  7. Run the cmd of windows and following command to install additional python packages
    conda config –add channels conda-forge
    conda config –add channels willyd
    conda install –yes cmake ninja numpy scipy protobuf==3.1.0 six scikit-image pyyaml pydotplus graphviz
    Note, to boost the download process, try to add a internal download mirror

  8. Run the following command to build the Caffe library.
    c:\projects> git clone https://github.com/BVLC/caffe.git
    c:\projects> cd caffe
    c:\projects\caffe> git checkout windows

  9. Edit any of the options inside build_win.cmd to suit your needs. In my case, skip to step 10 directly.

  10. C:\projects\caffe> scripts\build_win.cmd
    (Note: Using ninja will make the installation faster than using only Visual Studio)

There are some errors during the first run of step 10, and they are solved by just rerun step 10 several times.
HOW TO USE Python Interface
In order to use the python interface you need to either add the C:\Projects\caffe\python folder to your python path or copy the C:\Projects\caffe\python\caffe folder to your site_packages folder.

Result screen capture:
這裏寫圖片描述

這裏寫圖片描述