caffe-windows icon indicating copy to clipboard operation
caffe-windows copied to clipboard

error in compiling caffe on linux {hotspot_layer}

Open robosina opened this issue 6 years ago • 1 comments

I want to make caffe on ubunut 16.04.3 but I get some error that I can't find in like issue in google.my system config is as below:

opencv version 3 cuda version 9 cudnn version 7

the error I get is

92 errors detected in the compilation of "/tmp/tmpxft_00004404_00000000-6_hotspot_layer.cpp1.ii". Makefile:594: recipe for target '.build_release/cuda/src/caffe/layers/hotspot_layer.o' failed make: *** [.build_release/cuda/src/caffe/layers/hotspot_layer.o] Error 1

robosina avatar Dec 29 '18 06:12 robosina

I solve it with upgrading gcc to version 6.

for upgrading gcc you can use below commands.(link to source)

sudo apt-get update && \
sudo apt-get install build-essential software-properties-common -y && \
sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y && \
sudo apt-get update && \
sudo apt-get install gcc-6 g++-6 -y && \
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-6 60 --slave /usr/bin/g++ g++ /usr/bin/g++-6 && \
gcc -v

robosina avatar Dec 29 '18 06:12 robosina