# Import error in TrainingArguments of llm in colab

**URL:** <https://community.deeplearning.ai/t/import-error-in-trainingarguments-of-llm-in-colab/548962>\
**Category:** Finetuning Large Language Models\
**Created:** [January 19, 2024, 1:39pm UTC](https://community.deeplearning.ai/t/import-error-in-trainingarguments-of-llm-in-colab/548962 "2024-01-19T13:39:06Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![souravmodi221](https://avatars.discourse-cdn.com/v4/letter/s/e47c2d/32.png) [@souravmodi221](https://community.deeplearning.ai/u/souravmodi221)\
**Post date:** [January 19, 2024, 1:39pm UTC](https://community.deeplearning.ai/t/import-error-in-trainingarguments-of-llm-in-colab/548962/1 "2024-01-19T13:39:06Z")

</div>

from transformers import TrainingArguments

training\_args = TrainingArguments(  
learning\_rate=1.0e-5,  
…  
)

**Getting error in colab while running TrainingArguments() . Installed accelerate version 0.26.1 but still getting the same error.**

/usr/local/lib/python3.10/dist-packages/transformers/training\_args.py in \_setup\_devices(self)  
1785 if not is\_sagemaker\_mp\_enabled():  
1786 if not is\_accelerate\_available(min\_version=“0.20.1”):  
 → 1787 raise ImportError(  
1788 “Using the `Trainer` with `PyTorch` requires `accelerate>=0.20.1`: Please run `pip install transformers[torch]` or `pip install accelerate -U`”  
1789 )

ImportError: Using the `Trainer` with `PyTorch` requires `accelerate>=0.20.1`: Please run `pip install transformers[torch]` or `pip install accelerate -U`
