Getting error following the official docs for T5 translation fine-tuning: 'tensorflow.python.framework.ops.EagerTensor' object has no attribute 'new_zeros'
### System Info

- `transformers` version: 4.20.1
- Platform: Linux-5.4.188+-x86_64-with-Ubuntu-18.04-bionic
- Python version: 3.7.13
- Huggingface_hub version: 0.8.1
- PyTorch version (GPU?): 1.12.0+cu113 (False)
- Tensorflow version (GPU?): 2.8.2 (False)
- Flax version (CPU?/GPU?/TPU?): not installed (NA)
- Jax version: not installed
- JaxLib version: not installed
- Using GPU in script?: No
- Using distributed or parallel set-up in script?: No

### Who can help?

@patrickvonplaten

### Information

- [X] The official example scripts
- [ ] My own modified scripts

### Tasks

- [X] An officially supported task in the `examples` folder (such as GLUE/SQuAD, ...)
- [ ] My own task or dataset (give details below)

### Reproduction

When I follow the TF steps on [huggingface.co/docs/transformers/tasks/translation](https://huggingface.co/docs/transformers/tasks/translation), I get the error `'tensorflow.python.framework.ops.EagerTensor' object has no attribute 'new_zeros'`.  I created a Colab notebook that reproduces the issue

https://github.com/gorkemozkaya/Data-Science-Notes/blob/master/reproducing_bugs/Error_with_the_translation_fine_tuning_example.ipynb


### Expected behavior

Getting the data pipeline in the TF-dataset form without getting an error
I noticed the issue is due to using the PT model instead of the TF, but the documentation still needs to be fixed, because it is using the `model`  for creating the `data_collator` before the model is actually loaded, for both TF and PT. <|||||>This issue has been automatically marked as stale because it has not had recent activity. If you think this still needs to be addressed please comment on this thread.

Please note that issues that do not follow the [contributing guidelines](https://github.com/huggingface/transformers/blob/main/CONTRIBUTING.md) are likely to be ignored.<|||||>https://github.com/huggingface/transformers/pull/18169#issuecomment-1186713812 solves the issue