GPU Acceleration Setup for Anaconda (Tensorflow)
- This assumes you have Anaconda already installed on your computer
Steps:
- Make sure your computer has a GPU
- Install CUDA onto your computer
- Install cuDNN onto your computer
- I. You can base which cuDNN version to download on which CUDA version you downloaded
- Check to make sure CUDA and cuDNN are installed
- Install Visual Studio
- Create a new evironment in Anaconda
- I. Open Anaconda and type: create --name tensorflow
- This creates a new virutal environment called tensorflow
- Access environment
- I. Type: conda activate tensorflow
- Install Python
- I. type conda install python='version'
- The pyton version you install on this environment depends on the tensorflow version you need
OR 6) Create a new environment with python altogether
- Type: conda create --name tensorflow python=3.8
- Then: conda activate tensorflow
- Last: conda install -c conda-forge nb_conda (for Jupyter support)
- Install CUDA Toolkit and cuDNN
- I. type: conda install -c anaconda cudatoolkit='version'
- Install tensorflow-gpu
- I. type: conda install -c anaconda tensorflow-gpu
- Install Jupyter Notebook
- I. type: conda install jupyter
- Register your environment
- type: python -m ipykernel install --user --name tensorflow --display-name 'Tensorflow (Py3.8)'
Note: try to keep with only using conda install for everything. Tensorflow reccommends using pip to install Tensorflow, but conda also works and it is better to use the same install type. Mixing conda and pip can cause issues.