cuda11.6.2 + cudnn8.8.0 + tensorRT8.5.3 + pytorch1.13 installation records
1. cuda11.6.2 installation
1.1 cuda11.6.2 download
Since I downloaded cuda and updated it to version 12.0, I need to enter the previous version download interface.
Enter NVIDIA official website:
Find cuda Toolkit under paltforms and click to enter
After entering the cuda page, click Download New
Finally, click Archive of Previous CUDA Releases to enter the download page of the previous version.
Find the cuda11.6.2 version, click to enter,
and finally select your computer configuration to start downloading
1.2 cuda11.6.2 installation
Find the cuda 11.6.2 installation package downloaded in the first step, double-click
Wait for the extraction to complete
Enter the installation interface below, wait for the compatibility self-test to complete, click agree and continue
Choose Custom Installation and click Next
Select all, click Next
Select the default installation location, click Next
and wait for the installation to complete
1.3 cuda11.6.2 installation test
Check whether cuda is installed successfully in cmd: nvcc -V
2. cudnn8.8.0 installation
2.1 cudnn8.8.0 download
To download cudnn, you need to log in to your Nvidia account. If you don’t have an account, it takes a few minutes to register one. Find
cudnn on the home page, click to enter
and enter the cudnn page. After clicking Download cuDNN
, install the following operation.
2.2 cudnn8.8.0 installation
Right-click to decompress
and add the three decompressed files to the cuda installation path
The default installation is in C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.6
2.3 cudnn8.8.0 installation test
Open the terminal, enter the extras\demo_suite folder under the cuda installation path, and run deviceQuery.exe
If there is no problem with the installation, PASS will appear
After running bandwidthTest.exe
PASS , congratulations, the installation is complete, the installation is complete
3 tensorRT8.5.3 installation
3.1 tensorRT8.5.3 download
Find TensorRT on the homepage and click to
enter. After entering the TensorRT page, click Download now
and click TensorRT 8
to install the following steps to download.
3.2 tensorRT8.5.3 installation
Download the zip archive and unzip it.
TensorRT installation
Complete the following steps in any order:
Copy the contents of TensorRT-8.5.3.1\bin to C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.6\bin
Copy the include folder of TensorRT to the include folder of CUDA
Copy the lib file in the TensorRT-8.5.3.1\lib folder to the lib\x64 folder of CUDA, and the dll file to the bin folder of CUDA
3.3 python tensorRT8.5.3 installation test
Run cmd to decompress the file under the bin folder, trtexe.exe
appears as follows, the installation is successful
3.4 python tensorRT8.5.3 installation
Use pip install xxx.whl to install the TensorRT-8.5.3.1 folder, the following 4 files need to be installed,
as shown in the figure below:
use python to check whether the installation is successful
3.5 vs configure tensorRT8.5.3
Add the following path to the environment variable:
~\TensorRT-8.5.3.1\lib ~ indicates your storage path, remember to replace
vs environment settings
include directory
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.6\include
D:\Program Files\TensorRT-8.5.3.1\include
library directory
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.6\lib
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.6\lib\x64
D:\Program Files\TensorRT-8.5.3.1\lib
additional dependencies
nvinfer.lib
nvinfer_plugin.lib
nvonnxparser.lib
nvparsers.lib
cublas.lib
cublasLt.lib
cuda.lib
cudadevrt.lib
cudart.lib
cudart_static.lib
cudnn.lib
cudnn64_8.lib
cudnn_adv_infer.lib
cudnn_adv_infer64_8.lib
cudnn_adv_train.lib
cudnn_adv_train64_8.lib
cudnn_cnn_infer.lib
cudnn_cnn_infer64_8.lib
cudnn_cnn_train.lib
cudnn_cnn_train64_8.lib
cudnn_ops_infer.lib
cudnn_ops_infer64_8.lib
cudnn_ops_train.lib
cudnn_ops_train64_8.lib
cufft.lib
cufftw.lib
curand.lib
cusolver.lib
cusolverMg.lib
cusparse.lib
nppc.lib
nppial.lib
nppicc.lib
nppidei.lib
nppif.lib
nppig.lib
nppim.lib
nppist.lib
nppisu.lib
nppitc.lib
npps.lib
nvblas.lib
nvjpeg.lib
nvml.lib
nvrtc.lib
OpenCL.lib
4 pytorch1.13 installation
4.1 pytorch1.13 installation
Enter the pytorch official website, click install
to select as follows, and use the pip command to install in your own python environment
4.1 pytorch1.13 installation test
Open the terminal and switch to the pytorch installation environment. The detection procedure is as follows:
import torch
print(torch.__version__)
print(torch.cuda.is_available())