-
Notifications
You must be signed in to change notification settings - Fork 31.7k
Add image classifier donut & update loss calculation for all swins #37224
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
Add image classifier donut & update loss calculation for all swins #37224
Conversation
|
Hi 👋, thank you for opening this pull request! The pull request is converted to draft by default. The CI will be paused while the PR is in draft mode. When it is ready for review, please click the |
| _EXPECTED_OUTPUT_SHAPE = [1, 49, 768] | ||
|
|
||
| # Image classification docstring | ||
| _IMAGE_CLASS_CHECKPOINT = "eljandoubi/donut-base-encoder" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this a checkpoint trained for classification or base model ckpt?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Traind base model with randomly initialized head. It is meant for further fine tuning.
zucchini-nlp
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, looks good to me! Requesting review from core maintainer
|
@zucchini-nlp @ArthurZucker @ydshieh any feedback? |
|
sorry, let's merge it. Doesn't touch much core code, should be good to go |
…uggingface#37224) * add classifier head to donut * add to transformers __init__ * add to auto model * fix typo * add loss for image classification * add checkpoint * remove no needed import * reoder import * format * consistency * add test of classifier * add doc * try ignore * update loss for all swin models
…uggingface#37224) * add classifier head to donut * add to transformers __init__ * add to auto model * fix typo * add loss for image classification * add checkpoint * remove no needed import * reoder import * format * consistency * add test of classifier * add doc * try ignore * update loss for all swin models
What does this PR do?
LOSS_MAPPINGModels: