Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to install tensorflow on anaconda python 3.6

I installed the new version python 3.6 with the anaconda package. However i am not able to install tensorflow. Always receive the error that

tensorflow_gpu-1.0.0rc2-cp35-cp35m-win_amd64.whl is not a supported wheel on this platform.

How can I install tensorflow on anaconda (python 3.6)?

like image 458
Muten_Roshi Avatar asked Apr 14 '17 22:04

Muten_Roshi


People also ask

Does Python 3.7 support TensorFlow?

TensorFlow is tested and supported on the following 64-bit systems: Python 3.7–3.10.

Is TensorFlow available in Anaconda?

Like other packages in the Anaconda repository, TensorFlow is supported on a number of platforms. TensorFlow conda packages are available for Windows, Linux, and macOS.


4 Answers

UPDATE: TensorFlow supports Python 3.6 on Windows since version 1.2.0 (see the release notes)


TensorFlow only supports Python 3.5 64-bit as of now. Support for Python 3.6 is a work in progress and you can track it here as well as chime in the discussion.

The only alternative to use Python 3.6 with TensorFlow on Windows currently is building TF from source.

If you don't want to uninstall your Anaconda distribution for Python 3.6 and install a previous release you can create a conda environment for Python=3.5 as in: conda create --name tensorflow python=3.5 activate tensorflow pip install tensorflow-gpu

like image 197
Adriano Avatar answered Sep 28 '22 09:09

Adriano


This is what I did for Installing Anaconda Python 3.6 version and Tensorflow on Window 10 64bit.And It was success!

  1. Download Anaconda Python 3.6 version for Window 64bit.

  2. Create a conda environment named tensorflow by invoking the following command:

    C:> conda create -n tensorflow  
  3. Activate the conda environment by issuing the following command:

    C:> activate tensorflow (tensorflow)C:>  # Your prompt should change  
  4. Download “tensorflow-1.0.1-cp36-cp36m-win_amd64.whl” from here. (For my case, the file will be located in “C:\Users\Joshua\Downloads” once after downloaded).

  5. Install the Tensorflow by using following command:

    (tensorflow)C:>pip install C:\Users\Joshua\Downloads\ tensorflow-1.0.1-cp36-cp36m-win_amd64.whl 

This is what I got after the installing: enter image description here

  1. Validate installation by entering following command in your Python environment:

    import tensorflow as tf hello = tf.constant('Hello, TensorFlow!') sess = tf.Session() print(sess.run(hello)) 

If the output you got is 'Hello, TensorFlow!',that means you have successfully install your Tensorflow.

like image 30
Joshua Avatar answered Sep 28 '22 09:09

Joshua


Simple Way from Scratch.

  1. Download Anaconda from https://repo.anaconda.com/archive/Anaconda3-5.2.0-Windows-x86_64.exe

  2. Install Anaconda by double clicking it.

  3. Open anaconda prompt by searching anaconda in windows search and type the following command while being connected to internet.

    A. conda create -n tensorflow_env python=3.6

    B. conda activate tensorflow_env

    C. conda install -c conda-forge tensorflow

Step C will take time. After install type python in conda prompt and type

import tensorflow as tf

If no error is found your installation is successful.

like image 41
Sandeep Kumar Avatar answered Sep 28 '22 08:09

Sandeep Kumar


According to :https://anaconda.org/intel/tensorflow

To install this package with conda run:

conda install -c intel tensorflow

pip install To install this package with pip:

pip install -i https://pypi.anaconda.org/intel/simple tensorflow
like image 44
Ron Avatar answered Sep 28 '22 08:09

Ron