Skip to content

Conversation

@Rocketknight1
Copy link
Member

@Rocketknight1 Rocketknight1 commented Dec 12, 2022

Fixes #20724

@Rocketknight1 Rocketknight1 changed the title Fix AdamWeightDecay for TF Fix AdamWeightDecay for TF 2.11 Dec 12, 2022
@Rocketknight1
Copy link
Member Author

@gante take a quick look at this one too, please! Our AdamWeightDecay doesn't work with the new Optimizer base class in TF 2.11, so I moved it onto the legacy class for now. When I have more time I should clean this up properly, and possibly just use the official AdamW instead.

@HuggingFaceDocBuilderDev
Copy link

HuggingFaceDocBuilderDev commented Dec 12, 2022

The documentation is not available anymore as the PR was closed or merged.

Copy link
Collaborator

@sgugger sgugger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing!

@Rocketknight1 Rocketknight1 merged commit 4f1788b into main Dec 13, 2022
@Rocketknight1 Rocketknight1 deleted the fix_adamweightdecay branch December 13, 2022 12:51
mpierrau pushed a commit to mpierrau/transformers that referenced this pull request Dec 15, 2022
* Fix AdamWeightDecay for TF

* Fix AdamWeightDecay for TF

* make fixup
@el-profesor-04
Copy link

The same issue occurred with the Summarization tutorial. https://huggingface.co/course/chapter7/5?fw=tf#models-for-text-summarization

@Rocketknight1
Copy link
Member Author

Thanks @el-profesor-04 - can you confirm that the issue goes away with you install the latest version of transformers from main with pip install --upgrade git+https://github.com/huggingface/transformers.git?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Tutorial on token classification throws casting error in Tensorflow 2.11

5 participants