# FineTune TFT5ForConditionalGeneration Batch Size

**URL:** <https://discuss.huggingface.co/t/finetune-tft5forconditionalgeneration-batch-size/24855>\
**Category:** Models\
**Created:** [October 23, 2022, 10:25pm UTC](https://discuss.huggingface.co/t/finetune-tft5forconditionalgeneration-batch-size/24855 "2022-10-23T22:25:16Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![RERobbins](https://avatars.discourse-cdn.com/v4/letter/r/22d042/32.png) [@RERobbins](https://discuss.huggingface.co/u/RERobbins)\
**Post date:** [October 23, 2022, 10:25pm UTC](https://discuss.huggingface.co/t/finetune-tft5forconditionalgeneration-batch-size/24855/1 "2022-10-23T22:25:16Z")

</div>

How do I set the batch size when trying to FineTune a TFT5ForConditionalGeneration model?

Currently, I’ve run my input sequences and labels through the T5Tokenizer and am calling the model with…

output = model(input\_ids=input\_ids, attention\_mask=attention\_mask, labels=target\_ids)

where model = TFT5ForConditionalGeneration.from\_pretrained(“google/t5-v1\_1-base”)
