How to get the cuda version?

check cuda version windows 10
check cudnn version
check cuda version python
how to check cuda version anaconda
check cuda version pytorch
update cuda version
tensorflow cuda version
pytorch cuda version

Is there any quick command or script to check for the version of CUDA installed?

I found the manual of 4.0 under the installation directory but I'm not sure whether it is of the actual installed version or not.

As Jared mentions in a comment, from the command line:

nvcc --version

(or /usr/local/cuda/bin/nvcc --version) gives the CUDA compiler version (which matches the toolkit version).

From application code, you can query the runtime API version with


or the driver API version with


As Daniel points out, deviceQuery is an SDK sample app that queries the above, along with device capabilities.

As others note, you can also check the contents of the version.txt using (e.g., on Mac or Linux)

cat /usr/local/cuda/version.txt

However, if there is another version of the CUDA toolkit installed other than the one symlinked from /usr/local/cuda, this may report an inaccurate version if another version is earlier in your PATH than the above, so use with caution.

How to get the cuda version?, As Jared mentions in a comment, from the command line: nvcc --version. (or /usr/​local/cuda/bin/nvcc --version ) gives the CUDA compiler  Get Started The above options provide the complete CUDA Toolkit for application development. Runtime components for deploying CUDA-based applications are available in ready-to-use containers from NVIDIA GPU Cloud.

On Ubuntu Cuda V8:

$ cat /usr/local/cuda/version.txt

Installing the CUDA SDK Tool Chain - Rogue Wave, the system information for your GPU. You can simply do that by right clicking on the desktop and select the NVIDIA Control Panel and open it. In that go to help tab and select System Information. I installed cuda 8.0 in my ubuntu 16.04 machine and checked the cuda version using the command "nvcc --version". it shows version as 7.5!!!.How Can I be sure that it is accurate? Are there other commands that I can also use to verify my result?

If you run


You should find the CUDA Version on the top right corner of the comand's output. At least I found that output for CUDA version 10.0 e.g.,

How to verify CuDNN installation?, For cuda-8.0 on Ubuntu16.04, you should be able to read $ cat /usr/local/cuda/​version.txt CUDA Version 8.0.44. I agree with Robert Crovella,  (or /usr/local/cuda/bin/nvcc --version) gives the CUDA compiler version (which matches the toolkit version). From application code, you can query the runtime API version with or the driver API version with As Daniel points out, deviceQuery is an SDK sample app that queries the above, along with device capabilities.

On Ubuntu :


$ cat /usr/local/cuda/version.txt or $ cat /usr/local/cuda-8.0/version.txt

Sometimes the folder is named "Cuda-version".

If none of above works, try going to $ /usr/local/ And find the correct name of your Cuda folder.

Output should be similar to: CUDA Version 8.0.61

CUDA Toolkit on Windows 10 - Analytics Vidhya, Identify the CUDA location and version with NVCC​​ You should see something like /usr/bin/nvcc. If that appears, your NVCC is installed in the standard directory. If you have installed the CUDA toolkit but which nvcc returns no results, you might need to add the directory to your path. If you use the $(CUDA_PATH) environment variable to target a version of the CUDA Toolkit for building, and you perform an installation or uninstallation of any version of the CUDA Toolkit, you should validate that the $(CUDA_PATH) environment variable points to the correct installation directory of the CUDA Toolkit for your purposes.

For CUDA version:

nvcc --version

For cuDNN version:

For Linux:

Use following to find path for cuDNN:

$ whereis cuda
cuda: /usr/local/cuda

Then use this to get version from header file,

$ cat /usr/local/cuda/include/cudnn.h | grep CUDNN_MAJOR -A 2

For Windows,

Use following to find path for cuDNN:

C:\>where cudnn*
C:\Program Files\cuDNN7\cuda\bin\cudnn64_7.dll

Then use this to dump version from header file,

type "%PROGRAMFILES%\cuDNN7\cuda\include\cudnn.h" | findstr CUDNN_MAJOR

How to find cuda version in ubuntu?, Software Requirements and Linux Command Line Conventions. Category, Requirements, Conventions or Software Version Used. System  The driver has a CUDA driver version associated with it (which can be queried with nvidia-smi, for example). The CUDA runtime also has a CUDA runtime version associated with it. The two will not necessarily match in all cases.

How to check which CUDA version is installed on Linux, Previous releases of the CUDA Toolkit, GPU Computing SDK, documentation and Please select the release you want from the list below, and be sure to check  Multiple CUDA versions on machine nvcc -V confusion. I guess I'm confused since the /cuda/version.txt file says it is on cuda-8.0, but when I type: $ nvcc -V

How to check CUDA version on Ubuntu 20.04 Focal Fossa Linux , Watch this short video about how to install the CUDA Toolkit. Learn CUDA through getting started resources including videos, webinars, code  Unsubscribe from NVIDIA Developer? Want to watch this again later? Sign in to add this video to a playlist. Need to report the video? Sign in to report inappropriate content. Sign in to make your

CUDA Toolkit Archive, If the script above doesn't work, try this:. “[NV] How to check CUDA and cuDNN version” is published by CR-Ko.

  • $ nvcc --version is usually the version number of interest.
  • See also: How to verify CuDNN installation?
  • Which OS is this question targeting?
  • do you think about the installed and supported runtime or the installed SDK?
  • @JaredHoberock nvcc --version produce The program 'nvcc' is currently not installed. You can install it by typing: sudo apt install nvidia-cuda-toolkit however nvidia-smi contain CUDA Version: 10.1.
  • nvcc --version should work from the Windows command prompt assuming nvcc is in your path.
  • in Ubuntu you may need to install nvidia-cuda-tools to make this command to work. just type sudo apt install nvidia-cuda-toolkit
  • @OlegKokorin, if you're getting this advice from terminal, it seems you haven't CUDA installed.
  • If you can't find nvcc, it should be in /usr/local/cuda/bin/.
  • Upvote for cat /usr/local/cuda/version.txt. Popular method with nvcc --version works if you have nvidia-toolkit installed, however, if you have only cuda runtime, nvcc might not exist. It might be the case @RutgerHofste pointed out. E.g. (Tensorflow setup instructions do not install nvcc)
  • this is more versatile than harrism's answer since it doesn't require installing nvcc (which requires admin privileges)
  • Works on AWS Linux Deep Learning AMI
  • using this I get "CUDA Version 8.0.61" but nvcc --version gives me "Cuda compilation tools, release 7.5, V7.5.17" do you know the reason for the missmatch?
  • Upvoted for being the more correct answer, my CUDA version is 9.0.176 and was nowhere mentioned in nvcc -V