RTX2060 —— Anaconda + CUDA 10.0 +Cudnn 7.3 + Tensorflow-GPU + Keras 安装(二)CUDA10.0&cuDNN 7.3&VS2015

1. 安装CUDA

nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2018 NVIDIA Corporation
Built on Sat_Aug_25_21:08:04_Central_Daylight_Time_2018
Cuda compilation tools, release 10.0, V10.0.130

则表示安装成功。

2. 配置CUDA环境变量

在这里插入图片描述

3*. 配置VS2015(VS应当是在CUDA之前安装好的。如果只是用Python这一步暂时不需要)

  • 配置VS
    打开Visual Studio,选择项目–属性
    在这里插入图片描述选择VC++目录–包含目录
    添加如下
    在这里插入图片描述
    链接器–输入添加
cublas.lib
cuda.lib
cudadevrt.lib
cudart.lib
cudart_static.lib
nvcuvid.lib
OpenCL.lib
  • 运行CUDA samples
    找到如下路径
C:\ProgramData\NVIDIA Corporation\CUDA Samples\v10.0

随便运行该文件夹下任一子文件夹的任意工程,如果成功运行则说明VS+CUDA配置成功
例如,运行3_Imaging–boxFilter
可以看到图像
在这里插入图片描述

4. 安装cuDNN

  • 下载
    在官网https://developer.nvidia.com/rdp/cudnn-archive选择与CUDA版本相匹配的cuDNN,在这里选:在这里插入图片描述这里需要注册一下,不过需要注册,界面比较卡,我稍后把文件分享到网盘。我选的是cuDNN v7.6.0 for CUDA 10.0。
  • 拷贝文件
    下载好之后解压,将cuDNN下的
<cuDNN安装路径>\cuda\bin\cudnn64_7.dll
<cuDNN安装路径>\cuda\include\cudnn.h
<cuDNN安装路径>\cuda\lib\x64\cudnn.lib

分别拷贝到CUDA的安装路径下:

C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0\bin
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0\include
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0\lib\x64

5. 验证CUDA和cuDNN是否配置成功

  • 检验基本信息
    验证CUDA是否安装成功,打开cmd
nvcc -V

得到输出

nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2018 NVIDIA Corporation
Built on Sat_Aug_25_21:08:04_Central_Daylight_Time_2018
Cuda compilation tools, release 10.0, V10.0.130
  • 其他检验
    cd到安装目录下的extras\demo_suite
cd C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0\extras\demo_suite

执行

bandWidthTest.exe

输出如下

C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0\extras\demo_suite>bandWidthTest.exe
[CUDA Bandwidth Test] - Starting...
Running on...

 Device 0: GeForce RTX 2060
 Quick Mode

 Host to Device Bandwidth, 1 Device(s)
 PINNED Memory Transfers
   Transfer Size (Bytes)        Bandwidth(MB/s)
   33554432                     12522.0

 Device to Host Bandwidth, 1 Device(s)
 PINNED Memory Transfers
   Transfer Size (Bytes)        Bandwidth(MB/s)
   33554432                     12691.0

 Device to Device Bandwidth, 1 Device(s)
 PINNED Memory Transfers
   Transfer Size (Bytes)        Bandwidth(MB/s)
   33554432                     270038.6

Result = PASS

NOTE: The CUDA Samples are not meant for performance measurements. Results may vary when GPU Boost is enabled.

执行

deviceQuery.exe

输出如下

C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0\extras\demo_suite>deviceQuery.exe
deviceQuery.exe Starting...

 CUDA Device Query (Runtime API) version (CUDART static linking)

Detected 1 CUDA Capable device(s)

Device 0: "GeForce RTX 2060"
  CUDA Driver Version / Runtime Version          10.0 / 10.0
  CUDA Capability Major/Minor version number:    7.5
  Total amount of global memory:                 6144 MBytes (6442450944 bytes)
  (30) Multiprocessors, ( 64) CUDA Cores/MP:     1920 CUDA Cores
  GPU Max Clock rate:                            1200 MHz (1.20 GHz)
  Memory Clock rate:                             7001 Mhz
  Memory Bus Width:                              192-bit
  L2 Cache Size:                                 3145728 bytes
  Maximum Texture Dimension Size (x,y,z)         1D=(131072), 2D=(131072, 65536), 3D=(16384, 16384, 16384)
  Maximum Layered 1D Texture Size, (num) layers  1D=(32768), 2048 layers
  Maximum Layered 2D Texture Size, (num) layers  2D=(32768, 32768), 2048 layers
  Total amount of constant memory:               65536 bytes
  Total amount of shared memory per block:       49152 bytes
  Total number of registers available per block: 65536
  Warp size:                                     32
  Maximum number of threads per multiprocessor:  1024
  Maximum number of threads per block:           1024
  Max dimension size of a thread block (x,y,z): (1024, 1024, 64)
  Max dimension size of a grid size    (x,y,z): (2147483647, 65535, 65535)
  Maximum memory pitch:                          2147483647 bytes
  Texture alignment:                             512 bytes
  Concurrent copy and kernel execution:          Yes with 3 copy engine(s)
  Run time limit on kernels:                     Yes
  Integrated GPU sharing Host Memory:            No
  Support host page-locked memory mapping:       Yes
  Alignment requirement for Surfaces:            Yes
  Device has ECC support:                        Disabled
  CUDA Device Driver Mode (TCC or WDDM):         WDDM (Windows Display Driver Model)
  Device supports Unified Addressing (UVA):      Yes
  Device supports Compute Preemption:            No
  Supports Cooperative Kernel Launch:            No
  Supports MultiDevice Co-op Kernel Launch:      No
  Device PCI Domain ID / Bus ID / location ID:   0 / 1 / 0
  Compute Mode:
     < Default (multiple host threads can use ::cudaSetDevice() with device simultaneously) >

deviceQuery, CUDA Driver = CUDART, CUDA Driver Version = 10.0, CUDA Runtime Version = 10.0, NumDevs = 1, Device0 = GeForce RTX 2060
Result = PASS

都返回Result = PASS,说明安装成功。

参考链接:
https://blog.csdn.net/qilixuening/article/details/77503631

我的相关文章

RTX2060 —— Anaconda + CUDA 10.0 +Cudnn 7.3 + Tensorflow-GPU + Keras 安装(一)Anaconda3
RTX2060 —— Anaconda + CUDA 10.0 +Cudnn 7.3 + Tensorflow-GPU + Keras 安装(二)CUDA10.0 & cuDNN 7.3
RTX2060 —— Anaconda + CUDA 10.0 +Cudnn 7.3 + Tensorflow-GPU + Keras 安装(三)Tensorflow + Keras
RTX2060 —— Anaconda+CUDA+Cudnn+Pytorch安装(四)Pytorch安装

  • 1
    点赞
  • 9
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值