美文网首页
2020-06-06

2020-06-06

作者: 小醇仔 | 来源:发表于2020-06-06 14:59 被阅读0次

@[TOC](module 'tensorflow' has no attribute 'xxxx'解决办法)

module 'tensorflow' has no attribute 'xxxx'解决办法

当你安装TensorFlow时候,出现module 'tensorflow' has no attribute 'xxxx'

是你代码用的TensorFlow1.0版本,而编译时候用的TensorFlow2.0版本

解决办法:
1卸载TensorFlow2.0版本

pip uninstall tensorflow

2安装TensorFlow1.0版本
(首选清华大学镜像安装,速度快)

pip3 install tensorflow==1.3.0 -i https://pypi.tuna.tsinghua.edu.cn/simple/

相关文章

网友评论

      本文标题:2020-06-06

      本文链接:https://www.haomeiwen.com/subject/kmixtktx.html