how to install tensorflow on anaconda python 3.6

前端 未结 12 1885
滥情空心
滥情空心 2020-11-29 21:38

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

相关标签:
12条回答
  • 2020-11-29 21:42

    Uninstall Python 3.7 for Windows, and only install Python 3.6.0 then you will have no problem or receive the error message:

    import tensorflow as tf ModuleNotFoundError: No module named 'tensorflow'

    0 讨论(0)
  • 2020-11-29 21:47

    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

    0 讨论(0)
  • 2020-11-29 21:47

    Please refer this link :

    • Go to https://www.anaconda.com/products/individual and click the “Download” -button
    • Download the Python 3.7 64-Bit (x86) Installer
    • Run the downloaded bash script (.sh) file to begin the installation. See here for more details.
    • -When prompted with the question “Do you wish the installer to prepend the Anaconda<2 or 3> install location to PATH in your /home//.bashrc ?”, answer “Yes”. If you enter “No”, you must manually add the path to Anaconda or conda will not work.

    Select Windows or linked base command, In my case I have used Linux :

    Create a new Anaconda virtual environment Open a new Terminal window

    Type the following command: The above will create a new virtual environment with name tensorflow

    conda create -n tensorflow pip python=3.8
    
     conda activate tensorflow
    

    0 讨论(0)
  • 2020-11-29 21:56

    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.

    0 讨论(0)
  • 2020-11-29 21:56

    Well, conda install tensorflow worked perfect for me!

    0 讨论(0)
  • 2020-11-29 21:56

    conda create -n tensorflow_gpuenv tensorflow-gpu

    Or

    type the command pip install c:.*.whl in command prompt (cmd).

    0 讨论(0)
提交回复
热议问题