当前位置:网站首页>AttributeError: ‘tuple‘ object has no attribute ‘layer‘问题解决
AttributeError: ‘tuple‘ object has no attribute ‘layer‘问题解决
2022-07-02 23:31:00 【不撸先疯。】
一、问题描述
安装keras_bert、tensorflow、keras后,本来程序运行好好的,训练了两个模型也一切正常,随后由于Bert英文分词时,keras_bert不满足要求,尝试了transformers和bert4keras中的tokenizer后,突然报错,模型生成有问题。

查阅多方资料显示版本不兼容,tensorflow2.0以上会出现和keras版本问题。
二、问题解决
测试通过版本1:
python == 3.6
tensorflow-gpu == 2.2.0
keras == 2.4.3
keras_bert == 0.89.0
版本2:
python 2.7 + tensorflow 1.13 + keras 2.2.4
三、问题解决
版本匹配很重要!!!
至此,问题解决!
边栏推荐
- NC50965 Largest Rectangle in a Histogram
- Chapter 3 of getting started with MySQL: database creation and operation
- NC50965 Largest Rectangle in a Histogram
- Centos7 one click compilation to build MySQL script
- 论文的设计方案咋写?
- Mutual exclusion and synchronization of threads
- How to write the design scheme of the thesis?
- Basic 10 of C language: array and pointer
- Multiprocess programming (I): basic concepts
- 【Pulsar文档】概念和架构/Concepts and Architecture
猜你喜欢

可下载《2022年中国数字化办公市场研究报告》详解1768亿元市场

Pageoffice - bug modification journey

Sysdig analysis container system call

Solution to the problem of abnormal display of PDF exported Chinese documents of confluence

【雅思阅读】王希伟阅读P1(阅读判断题)
![[shutter] Introduction to the official example of shutter Gallery (learning example | email application | retail application | wealth management application | travel application | news application | a](/img/f2/f3b8899aa774dd32006c5928d370f1.gif)
[shutter] Introduction to the official example of shutter Gallery (learning example | email application | retail application | wealth management application | travel application | news application | a

TypeError: Cannot read properties of undefined (reading ***)

哪些软件可以整篇翻译英文论文?

Multiprocess programming (I): basic concepts

Architecture: load balancing
随机推荐
UART、RS232、RS485、I2C和SPI的介绍
秒杀系统设计
[shutter] Introduction to the official example of shutter Gallery (project introduction | engineering construction)
NC24840 [USACO 2009 Mar S]Look Up
[shutter] image component (image component introduction | image constructor | image.network constructor | image.asset constructor)
Nc20806 District interval
About the practice topic of screen related to unity screen, unity moves around a certain point inside
有哪些比较推荐的论文翻译软件?
logback配置文件
Pytorch 20 realizes corrosion expansion based on pytorch
Andorid 获取系统标题栏高度
JS interviewer wants to know how much you understand call, apply, bind no regrets series
NC24325 [USACO 2012 Mar S]Flowerpot
奥斯陆大学:Li Meng | 基于Swin-Transformer的深度强化学习
[target detection] r-cnn, fast r-cnn, fast r-cnn learning
Is there a specific format for English papers?
Bigder: how to deal with the bugs found in the 32/100 test if they are not bugs
Automated defect analysis in electronic microscopic images
[reading notes] phased summary of writing reading notes
Form form instantiation
至此,问题解决!