mxnet icon indicating copy to clipboard operation
mxnet copied to clipboard

error installing with cudnn support

Open Lopezurrutia opened this issue 10 years ago • 7 comments

Hi, I am installing mxnet with cudnn support. I have a clean installation of:

lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 14.04.3 LTS Release: 14.04 Codename: trusty

lspci | grep -i nvidia 02:00.0 3D controller: NVIDIA Corporation GK110BGL [Tesla K40m](rev a1)

nvcc --version nvcc: NVIDIA (R) Cuda compiler driver Copyright (c) 2005-2015 NVIDIA Corporation Built on Tue_Aug_11_14:27:32_CDT_2015 Cuda compilation tools, release 7.5, V7.5.17

I installed cudnn-7.0-linux-x64-v3.0-prod.tgz and the mnistCUDNN example: cudnn-sample-v3.tgz compile and runs OK, so I understand my cudnn installation is fine.

followed instructions in http://mxnet.readthedocs.org/en/latest/build.html#building-on-ubuntu-debian

I have modified mxnet/make/config.mk so: USE_CUDA_PATH = /usr/local/cuda USE_CUDNN = 1

make throws this error:

g++ -std=c++0x -DMSHADOW_FORCE_STREAM -Wall -O3 -I./mshadow/ -I./dmlc-core/include -fPIC -Iinclude -msse3 -funroll-loops -Wno-unused-parameter -Wno-unknown-pragmas -DMSHADOW_USE_CUDA=0 -I/usr/local/cuda/include -DMSHADOW_USE_CBLAS=1 -DMSHADOW_USE_MKL=0 -DMSHADOW_RABIT_PS=0 -DMSHADOW_DIST_PS=0 -DMXNET_USE_OPENCV=1 pkg-config --cflags opencv -fopenmp -DMSHADOW_USE_CUDNN=1 -DMXNET_USE_NVRTC=0 -MM -MT build/operator/native_op.o src/operator/native_op.cc >build/operator/native_op.d g++ -std=c++0x -c -DMSHADOW_FORCE_STREAM -Wall -O3 -I./mshadow/ -I./dmlc-core/include -fPIC -Iinclude -msse3 -funroll-loops -Wno-unused-parameter -Wno-unknown-pragmas -DMSHADOW_USE_CUDA=0 -I/usr/local/cuda/include -DMSHADOW_USE_CBLAS=1 -DMSHADOW_USE_MKL=0 -DMSHADOW_RABIT_PS=0 -DMSHADOW_DIST_PS=0 -DMXNET_USE_OPENCV=1 pkg-config --cflags opencv -fopenmp -DMSHADOW_USE_CUDNN=1 -DMXNET_USE_NVRTC=0 -c src/operator/native_op.cc -o build/operator/native_op.o In file included from src/operator/./lrn-inl.h:9:0, from src/operator/lrn.cc:8: src/operator/./cudnn_lrn-inl.h: In member function ‘virtual void mxnet::op::CuDNNLocalResponseNormOp::Forward(const mxnet::OpContext&, const std::vectormshadow::TBlob&, const std::vectormxnet::OpReqType&, const std::vectormshadow::TBlob&, const std::vectormshadow::TBlob&)’: src/operator/./cudnn_lrn-inl.h:46:17: error: ‘struct mshadow::Streammshadow::gpu’ has no member named ‘dnn_handle_ownership_’ CHECK_EQ(s->dnn_handle_ownership_, mshadow::Stream::OwnHandle); ^ ./dmlc-core/include/dmlc/logging.h:68:9: note: in definition of macro ‘CHECK’ if (!(x))
^ src/operator/./cudnn_lrn-inl.h:46:5: note: in expansion of macro ‘CHECK_EQ’ CHECK_EQ(s->dnn_handle_ownership_, mshadow::Stream::OwnHandle); ^ src/operator/./cudnn_lrn-inl.h:46:40: error: ‘OwnHandle’ is not a member of ‘mshadow::Streammshadow::gpu’ CHECK_EQ(s->dnn_handle_ownership_, mshadow::Stream::OwnHandle); ^ ./dmlc-core/include/dmlc/logging.h:68:9: note: in definition of macro ‘CHECK’ if (!(x))
^ src/operator/./cudnn_lrn-inl.h:46:5: note: in expansion of macro ‘CHECK_EQ’ CHECK_EQ(s->dnn_handle_ownership_, mshadow::Stream::OwnHandle); ^ src/operator/./cudnn_lrn-inl.h:47:45: error: ‘struct mshadow::Streammshadow::gpu’ has no member named ‘dnn_handle_’ CHECK_EQ(cudnnLRNCrossChannelForward(s->dnn_handle_, ^ ./dmlc-core/include/dmlc/logging.h:68:9: note: in definition of macro ‘CHECK’ if (!(x))
^ src/operator/./cudnn_lrn-inl.h:47:5: note: in expansion of macro ‘CHECK_EQ’ CHECK_EQ(cudnnLRNCrossChannelForward(s->dnn_handle_, ^ src/operator/./cudnn_lrn-inl.h: In member function ‘virtual void mxnet::op::CuDNNLocalResponseNormOp::Backward(const mxnet::OpContext&, const std::vectormshadow::TBlob&, const std::vectormshadow::TBlob&, const std::vectormshadow::TBlob&, const std::vectormxnet::OpReqType&, const std::vectormshadow::TBlob&, const std::vectormshadow::TBlob&)’: src/operator/./cudnn_lrn-inl.h:79:17: error: ‘struct mshadow::Streammshadow::gpu’ has no member named ‘dnn_handle_ownership_’ CHECK_EQ(s->dnn_handle_ownership_, mshadow::Stream::OwnHandle); ^ ./dmlc-core/include/dmlc/logging.h:68:9: note: in definition of macro ‘CHECK’ if (!(x))
^ src/operator/./cudnn_lrn-inl.h:79:5: note: in expansion of macro ‘CHECK_EQ’ CHECK_EQ(s->dnn_handle_ownership_, mshadow::Stream::OwnHandle); ^ src/operator/./cudnn_lrn-inl.h:79:40: error: ‘OwnHandle’ is not a member of ‘mshadow::Streammshadow::gpu’ CHECK_EQ(s->dnn_handle_ownership_, mshadow::Stream::OwnHandle); ^ ./dmlc-core/include/dmlc/logging.h:68:9: note: in definition of macro ‘CHECK’ if (!(x))
^ src/operator/./cudnn_lrn-inl.h:79:5: note: in expansion of macro ‘CHECK_EQ’ CHECK_EQ(s->dnn_handle_ownership_, mshadow::Stream::OwnHandle); ^ src/operator/./cudnn_lrn-inl.h:80:46: error: ‘struct mshadow::Streammshadow::gpu’ has no member named ‘dnn_handle_’ CHECK_EQ(cudnnLRNCrossChannelBackward(s->dnn_handle_, ^ ./dmlc-core/include/dmlc/logging.h:68:9: note: in definition of macro ‘CHECK’ if (!(x))
^ src/operator/./cudnn_lrn-inl.h:80:5: note: in expansion of macro ‘CHECK_EQ’ CHECK_EQ(cudnnLRNCrossChannelBackward(s->dnn_handle_, ^ In file included from src/operator/./lrn-inl.h:10:0, from src/operator/lrn.cc:8: src/operator/lrn.cc: At global scope: ./dmlc-core/include/dmlc/parameter.h:254:43: warning: ‘mxnet::op::make__LRNParamParamManager’ defined but not used [-Wunused-variable] static ::dmlc::parameter::ParamManager &make ## PType ## ParamManager__ =
^ src/operator/lrn.cc:24:1: note: in expansion of macro ‘DMLC_REGISTER_PARAMETER’ DMLC_REGISTER_PARAMETER(LRNParam); ^ In file included from include/mxnet/operator.h:13:0, from src/operator/./lrn-inl.h:11, from src/operator/lrn.cc:8: ./dmlc-core/include/dmlc/registry.h:206:22: warning: ‘mxnet::op::make_OperatorPropertyReg_LRN’ defined but not used [-Wunused-variable] static EntryType & _make ## EntryTypeName ## _ ## Name ## __ =
^ include/mxnet/operator.h:480:3: note: in expansion of macro ‘DMLC_REGISTRY_REGISTER’ DMLC_REGISTRY_REGISTER(::mxnet::OperatorPropertyReg, OperatorPropertyReg, name)
^ src/operator/lrn.cc:26:1: note: in expansion of macro ‘MXNET_REGISTER_OP_PROPERTY’ MXNET_REGISTER_OP_PROPERTY(LRN, LocalResponseNormProp) ^ make: *** [build/operator/lrn.o] Error 1

Lopezurrutia avatar Jan 07 '16 12:01 Lopezurrutia

cudnn version?

qiaohaijun avatar Jan 07 '16 13:01 qiaohaijun

cudnn-7.0-linux-x64-v3.0

Lopezurrutia avatar Jan 07 '16 13:01 Lopezurrutia

the latest code?

qiaohaijun avatar Jan 07 '16 13:01 qiaohaijun

you mean of mxnet? I did: git clone --recursive https://github.com/dmlc/mxnet

Lopezurrutia avatar Jan 07 '16 13:01 Lopezurrutia

git submodule update

qiaohaijun avatar Jan 07 '16 14:01 qiaohaijun

yes, everything is up to date, I downloaded mxnet a couple of hours ago and git submodule update does not update anything

Lopezurrutia avatar Jan 07 '16 14:01 Lopezurrutia

stupid me.. I had set USE_CUDNN = 1 and USE_CUDA_PATH = /usr/local/cuda but had

whether use CUDA during compile

USE_CUDA = 0

set to 1 and installs ok. sorry

Lopezurrutia avatar Jan 07 '16 21:01 Lopezurrutia