Forward() got an unexpected keyword argument 'labels_mask'


I am new to transformers, and am currently following this tutorial for my school project: Summarization - Hugging Face Course

I am following the instructions in the Accelerate section, except I am trying to fine tune the google/t5-v1_1-small model on the cnn_dailymail dataset. Eveything seems fine, but when I try to run the training loop, I get the following error trace:

0/3230 [00:00<?, ?it/s]

TypeError Traceback (most recent call last)
9 model.train()
10 for step, batch in enumerate(train_dataloader):
—> 11 outputs = model(**batch)
12 loss = outputs.loss
13 accelerator.backward(loss)

/usr/local/lib/python3.7/dist-packages/torch/nn/modules/ in _call_impl(self, *input, **kwargs)
1128 if not (self._backward_hooks or self._forward_hooks or self._forward_pre_hooks or _global_backward_hooks
1129 or _global_forward_hooks or _global_forward_pre_hooks):
→ 1130 return forward_call(*input, **kwargs)
1131 # Do not call functions when jit is used
1132 full_backward_hooks, non_full_backward_hooks = ,

TypeError: forward() got an unexpected keyword argument ‘labels_mask’

I already found question similar to mine, but the answers did not necessarily help.

thank you so much in advance!!!

Could someone please enlighten me?