ImportError: Using the Trainer with PyTorch: Seq2SeqTrainingArguments

Trying to implement Whisper fine tuning on colab: Google Colab
When trying the step: training_args = Seq2SeqTrainingArguments(…) got the following error message:
ImportError: Using the Trainer with PyTorch requires accelerate>=0.19.0: Please run pip install transformers[torch] or pip install accelerate -U

I tried both pip install transformers[torch] or pip install accelerate -U with no success. Any help is appreciated.

2 Likes

same, did you find any solution?

1 Like

One option is “!pip install accelerate -U” at the very beginning, then restart the runtime and it should work.
Another option may be to downgrade pytorch to 1.3.1 version.
I hope it helps

4 Likes

Restaring the Runtime in Colab solved this issue for me

3 Likes

This fixed the issue for me