| 
                           
- 可以根据自身的环境选择相应版本进行下载,这个有身份验证只能浏览器下载然后再上传到云主机中。  
 -   
 - 安装:  
 -   
 - #rpm -ivh libcudnn7-7.4.2.24-1.cuda10.0.x86_64.rpm libcudnn7-devel-7.4.2.24-1.cuda10.0.x86_64.rpm libcudnn7-doc-7.4.2.24-1.cuda10.0.x86_64.rpm  
 -   
 - 准备中... ################################# [100%]  
 -   
 - 正在升级/安装...  
 -   
 - 1:libcudnn7-7.4.2.24-1.cuda10.0 ################################# [ 33%]  
 -   
 - 2:libcudnn7-devel-7.4.2.24-1.cuda10################################# [ 67%]  
 -   
 - 3:libcudnn7-doc-7.4.2.24-1.cuda10.0################################# [100%]  
 -   
 - 验证cuDNN:  
 -   
 - # cp -r /usr/src/cudnn_samples_v7/ $HOME  
 -   
 - # cd $HOME/cudnn_samples_v7/mnistCUDNN  
 -   
 - # make clean && make  
 -   
 - rm -rf *o  
 -   
 - rm -rf mnistCUDNN  
 -   
 - /usr/local/cuda/bin/nvcc -ccbin g++ -I/usr/local/cuda/include -IFreeImage/include -m64 -gencode arch=compute_30,code=sm_30 -gencode arch=compute_35,code=sm_35 -gencode arch=compute_50,code=sm_50 -gencode arch=compute_53,code=sm_53 -gencode arch=compute_53,code=compute_53 -o fp16_dev.o -c fp16_dev.cu  
 -   
 - g++ -I/usr/local/cuda/include -IFreeImage/include -o fp16_emu.o -c fp16_emu.cpp  
 -   
 - g++ -I/usr/local/cuda/include -IFreeImage/include -o mnistCUDNN.o -c mnistCUDNN.cpp  
 -   
 - /usr/local/cuda/bin/nvcc -ccbin g++ -m64 -gencode arch=compute_30,code=sm_30 -gencode arch=compute_35,code=sm_35 -gencode arch=compute_50,code=sm_50 -gencode arch=compute_53,code=sm_53 -gencode arch=compute_53,code=compute_53 -o mnistCUDNN fp16_dev.o fp16_emu.o mnistCUDNN.o -I/usr/local/cuda/include -IFreeImage/include -LFreeImage/lib/linux/x86_64 -LFreeImage/lib/linux -lcudart -lcublas -lcudnn -lfreeimage -lstdc++ -lm  
 -   
 - # ./mnistCUDNN  
 -   
 - cudnnGetVersion() : 7402 , CUDNN_VERSION from cudnn.h : 7402 (7.4.2)  
 -   
 - Host compiler version : GCC 4.8.5  
 -   
 - There are 1 CUDA capable devices on your machine :  
 -   
 - device 0 : sms 8 Capabilities 6.1, SmClock 1480.5 Mhz, MemSize (Mb) 5059, MemClock 3504.0 Mhz, Ecc=0, boardGroupID=0  
 -   
 - Using device 0  
 -   
 - Testing single precision  
 -   
 - Loading image data/one_28x28.pgm  
 -   
 - Performing forward propagation ...  
 -   
 - Testing cudnnGetConvolutionForwardAlgorithm ...  
 -   
 - Fastest algorithm is Algo 1  
 -   
 - Testing cudnnFindConvolutionForwardAlgorithm ...  
 -   
 - ^^^^ CUDNN_STATUS_SUCCESS for Algo 0: 0.036864 time requiring 0 memory  
 -   
 - ^^^^ CUDNN_STATUS_SUCCESS for Algo 1: 0.044032 time requiring 3464 memory  
 -   
 - ^^^^ CUDNN_STATUS_SUCCESS for Algo 2: 0.053248 time requiring 57600 memory  
 -   
 - ^^^^ CUDNN_STATUS_SUCCESS for Algo 4: 0.116544 time requiring 207360 memory  
 -   
 - ^^^^ CUDNN_STATUS_SUCCESS for Algo 7: 0.181248 time requiring 2057744 memory  
 -   
 - Resulting weights from Softmax:  
 -   
 - 0.0000000 0.9999399 0.0000000 0.0000000 0.0000561 0.0000000 0.0000012 0.0000017 0.0000010 0.0000000  
 -   
 - Loading image data/three_28x28.pgm  
 -   
 - Performing forward propagation ...  
 -   
 - Resulting weights from Softmax:  
 -   
 - 0.0000000 0.0000000 0.0000000 0.9999288 0.0000000 0.0000711 0.0000000 0.0000000 0.0000000 0.0000000  
 -   
 - Loading image data/five_28x28.pgm  
 -   
 - Performing forward propagation ...  
 -   
 - Resulting weights from Softmax:  
 -   
 - 0.0000000 0.0000008 0.0000000 0.0000002 0.0000000 0.9999820 0.0000154 0.0000000 0.0000012 0.0000006  
 -   
 - Result of classification: 1 3 5  
 -   
 - Test passed!  
 -   
 - Testing half precision (math in single precision)  
 -   
 - Loading image data/one_28x28.pgm  
 -   
 - Performing forward propagation ...  
 -   
 - Testing cudnnGetConvolutionForwardAlgorithm ...  
 -   
 - Fastest algorithm is Algo 1  
 -   
 - Testing cudnnFindConvolutionForwardAlgorithm ...  
 -   
 - ^^^^ CUDNN_STATUS_SUCCESS for Algo 0: 0.032896 time requiring 0 memory  
 -   
 - ^^^^ CUDNN_STATUS_SUCCESS for Algo 1: 0.036448 time requiring 3464 memory  
 -   
 - ^^^^ CUDNN_STATUS_SUCCESS for Algo 2: 0.044000 time requiring 28800 memory  
 -   
 - ^^^^ CUDNN_STATUS_SUCCESS for Algo 4: 0.115488 time requiring 207360 memory  
 -   
 - ^^^^ CUDNN_STATUS_SUCCESS for Algo 7: 0.180224 time requiring 2057744 memory  
 -   
 - Resulting weights from Softmax:  
 -   
 - 0.0000001 1.0000000 0.0000001 0.0000000 0.0000563 0.0000001 0.0000012 0.0000017 0.0000010 0.0000001  
 -   
 - Loading image data/three_28x28.pgm  
 -   
 - Performing forward propagation ...  
 -   
 - Resulting weights from Softmax:  
 -   
 - 0.0000000 0.0000000 0.0000000 1.0000000 0.0000000 0.0000714 0.0000000 0.0000000 0.0000000 0.0000000  
 -   
 - Loading image data/five_28x28.pgm  
 -   
 - Performing forward propagation ...  
 -   
 - Resulting weights from Softmax:  
 -   
 - 0.0000000 0.0000008 0.0000000 0.0000002 0.0000000 1.0000000 0.0000154 0.0000000 0.0000012 0.0000006  
 -   
 - Result of classification: 1 3 5  
 -   
 - Test passed!  
 -   
 - Test passed!且测试过程中无报错,表示测试通过!  
 
  
3.4安装 TensorFlow
- # pip3 install --upgrade setuptools==30.1.0 
 -  
 - # pip3 install tf-nightly-gpu 
 -  
 - 验证测试: 
 -  
 - 在 Python 交互式 shell 中输入以下几行简短的程序代码: 
 -  
 - # python  
 - import tensorflow as tf  
 - hello = tf.constant('Hello, TensorFlow!')  
 - sess = tf.Session()  
 - print(sess.run(hello)) 
 -  
 - 如果系统输出以下内容,就说明您可以开始编写 TensorFlow 程序了: 
 -  
 - Hello, TensorFlow! 
 -  
 - 同时使用nvidia-smi命令可以看到当前显卡的处理任务。 
                          (编辑:泰州站长网) 
【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! 
                    
  |