Some of the previous preparations will not be detailed here.
CUDA and cuDNN: how to install and configure. You can see a blog that tell you how to configure pytorch.
https://blog.csdn.net/m0_72572822/article/details/129938788?spm=1001.2014.3001.5501
And then I'll talk about how to install tensorflow-gpu. Okay.
Having installed CUDA and cuDNN,use conda to create a new enviroment of python.
conda create -n tensorflow2 python=3.8
conda activate tensorflow2
Then we can use this command to speed up the download.
pip config set global.index-url https://opentuna.cn/pypi/web/simple
Here I download the method is as follows.
pip install tensorflow-gpu==2.6.0
You can see the download speed is very fast.
At the end you will find the following prompt for a successful installation.
Input python to test.
import tensorflow as tf
If it shows the following error message:
Here's my solution.
pip install protobuf==3.20.0
Try again to test it.
This is already done.