# Train T5 model with two different datasets

**URL:** </static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Ftrain-t5-model-with-two-different-datasets%2F28208%3E%5C
**Category:** 🤗Transformers\
**Created:** [December 21, 2022, 6:15am UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Ftrain-t5-model-with-two-different-datasets%2F28208 "2022-12-21T06:15:13Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![viswanath660](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/viswanath660/32/13152_2.png) [@viswanath660](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2Fviswanath660)%5C
**Post date:** [December 21, 2022, 6:15am UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Ftrain-t5-model-with-two-different-datasets%2F28208%2F1 "2022-12-21T06:15:13Z")

</div>

Hi All,

I trained t5-base for a particular dataset to split a sentence into two and got a Pytorch model. Now, I want to train the pytorch model for another dataset for translation. How do I go about doing it?

I cannot use the following for my trained model:

from simpletransformers.t5 import T5Model  
model = T5Model(“t5”,“t5-base”, args=args)

model.train\_model(train\_data, eval\_data=test\_data, use\_cuda=True,acc=sklearn.metrics.accuracy\_score)
