Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

T5 compile compatibilty #34089

Merged
merged 34 commits into from
Oct 22, 2024
Merged

T5 compile compatibilty #34089

merged 34 commits into from
Oct 22, 2024

Conversation

zucchini-nlp
Copy link
Member

What does this PR do?

Same as #33754, I accidentally force pushed to wrong branch and the PR got closed 🙃

Copy link
Member

@gante gante left a comment

Choose a reason for hiding this comment

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

Thank you for this refactor 🙏

I've left a question for us to double-check, but approving since it looks good to me.


⚠️ before merging, make sure to run the following slow tests to confirm that there are no regressions vs main: {all touched models} + {llama, whisper, caches}

Comment on lines +1644 to +1645
"Liana Barrientos has been married 10 times, nine of them in the Bronx . Her husbands filed for "
"permanent residence after the marriages, prosecutors say ."
Copy link
Member

Choose a reason for hiding this comment

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

Is this a new failure?

If yes: can you confirm a) the generated tokens are different b) compare the logprobs of the different tokens before/after the change, to see whether it can be explained by tiny fluctuations?

If no: can you add a comment with the PR that causes the difference? 🙏

Copy link
Member Author

@zucchini-nlp zucchini-nlp Oct 18, 2024

Choose a reason for hiding this comment

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

Added a comment, the regression was caused by changes in the tokenization. So nothing breaks in terms of modeling or generation. Not sure if the fix in tokenization was intended to break T5 (i.e. it actually fixes T5) or we need another PR to fix tokenization back, so I'll leave a comment for future us

Copy link
Collaborator

@ArthurZucker ArthurZucker left a comment

Choose a reason for hiding this comment

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

NICE! 🔥 thanks for adding the compile integration tests 🤗

@zucchini-nlp
Copy link
Member Author

Will merge this later today if we are all okay. The comment for tokenization is added within code with a TODO for us, in case it is not a bug we can remove the comment later

@zucchini-nlp zucchini-nlp merged commit 73d65e6 into huggingface:main Oct 22, 2024
24 of 26 checks passed
@IlyasMoutawwakil IlyasMoutawwakil mentioned this pull request Oct 24, 2024
5 tasks
BernardZach pushed a commit to BernardZach/transformers that referenced this pull request Dec 5, 2024
* this worked in normal generation, needs more tests

* fix almost all tests in t5

* nit

* longt5, umt5, mt5

* style

* udop, pix2struct

* more models

* fix some tests

* fix onnx tests

* tracing tests fixed

* compile enabled and tested for t5 models

* fix small bug in slow tests

* [run-slow] t5

* uncomment

* style

* update with new generation refactoring

* nit

* fix copies

* this is the fix, had to change t5 to fix copies

* update

* [run-slow] t5

* [run-slow] t5

* update

* add test for encoder only T5

* clean up after rebase

* fix pop2piano

* add comment

* style

* fix copies after rebase

* fix copies  missed this one
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.

3 participants