Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Which NVIDIA cuDNN release type for TensorFlow on Ubuntu 16.04 [closed]

According to TensorFlow 1.5 installation instructions for Ubuntu 16.04, you need to install cuDNN 7.0 but they don't mention exactly what should be installed:

cuDNN v7.0. For details, see NVIDIA's documentation. Ensure that you create the CUDA_HOME environment variable as described in the NVIDIA documentation.

After registering and going through all the hoops to download cuDNN there is are multiple options to download and install:

enter image description here

Obviously, for Ubuntu 16.04 it's either the Linux or Ubuntu Runtime or Developer but since I saw different mentions on the web of which file exactly should be installed I was wondering which is the best one to install, or if there's actually any difference?

like image 795
traveh Avatar asked Feb 14 '18 10:02

traveh


People also ask

What version of cuDNN should I install with TensorFlow?

If your cuDNN version is not on the list, then select “ Archived cuDNN Releases ” for more options. Remember to match both cuDNN and CUDA versions that are compatible for the TensorFlow you can/want to install. For my case, I chose cuDNN 7.6.3 with CUDA 10.0.

What version of cuDNN is available for Ubuntu?

cuDNN v7.1.3 Developer Library for Ubuntu16.04 (Deb) cuDNN v7.1.3 Code Samples and User Guide for Ubuntu16.04 (Deb)

How to install NVIDIA CUDA tookit and cuDNN on Ubuntu 18 LTS?

How I install compatible NVIDIA CUDA Tookit and cuDNN packages on Ubuntu 18.04 LTS, so that I can speed up Deep Learning with TensorFlow/Keras using GPU on my laptop. Step 1. Identify Compatibility Step 2. Install Video Driver Step 3. Install CUDA Toolkit Step 4. Install CUDNN Library Step 5. Update Environment Variables Step 6.

How to download and install NVIDIA cuDNN displays?

#2 go the NVIDIA cuDNN home page, click Download button, and then you need to complete the short survey and click Submit. #3 you should see a list of available download versions of cuDNN displays, you need to choose one based on CUDA version installed on your system.


1 Answers

First of all, I would encourage you to read the developer guide and the install guide. I'm going to try not to duplicate information contained there (such as specific install steps/command lines).

There are basically 2 install methods, which is true for a number of different kinds of NVIDIA software:

  • direct install (in this particular case via a .tgz compressed archive)
  • package manager install (i.e. using dpkg/apt/apt-get on Ubuntu)

There are various reasons including just personal preferences as to why you may prefer to use a tar archive (.tgz) and "unzip" everything, vs. letting apt or apt-get handle the install for you.

If you choose the .tgz method, everything you need is contained in the single .tgz archive "cuDNN v7.0.5 Library for Linux", and right off the bat we can make the observation that if you were using some Linux OS besides Ubuntu, this is the (only) way to go. This zip file contains the compiled libraries, the header files needed for development against the cuDNN API, and other things you will need to compile/link code against cuDNN.

If you choose the package manager method, this is currently only available for the listed OS's (Ubuntu 16.04 and Ubuntu 14.04 in this example). You have some independent choices:

  • Runtime Library - this is sufficient if the only thing you will be doing with cuDNN is running another binary that is already compiled to use that version of cuDNN on that version of Ubuntu. For example, if you have installed Tensorflow (TF) via a pip method, so you get precompiled binaries that are ready to go, and those precompiled binaries are set up for Ubuntu 16.04 and cuDNN 7.0.5, then you could just install the cuDNN runtime library (follow the steps in the install guide) and that would be sufficient to begin using your precompiled TF.

  • Developer Library - this will include header files and other things that are needed to compile and build codes against this particular version of the cuDNN API. So if you wanted to build or rebuild TF (for CUDA GPU usage), or you simply were working on your own API usage of cuDNN, you would want this option.

  • Code Samples and User Guide - In the .tgz install method, all of these components, including documentation and code samples, are included in the single .tgz archive. In the package manager method, even the Code samples and API user guide are broken out into a separate .deb install, so you don't have to download it if you don't need it (for example if you were just rebuilding TF against cuDNN 7.0.5, you would want the Developer Library but would not need the Code Samples or API User Guide).

UPDATE: With more recent versions of CUDNN, the .tgz file/method no longer contains the sample codes or documentation. The documentation (user guide and install guide) is here. The samples are only available in the .deb installer(s).

like image 96
Robert Crovella Avatar answered Sep 17 '22 14:09

Robert Crovella