-- Mike Gore - 2020-08-05

Windows 10 CUDA cuDNN and Tensorflow GPU install


  • These are instruction for installing Python 3.78, CUDA, cuDNN and tensorflow on Windows 10 with and without AVX support
  • The first part is for Administrative setup and installs the NVIDIA support packages CUDA 10.1 and cuDNN 7.6.5
    • These version are required for TensorFlow version 2.0 thru 2.2
  • The second part of for end users and outline how they can create a virtual environment and install tensorflow

Administrative instructions

Installing of Python 3.78, CUDA 10.1 and cuDNN 7.6.5 setup

  • Assumptions - you are doing this on a clean system that has not had these packages installed before

Hardware Requirements

  • nVidia GPU card

Software Requirements

CUDA 10.1 install

cuDNN 7.6.5 install

Windows System Environment Variables

  • Open Windows search: view advanced system setting - or open Control Panel -> System
  • Select Advanced Tab -> Environment Variables -> System Variables -> Path -> Edit
  • Use the New button to add each line - you can also click on and edit lines if you need to change settings
  • Make sure you have the following lines added
          C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1\bin
          C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1\extras\CUPTI\lib64
          C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1\include

Install python 3.78

End user instructions for installing of TensorFlow GPU in a virtual environment

  • You MUST always use a Python3 virtual environment otherwise you risk damaging the system wide Python installation
  • Note: this installation can be done as a normal user without Administrator perms
  • Open a Command Prompt -> Windows Search -> cmd
  • Create a virtual environment called venv in your current directory
    • python3 -m venv --system-site-packages .\venv
    • .\venv\Scripts\activate
    • pip install --upgrade pip
    • Please remove \Users\userid\AppData\Local\Temp\pip - replace userid with your own userid pip install --upgrade pip

Check if your system has AVX instruction support

On systems WITHOUT AVX support

On newer systems with AVX support

  • pip install tensorflow-gpu==2.2


  • python -c "import tensorflow as tf;print(tf.reduce_sum(tf.random.normal([1000, 1000])))"
Edit | Attach | Watch | Print version | History: r4 < r3 < r2 < r1 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r4 - 2020-08-26 - MikeGore
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2020 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback