简体   繁体   English

在Windows 10上导入Tensorflow Python 3.7的问题

[英]Issues with importing tensorflow python 3.7 on windows 10

I have issues with importing tensorflow on my computer. 我在计算机上导入Tensorflow时遇到问题。 After I received errors initially, I reinstalled Anaconda with the newest version Anaconda 5.3 for wihndows - python 3.7 . 最初收到错误后,我为wihndows-python 3.7重新安装了最新版本的Anaconda 5.3。 For the installation I used the following commands on cmd: 对于安装,我在cmd上使用了以下命令:

  • conda install tensorflow-gpu - got an error because of different versions, and continued with the following: conda install tensorflow-gpu由于版本不同而出现错误,并继续执行以下操作:
  • conda create -n Tensorflow anaconda python=3.7 - installed some packages , as required conda create -n Tensorflow anaconda python=3.7根据需要安装了一些软件包
  • activate Tensorflow
  • pip install --ignore-installed --upgrade https://storage.googleapis.com/tensorflow/windows/cpu/tensorflow-1.1.0-cp35-cp35m-win_amd64.whl --> Got the following error : tensorflow-1.1.0-cp35-cp35m-win_amd64.whl is not a supported wheel on this platform. pip install --ignore-installed --upgrade https://storage.googleapis.com/tensorflow/windows/cpu/tensorflow-1.1.0-cp35-cp35m-win_amd64.whl >出现以下错误: tensorflow-1.1.0-cp35-cp35m-win_amd64.whl is not a supported wheel on this platform.

Afterwards I tried to import it on jupyter notebook anyway and got error again: 之后,我还是尝试将其导入jupyter笔记本上,并再次出现错误:

ModuleNotFoundError                       Traceback (most recent call last)
<ipython-input-1-64156d691fe5> in <module>()
----> 1 import tensorflow as tf

ModuleNotFoundError: No module named 'tensorflow'

Can anyone advise how can I solve it? 谁能建议我该如何解决?

just uninstall your python 3.7.xxxx versions,then install python 3.6.xx or lower version,now you can run pip install tensorflow successfully. 只需卸载python 3.7.xxxx版本,然后安装python 3.6.xx或更低版本,现在就可以成功运行pip install tensorflow。 don't forget reset your ide's python path and reinstall other packages. 不要忘记重置ide的python路径并重新安装其他软件包。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM