Installing tensorflow gpu in anaconda 5.3

I have recently installed anaconda 5.3 and it came with python 3.7 preinstalled. Now when I checked tensorflow website it's says tensorflow does not support 3.7 only 3.6.

Tensorflow Requires Python 3.4, 3.5, or 3.6

What can I do now to have tensorflow gpu for my pc. Any help is appreciated. Is there any workaround?

Thanks.

1 answer

  • answered 2018-11-12 19:40 Geeocode

    You should create a new conda virtual environment with python 3.6, then install tensorflow into that. At the creation of the new env you can freely choose the python version you want to use. This is one of the essence of conda and virtual envs in general.

    A bit more details:

    Inside of the anaconda-navigator you can choose Environments, then choose create. Here you can give the new environment name and the packages basis i.e. Python or R and the versions you want to use it for the environment. Then you have to install your custom packages beside of the default ones. Here you can install tensorflow-gpu too. For installing packages you can choose Anaconda navigator GUI or inside of the Anaconda command shell with conda conda install <package> or in the Anaconda command shell pip install <package>. In general you should prefer Anaconda package management i.e. GUI or conda to the package versions be consistent, what conda manages well. In some cases -choose always the package developer's suggestion- however, you may choose pip install.