# Program hangs when creating a transformers.TrainingArguments object

**URL:** <https://discuss.huggingface.co/t/program-hangs-when-creating-a-transformers-trainingarguments-object/39156>\
**Category:** 🤗Transformers\
**Created:** [May 9, 2023, 3:20am UTC](https://discuss.huggingface.co/t/program-hangs-when-creating-a-transformers-trainingarguments-object/39156 "2023-05-09T03:20:06Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![emmabyp](https://avatars.discourse-cdn.com/v4/letter/e/aeb1de/32.png) [@emmabyp](https://discuss.huggingface.co/u/emmabyp)\
**Post date:** [May 9, 2023, 3:20am UTC](https://discuss.huggingface.co/t/program-hangs-when-creating-a-transformers-trainingarguments-object/39156/1 "2023-05-09T03:20:06Z")

</div>

Hi! I’m trying to create a transformers.TrainingArguments object in a JupyterLab notebook as follows

```auto
transformers.TrainingArguments(
    per_device_train_batch_size=8,
    gradient_accumulation_steps=16,
    warmup_steps=100,
    num_train_epochs=2,
    learning_rate=2e-5,
    fp16=True,
    logging_steps=1,
    output_dir="lora-dolly",
    save_total_limit=3,
)

```

but the program gets stuck trying to run this cell.

My deps are:

- torch == 1.13.1+cu117
- transformers == 4.29.0.dev0

This is really confusing since I’m not loading any model into memory, just trying to initialize a TrainingArguments object. Wonder if anyone has seen similar issues before?

---

<div class="post-metadata">

**Author:** ![kllisre](https://avatars.discourse-cdn.com/v4/letter/k/f08c70/32.png) [@kllisre](https://discuss.huggingface.co/u/kllisre)\
**Post date:** [October 5, 2023, 4:30pm UTC](https://discuss.huggingface.co/t/program-hangs-when-creating-a-transformers-trainingarguments-object/39156/2 "2023-10-05T16:30:34Z")

</div>

Hey, may I know if you fixed this?  
I’ve faced the same bug.

---

<div class="post-metadata">

**Author:** ![xorima](https://avatars.discourse-cdn.com/v4/letter/x/8dc957/32.png) [@xorima](https://discuss.huggingface.co/u/xorima)\
**Post date:** [April 23, 2024, 4:56am UTC](https://discuss.huggingface.co/t/program-hangs-when-creating-a-transformers-trainingarguments-object/39156/3 "2024-04-23T04:56:01Z")

</div>

Same issue on databricks notebook  
transformers==4.40.0  
torch==2.2.2
