mxnet erro de instalação padrão

1

Eu quero configurar o arquivo config.mk para usar o cuda . Eu modifiquei estas opções:



    USE_CUDA = 1
    ADD_LDFLAGS = /usr/local/cuda-8.0/lib64
    ADD_CFLAGS = /usr/local/cuda-8.0/lib64
    USE_CUDA_PATH = /usr/local/cuda 
    USE_CUDNN = 1
    USE_NVRTC = 1

enquanto corro make -j8 , recebi os erros abaixo:



    cd /home/wanger/MXNet/mxnet/dmlc-core; make libdmlc.a USE_SSE=1 config=/home/wanger/MXNet/mxnet/config.mk; cd /home/wanger/MXNet/mxnet
    /usr/local/cuda /bin/nvcc -std=c++11 -Xcompiler -D_FORCE_INLINES -g -O3 -ccbin g++  -Xcompiler "-DMSHADOW_FORCE_STREAM -Wall -O3 -I/home/wanger/MXNet/mxnet/mshadow/ -I/home/wanger/MXNet/mxnet/dmlc-core/include -fPIC -Iinclude -funroll-loops -Wno-unused-parameter -Wno-unknown-pragmas -msse3 -I/usr/local/cuda /include -DMSHADOW_USE_CBLAS=1 -DMSHADOW_USE_MKL=0 -DMSHADOW_RABIT_PS=0 -DMSHADOW_DIST_PS=0 -DMSDHADOW_USE_PASCAL=0 -DMXNET_USE_OPENCV=1 'pkg-config --cflags opencv' -fopenmp -DMSHADOW_USE_CUDNN=1 /usr/local/cuda-8.0/lib64 -DMXNET_USE_NVRTC=1" -M -MT build/src/ndarray/ndarray_function_gpu.o src/ndarray/ndarray_function.cu >build/src/ndarray/ndarray_function_gpu.d
    make[1]: Entering directory '/home/wanger/MXNet/mxnet/dmlc-core'
    /usr/local/cuda /bin/nvcc -std=c++11 -Xcompiler -D_FORCE_INLINES -g -O3 -ccbin g++  -Xcompiler "-DMSHADOW_FORCE_STREAM -Wall -O3 -I/home/wanger/MXNet/mxnet/mshadow/ -I/home/wanger/MXNet/mxnet/dmlc-core/include -fPIC -Iinclude -funroll-loops -Wno-unused-parameter -Wno-unknown-pragmas -msse3 -I/usr/local/cuda /include -DMSHADOW_USE_CBLAS=1 -DMSHADOW_USE_MKL=0 -DMSHADOW_RABIT_PS=0 -DMSHADOW_DIST_PS=0 -DMSDHADOW_USE_PASCAL=0 -DMXNET_USE_OPENCV=1 'pkg-config --cflags opencv' -fopenmp -DMSHADOW_USE_CUDNN=1 /usr/local/cuda-8.0/lib64 -DMXNET_USE_NVRTC=1" -M -MT build/src/optimizer/sgd_gpu.o src/optimizer/sgd.cu >build/src/optimizer/sgd_gpu.d
    /usr/local/cuda /bin/nvcc -std=c++11 -Xcompiler -D_FORCE_INLINES -g -O3 -ccbin g++  -Xcompiler "-DMSHADOW_FORCE_STREAM -Wall -O3 -I/home/wanger/MXNet/mxnet/mshadow/ -I/home/wanger/MXNet/mxnet/dmlc-core/include -fPIC -Iinclude -funroll-loops -Wno-unused-parameter -Wno-unknown-pragmas -msse3 -I/usr/local/cuda /include -DMSHADOW_USE_CBLAS=1 -DMSHADOW_USE_MKL=0 -DMSHADOW_RABIT_PS=0 -DMSHADOW_DIST_PS=0 -DMSDHADOW_USE_PASCAL=0 -DMXNET_USE_OPENCV=1 'pkg-config --cflags opencv' -fopenmp -DMSHADOW_USE_CUDNN=1 /usr/local/cuda-8.0/lib64 -DMXNET_USE_NVRTC=1" -M -MT build/src/operator/convolution_gpu.o src/operator/convolution.cu >build/src/operator/convolution_gpu.d
    /usr/local/cuda /bin/nvcc -std=c++11 -Xcompiler -D_FORCE_INLINES -g -O3 -ccbin g++  -Xcompiler "-DMSHADOW_FORCE_STREAM -Wall -O3 -I/home/wanger/MXNet/mxnet/mshadow/ -I/home/wanger/MXNet/mxnet/dmlc-core/include -fPIC -Iinclude -funroll-loops -Wno-unused-parameter -Wno-unknown-pragmas -msse3 -I/usr/local/cuda /include -DMSHADOW_USE_CBLAS=1 -DMSHADOW_USE_MKL=0 -DMSHADOW_RABIT_PS=0 -DMSHADOW_DIST_PS=0 -DMSDHADOW_USE_PASCAL=0 -DMXNET_USE_OPENCV=1 'pkg-config --cflags opencv' -fopenmp -DMSHADOW_USE_CUDNN=1 /usr/local/cuda-8.0/lib64 -DMXNET_USE_NVRTC=1" -M -MT build/src/operator/svm_output_gpu.o src/operator/svm_output.cu >build/src/operator/svm_output_gpu.d
    /usr/local/cuda /bin/nvcc -std=c++11 -Xcompiler -D_FORCE_INLINES -g -O3 -ccbin g++  -Xcompiler "-DMSHADOW_FORCE_STREAM -Wall -O3 -I/home/wanger/MXNet/mxnet/mshadow/ -I/home/wanger/MXNet/mxnet/dmlc-core/include -fPIC -Iinclude -funroll-loops -Wno-unused-parameter -Wno-unknown-pragmas -msse3 -I/usr/local/cuda /include -DMSHADOW_USE_CBLAS=1 -DMSHADOW_USE_MKL=0 -DMSHADOW_RABIT_PS=0 -DMSHADOW_DIST_PS=0 -DMSDHADOW_USE_PASCAL=0 -DMXNET_USE_OPENCV=1 'pkg-config --cflags opencv' -fopenmp -DMSHADOW_USE_CUDNN=1 /usr/local/cuda-8.0/lib64 -DMXNET_USE_NVRTC=1" -M -MT build/src/operator/leaky_relu_gpu.o src/operator/leaky_relu.cu >build/src/operator/leaky_relu_gpu.d
    /usr/local/cuda /bin/nvcc -std=c++11 -Xcompiler -D_FORCE_INLINES -g -O3 -ccbin g++  -Xcompiler "-DMSHADOW_FORCE_STREAM -Wall -O3 -I/home/wanger/MXNet/mxnet/mshadow/ -I/home/wanger/MXNet/mxnet/dmlc-core/include -fPIC -Iinclude -funroll-loops -Wno-unused-parameter -Wno-unknown-pragmas -msse3 -I/usr/local/cuda /include -DMSHADOW_USE_CBLAS=1 -DMSHADOW_USE_MKL=0 -DMSHADOW_RABIT_PS=0 -DMSHADOW_DIST_PS=0 -DMSDHADOW_USE_PASCAL=0 -DMXNET_USE_OPENCV=1 'pkg-config --cflags opencv' -fopenmp -DMSHADOW_USE_CUDNN=1 /usr/local/cuda-8.0/lib64 -DMXNET_USE_NVRTC=1" -M -MT build/src/operator/lrn_gpu.o src/operator/lrn.cu >build/src/operator/lrn_gpu.d
    /usr/local/cuda /bin/nvcc -std=c++11 -Xcompiler -D_FORCE_INLINES -g -O3 -ccbin g++  -Xcompiler "-DMSHADOW_FORCE_STREAM -Wall -O3 -I/home/wanger/MXNet/mxnet/mshadow/ -I/home/wanger/MXNet/mxnet/dmlc-core/include -fPIC -Iinclude -funroll-loops -Wno-unused-parameter -Wno-unknown-pragmas -msse3 -I/usr/local/cuda /include -DMSHADOW_USE_CBLAS=1 -DMSHADOW_USE_MKL=0 -DMSHADOW_RABIT_PS=0 -DMSHADOW_DIST_PS=0 -DMSDHADOW_USE_PASCAL=0 -DMXNET_USE_OPENCV=1 'pkg-config --cflags opencv' -fopenmp -DMSHADOW_USE_CUDNN=1 /usr/local/cuda-8.0/lib64 -DMXNET_USE_NVRTC=1" -M -MT build/src/operator/fully_connected_gpu.o src/operator/fully_connected.cu >build/src/operator/fully_connected_gpu.d
    /bin/sh: 1: /usr/local/cuda: Permission denied
    Makefile:184: recipe for target 'build/src/ndarray/ndarray_function_gpu.o' failed
    make: *** [build/src/ndarray/ndarray_function_gpu.o] Error 126
    make: *** Waiting for unfinished jobs....
    /bin/sh: 1: /usr/local/cuda: Permission denied
    /bin/sh: 1: /usr/local/cuda: Permission denied
    Makefile:184: recipe for target 'build/src/optimizer/sgd_gpu.o' failed
    make: *** [build/src/optimizer/sgd_gpu.o] Error 126
    Makefile:184: recipe for target 'build/src/operator/convolution_gpu.o' failed
    make: *** [build/src/operator/convolution_gpu.o] Error 126
    /bin/sh: 1: /usr/local/cuda: Permission denied
    /bin/sh: 1: /usr/local/cuda: Permission denied
    Makefile:184: recipe for target 'build/src/operator/svm_output_gpu.o' failed
    make: *** [build/src/operator/svm_output_gpu.o] Error 126
    Makefile:184: recipe for target 'build/src/operator/lrn_gpu.o' failed
    make: *** [build/src/operator/lrn_gpu.o] Error 126
    /bin/sh: 1: /usr/local/cuda: Permission denied
    Makefile:184: recipe for target 'build/src/operator/fully_connected_gpu.o' failed
    make: *** [build/src/operator/fully_connected_gpu.o] Error 126
    make[1]: 'libdmlc.a' is up to date.
    make[1]: Leaving directory '/home/wanger/MXNet/mxnet/dmlc-core'
    /bin/sh: 1: /usr/local/cuda: Permission denied
    Makefile:184: recipe for target 'build/src/operator/leaky_relu_gpu.o' failed
    make: *** [build/src/operator/leaky_relu_gpu.o] Error 126

Obrigado pela sua ajuda!

    
por hychn 18.11.2016 / 08:41

1 resposta

0

A linha

/bin/sh: 1: /usr/local/cuda: Permission denied

Sugere que seu problema está nas permissões configuradas incorretamente para o diretório /usr/local/cuda . Você parece tentar executá-lo, como se fosse um arquivo de comando. O que você mais deseja é executar /usr/local/cuda/bin/nvcc .

Edite seu makefile para que o comando CUDA leia /usr/local/cuda/bin/nvcc (note que não há espaço entre "cuda" e "bin") e tente novamente.

    
por Dmitry Grigoryev 18.11.2016 / 11:19