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

Training T5 #1

Open
yejh123 opened this issue Sep 25, 2023 · 6 comments
Open

Training T5 #1

yejh123 opened this issue Sep 25, 2023 · 6 comments

Comments

@yejh123
Copy link

yejh123 commented Sep 25, 2023

Hello, I attempt to train a T5 model, but I cannot run the code. Where is the file trainer_seq2seq_t5 in run_maxtokens_translation.py?

@li-aolong
Copy link
Owner

The file trainer_seq2seq_t5 is in my local environment. It is same as the trainer_seq2seq.
Just replace from transformers.trainer_seq2seq_t5 import Seq2SeqTrainer with from transformers.trainer_seq2seq import Seq2SeqTrainer.

@yejh123
Copy link
Author

yejh123 commented Sep 26, 2023

I got it. But if I use the default Seq2SeqTrainer, how can I train models using SortishSampler with max_token?

@li-aolong
Copy link
Owner

Sorry, I don't know about SortishSampler. It can be set True in Seq2SeqTrainingArguments.

@yejh123
Copy link
Author

yejh123 commented Sep 26, 2023

I mean I want to train with max_token, not with batch_size. But if I use the default Seq2SeqTrainer, it will train the model with batch_size. Would you please tell me how to train with max_token since it seems to be helpful to speed up the training?

@li-aolong
Copy link
Owner

I before tried to train with max_token with run_maxtokens_translation.py, but it was still with batch_size. So I don't konw, too.

@yejh123
Copy link
Author

yejh123 commented Sep 27, 2023

Anyway, thanks for answering.

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

No branches or pull requests

2 participants