Reputation: 63062
An attempt to build the gpu based caffe
docker image was unsuccessful. The command run:
docker build -t caffe:gpu standalone/gpu
It ran for about twenty minutes including compiling many numpy/scikit scripts to c-code via cython
. However the build finally failed in an nvidia nvcc
step:
[ 1%] [ 1%] Building NVCC (Device) object src/caffe/CMakeFiles/cuda_compile.dir/layers/./cuda_compile_generated_cudnn_pooling_layer.cu.o
Building NVCC (Device) object src/caffe/CMakeFiles/cuda_compile.dir/util/./cuda_compile_generated_im2col.cu.o
nvcc fatal : Unsupported gpu architecture 'compute_60'
CMake Error at cuda_compile_generated_cudnn_pooling_layer.cu.o.cmake:206 (message):
Error generating
/opt/caffe/build/src/caffe/CMakeFiles/cuda_compile.dir/layers/./cuda_compile_generated_cudnn_pooling_layer.cu.o
make[2]: *** [src/caffe/CMakeFiles/cuda_compile.dir/layers/./cuda_compile_generated_cudnn_pooling_layer.cu.o] Error 1
make[2]: *** Waiting for unfinished jobs....
nvcc fatal : Unsupported gpu architecture 'compute_60'
CMake Error at cuda_compile_generated_im2col.cu.o.cmake:206 (message):
Error generating
/opt/caffe/build/src/caffe/CMakeFiles/cuda_compile.dir/util/./cuda_compile_generated_im2col.cu.o
make[2]: *** [src/caffe/CMakeFiles/cuda_compile.dir/util/./cuda_compile_generated_im2col.cu.o] Error 1
make[1]: *** [src/caffe/CMakeFiles/caffe.dir/all] Error 2
make: *** [all] Error 2
I am on El Capitan
and running on a late 2013 MBPro that has the GT750m
nvidia chipset.
Note: The cpu based caffe
docker image from their github repo: https://github.com/BVLC/caffe docker
was successfully built inside the caffe/docker
directory on my mac:
docker build -t caffe:cpu standalone/cpu
.. and about ten minutes later ..
Successfully built bf71c19501e5
There is some mention of a different project arrayfire
encountering similar error https://github.com/arrayfire/arrayfire/issues/1535 . However I lack the specific knowledge to troubleshoot the BVLC/caffe/docker
commands to try to replicate what appears to be cuda7.5
vs cuda8.0
versioning issues.
Has anyone successfully built the gpu version of Caffe on docker container from mac?
Upvotes: 2
Views: 3096
Reputation: 5540
In the Makefile.example, try commenting out the *_60 and *_61 lines (for compatibility with CUDA < 8.0).
CUDA_ARCH := -gencode arch=compute_20,code=sm_20 \
-gencode arch=compute_20,code=sm_21 \
-gencode arch=compute_30,code=sm_30 \
-gencode arch=compute_35,code=sm_35 \
-gencode arch=compute_50,code=sm_50 \
-gencode arch=compute_52,code=sm_52 \
#-gencode arch=compute_60,code=sm_60 \
#-gencode arch=compute_61,code=sm_61 \
#-gencode arch=compute_61,code=compute_61
Upvotes: 2