'tensorflow 2,8 is installed in environment but when I run a notebook it prints out tf version as 2.3

I created an environment using conda and installed tensorflow 2.8 and CUDA. I am using python version 3.8.1. In a terminal I activated the environment and typed pip show tensorflow and it prints out version 2.8 as expected. Now I open a jupyter notebook in that environment and run the code to check for the gpu and it finds it. Then I ran

 print(tf.__version__)

and it prints out 2.3.0. Why is it showing a different version?



Solution 1:[1]

well I tried all kinds of stuff and could not solve the problem. So I decided to start from scratch. I remove anaconda/ I remove all versions of the CUDA toolkit and Cundd. I made sure all those directories were deleted. I remove all the environmental variables from path that reference the cuda paths. Then I re installed anaconda and create a new virtual environment(I forget I also deleted all anaconda generated directories). Then I followed the exact procedure to install tensorflow , the CUdatoolit and cudnn. Then all worked as it should.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Gerry P