caffe-windows cpu下编译python接口/matlab接口
2017-07-20 09:51
549 查看
1.下载caffe-windwos:https://github.com/BVLC/caffe/tree/windows
2.修改scripts/build_win.cmd:
64行以后::: Change the settings here to match your setup
:: Change MSVC_VERSION to 12 to use VS 2013
if NOT DEFINED MSVC_VERSION set MSVC_VERSION=14
:: Change to 1 to use Ninja generator (builds much faster)
if NOT DEFINED WITH_NINJA set WITH_NINJA=0
:: Change to 1 to build caffe without CUDA support
if NOT DEFINED CPU_ONLY set CPU_ONLY=1
:: Change to generate CUDA code for one of the following GPU architectures
:: [Fermi Kepler Maxwell Pascal All]
if NOT DEFINED CUDA_ARCH_NAME set CUDA_ARCH_NAME=Auto
:: Change to Debug to build Debug. This is only relevant for the Ninja generator the Visual Studio generator will generate both Debug and Release configs
if NOT DEFINED CMAKE_CONFIG set CMAKE_CONFIG=Release
:: Set to 1 to use NCCL
if NOT DEFINED USE_NCCL set USE_NCCL=0
:: Change to 1 to build a caffe.dll
if NOT DEFINED CMAKE_BUILD_SHARED_LIBS set CMAKE_BUILD_SHARED_LIBS=0
:: Change to 3 if using python 3.5 (only 2.7 and 3.5 are supported)
if NOT DEFINED PYTHON_VERSION set PYTHON_VERSION=3
:: Change these options for your needs.
if NOT DEFINED BUILD_PYTHON set BUILD_PYTHON=1
if NOT DEFINED BUILD_PYTHON_LAYER set BUILD_PYTHON_LAYER=1
if NOT DEFINED BUILD_MATLAB set BUILD_MATLAB=1
:: If python is on your path leave this alone
if NOT DEFINED PYTHON_EXE set PYTHON_EXE=python
:: Run the tests
if NOT DEFINED RUN_TESTS set RUN_TESTS=0
:: Run lint
if NOT DEFINED RUN_LINT set RUN_LINT=0
:: Build the install target
if NOT DEFINED RUN_INSTALL set RUN_INSTALL=0
3.dos下,运行scripts/build_win.cmd
4.pycaffe:将运行完成后的python目录下caffe目录拷贝到:C:\Python35\Lib\site-packages
5.matlab:将caffe-windows\matlab\+caffe\private\Release目录下的caffe_.mexw64拷贝到caffe-windows\matlab\+caffe\private,并在matlab软件里设置路径:caffe-windows\matlab。
2.修改scripts/build_win.cmd:
64行以后::: Change the settings here to match your setup
:: Change MSVC_VERSION to 12 to use VS 2013
if NOT DEFINED MSVC_VERSION set MSVC_VERSION=14
:: Change to 1 to use Ninja generator (builds much faster)
if NOT DEFINED WITH_NINJA set WITH_NINJA=0
:: Change to 1 to build caffe without CUDA support
if NOT DEFINED CPU_ONLY set CPU_ONLY=1
:: Change to generate CUDA code for one of the following GPU architectures
:: [Fermi Kepler Maxwell Pascal All]
if NOT DEFINED CUDA_ARCH_NAME set CUDA_ARCH_NAME=Auto
:: Change to Debug to build Debug. This is only relevant for the Ninja generator the Visual Studio generator will generate both Debug and Release configs
if NOT DEFINED CMAKE_CONFIG set CMAKE_CONFIG=Release
:: Set to 1 to use NCCL
if NOT DEFINED USE_NCCL set USE_NCCL=0
:: Change to 1 to build a caffe.dll
if NOT DEFINED CMAKE_BUILD_SHARED_LIBS set CMAKE_BUILD_SHARED_LIBS=0
:: Change to 3 if using python 3.5 (only 2.7 and 3.5 are supported)
if NOT DEFINED PYTHON_VERSION set PYTHON_VERSION=3
:: Change these options for your needs.
if NOT DEFINED BUILD_PYTHON set BUILD_PYTHON=1
if NOT DEFINED BUILD_PYTHON_LAYER set BUILD_PYTHON_LAYER=1
if NOT DEFINED BUILD_MATLAB set BUILD_MATLAB=1
:: If python is on your path leave this alone
if NOT DEFINED PYTHON_EXE set PYTHON_EXE=python
:: Run the tests
if NOT DEFINED RUN_TESTS set RUN_TESTS=0
:: Run lint
if NOT DEFINED RUN_LINT set RUN_LINT=0
:: Build the install target
if NOT DEFINED RUN_INSTALL set RUN_INSTALL=0
3.dos下,运行scripts/build_win.cmd
4.pycaffe:将运行完成后的python目录下caffe目录拷贝到:C:\Python35\Lib\site-packages
5.matlab:将caffe-windows\matlab\+caffe\private\Release目录下的caffe_.mexw64拷贝到caffe-windows\matlab\+caffe\private,并在matlab软件里设置路径:caffe-windows\matlab。
相关文章推荐
- windows配置caffe及matlab/python接口编译和调用(cpu/gpu)
- 如何快糙好猛地在Windows下编译CAFFE并使用其matlab和python接口
- 如何快糙好猛地在Windows下编译CAFFE并使用其matlab和python接口
- 如何快糙好猛地在Windows下编译CAFFE并使用其matlab和python接口
- 如何快糙好猛地在Windows下编译CAFFE并使用其matlab和python接口
- 如何快糙好猛地在Windows下编译CAFFE并使用其matlab和python接口
- 如何快糙好猛地在Windows下编译CAFFE并使用其matlab和python接口
- 在Windows下编译CAFFE并使用其matlab和python接口
- 如何快糙好猛地在Windows下编译CAFFE并使用其matlab和python接口
- 如何快糙好猛地在Windows下编译CAFFE并使用其matlab和python接口
- 如何快糙好猛地在Windows下编译CAFFE并使用其matlab和python接口
- win10编译安装caffe的CPU版本和matlab及python接口
- 关于Windows下编译Caffe的Matlab接口
- 【caffe-Windows】微软官方caffe之 matlab接口cpu配置
- windows下编译Caffe的MATLAB接口
- 在Windows下编译Caffe的Python接口
- Windows下编译Caffe并编译Matlab接口
- 深度学习之Windows下安装caffe及配置Python和matlab接口
- windows环境下caffe编译以及python接口配置教程(超详细)