Professional Documents
Culture Documents
Cudnn Install Guide
Cudnn Install Guide
Ubuntu Community Ask! Developer Design Hardware Insights Juju Shop More
sign up log in tour help
_
Ask Ubuntu is a question and answer Here's how it works:
site for Ubuntu users and developers.
Join them; it only takes a minute:
Sign up
Anybody can ask Anybody can The best answers are voted
a question answer up and rise to the top
For TensorFlow I would like to install cuda and CuDNN. How do I do that on Ubuntu
16.04?
Warning: if you're trying to run tensorow and need cudnn, make sure to install 5.1 and not 6.0 for now.
wordsforthewise Apr 18 at 5:50
4 Answers
Step 0: Install cuda from the standard repositories. (See How can I install CUDA on Ubuntu
16.04?)
Step 1: Register an nvidia developer account and download cudnn here (about 80 MB)
Step 2: Check where your cuda installation is. For the installation from the repository it is
/usr/lib/... and /usr/include . Otherwise, it will be /urs/local/cuda/ . You can check it
with which nvcc or ldconfig -p | grep cuda
$ cd folder/extracted/contents
$ sudo cp -P include/cudnn.h /usr/include
$ sudo cp -P lib64/libcudnn* /usr/lib/x86_64-linux-gnu/
$ sudo chmod a+r /usr/lib/x86_64-linux-gnu/libcudnn*
Update from here: "Download cuDNN v4 (v5 is currently a release candidate and is only supported when installing
TensorFlow from sources)." nobar Sep 4 '16 at 23:06
16 For Tensorow to nd everything, I had to copy include/cudnn.h and the libraries in lib64/ to
/usr/local/cuda-8.0/include and /usr/local/cuda-8.0/lib64 (using CUDA 8.0, Ubuntu 14.04,
Tensorow 0.12.0rc0) - maybe this is helpful for somebody. David Stutz Dec 9 '16 at 12:16
1. Register on NVidia's website. It may take a day, or two before they'll get your account
approved. At least that used to be the case back when I registered.
2. Download and Install latest CUDA from NVidia, or the latest version that ts the software
you'll be working with, if any, in this case your version of TFlow.
1 of 2 25.04.2017 20:11
nvidia - How can I install CuDNN on Ubuntu 16... https://askubuntu.com/questions/767269/how-ca...
Also, you can download the deb packages for Debian based distributions.
From the NVIDIA web page, for the developer prole are available the next les :
I tested this, over my machine with Debian (Stretch) and TensorFlow is working !
3 Please note that as of now (July 2016) cuDNN v5.1 won't work with TensorFlow unless you compiled it from
source, see tensorow.org/versions/r0.9/get_started/os_setup.html mastazi Jul 12 '16 at 4:48
the answer is correct but for cuDNN 5.1 some names have been changed. So if you use this
version after extracting the cuDNN le you will nd two folder: lib and include. change the
name of *.h le in include folder to cudnn.h and then follow https://askubuntu.com/a/767270
/641589. this change is needed if you wanted to use cuDNN for Cae!
Please edit your answer and add the reference, 'the instruction above'. sudodus Jan 12 at 18:42
2 of 2 25.04.2017 20:11