tf2.0不降版本也能完美解决module ‘tensorflow’ has no attribute ‘contrib’的问题
tf2.0不降版本也能完美解决module ‘tensorflow’ has no attribute 'contrib’的问题
看图
tf2.0版本更改
我在学习的过程中,发现了大佬们写的项目都是在1.0版本的基础上搭建的,所以在学习他们的项目的时候遇到了非常棘手的contrib模块(2.0中被弃用),看到网上所有人的解决方法都是讲2.0版本降到1.0版本(个人不想降,所以就尝试找其他的代替),最后发现,只要将
cell = tf.contrib.rnn.BasicLSTMCel
用
cell = tf.compat.v1.nn.rnn_cell.BasicLSTMCell
代替就可以完美的解决出现的问题。得到的结果没啥区别。
我只是知识的搬运工,刚开始学习不久,大佬们勿喷!大家一起学习。
tf2.0不降版本也能完美解决module ‘tensorflow’ has no attribute ‘contrib’的问题相关推荐
- 解决Tensorflow2.0出现:AttributeError: module 'tensorflow' has no attribute 'get_default_graph'的问题
问题描述 在使用tensorflow2.0时,遇到了这个问题: AttributeError: module 'tensorflow' has no attribute 'get_default_gr ...
- tf2.0环境下“module ‘tensorflow‘ has no attribute ‘log‘”的解决办法
写在这里的初衷,一是备忘,二是希望得到高人指点,三是希望能遇到志同道合的朋友. 目录 一.问题 二.根本原因 三.解决办法 方法一 方法二 一.问题 目前,尝试着通过tensorflow对医学图像进行 ...
- tensorflow2.0及以上版本在使用Session模块时报错:AttributeError: module ‘tensorflow‘ has no attribute ‘Session‘ 已解决
tensorflow2.0版本及之后的版本在使用Session模块时报错:AttributeError: module 'tensorflow' has no attribute 'Session' ...
- tensorflow版本问题导致的错误AttributeError: module ‘tensorflow‘ has no attribute ‘***‘
问题解决--AttributeError: module 'tensorflow' has no attribute 'placeholder' - yuanyuanWu11 - 博客园 tensor ...
- module ‘tensorflow‘ has no attribute xxx tensorflow版本问题类导致API函数的报错
目录 1. module 'tensorflow' has no attribute 'Session' 2. The Session graph is empty. Add operations t ...
- python pip 多个版本冲突问题 完美解决
为何要在一个系统中装多个Python版本 Python的主版本有2和3两个,还有一些特殊的包要求特殊的版本号.软件开发和测试中,可能会遇到不同开发对Python版本和包的要求不同,还可能要测试编写代码 ...
- Ant Design Vue Pro(V3.0.0 )MultiTab标签缓存,完美解决
使用Ant Design Vue Pro 基础框架都知道好用,但是MultiTab标签一直未解决(V3.0.0),最新版解决了但是要收费9K(2022-01-21日). 首先需要实现如下: Multi ...
- AttributeError: module 'tensorflow' has no attribute 'placeholder'等一系列tensorflow版本导致的问题
新人tensorflow2.1版本导致程序我无法运行最简单的办法 法1 tensorflow.compat.v1 import tensorflow.compat..v1 as tf tf.disab ...
- 解决Tensorflow2.0出现:AttributeError: module ‘tensorflow‘ has no attribute ‘get_default_graph‘的问题
https://blog.csdn.net/public669/article/details/99686151
最新文章
- 这10篇 iOS 热文,你别错过哦
- C++虚函数实现多态的机制
- 20个编写现代CSS代码的建议
- Python实现红黑树的插入操作
- 技术实践丨Prometheus+Grafana搭建HBase监控仪表盘
- Java实现二维码生成
- learn to study
- 为什么浏览器User-agent(浏览器类型)总是有Mozilla字样?
- 电机学(1) - 绪论
- 大型网页游戏开发流程
- GPRS通信原理+中国移动micro sim 卡,实现经过tcp/ip 传输数据到服务器
- HTML CSS参考文档,css离线手册
- 物联网模块--esp8266的wifi模块
- python科赫雪花正方形_python—科赫曲线(科赫雪花小包裹)
- 平板/笔记本亮度调节工具halo(WINDOWS)
- Unity lua os.time超过2038年1月19日3时14分07秒会出问题的解决办法(新千年虫问题、C#时间)
- Typora快捷键全
- Java程序员由笨鸟到菜鸟 电子版书正式发布 欢迎大家下载
- linux卸载informatica,Informatica在linux下安装搭建
- 如何安装、设置采集卡,如何使用采集卡工具检查采集信号
热门文章
- 比尔盖茨的15个预言,如今全已成真
- 速度来!《软技能:代码之外的生存指南 (第2版)》送书4本
- 1218学习笔记——kvm上vm+vtpm(IMA)
- python可视化丨从1896年说起,用数据看 120 年奥运变迁
- JMM内存模型 多线程三大特性
- y9000p + ubuntu18.04 亮度无法调节问题解决方法(亲测有效)
- SecureCRT for linux安装教学
- 初识MIMO(二):MIMO的信道容量及其仿真
- [转自mop]各大高校BBS上的100个爆笑的签名档
- android如何绑定事件,Android_安卓为按钮控件绑定事件的五种方式