Trainer - deprecate tokenizer for processing_class
Author: amyeroberts
Pull request: yes

For reviewers: most files touched here are just updates to the documentation. Unfortunately, a lot of the diff is just stripping of unnecessary whitespaces (which my editor does automatically). 

The most important changes are in: 
* src/transformers/trainer.py
* src/transformers/trainer_callback.py
* src/transformers/trainer_seq2seq.py

-------------------------------------------

# What does this PR do?

At the moment, if we wish for a processing class e.g. an image processor, to be saved alongside the model e.g. when pushing to the hub, we have to do the following: 

```py
trainer = Trainer(
    model, 
    args, 
    tokenizer=image_processor, 
    ...
)
```

This causes a lot of confusion for users (an image processor is not a tokenizer). 

Previous efforts were made to add individual classes to the trainer s.t. one could do: `trainer = Trainer(model, args, image_processor=image_processor, ...)`, however, this has some drawbacks: 
* It creates ambiguity when a model has a processor class: should we be able to do `Trainer(model, args, processor=processor)` or should it be `Trainer(model, args, tokenizer=tokenizer, image_processor=image_processor)`? 
* It adds new arguments to handle for every processing class, meaning more work if future classes are added

This PR therefore just deprecates `tokenizer` in favour of a more general `processing_class` argument, which can be any class with a `from_pretrained` method. 

Relevant PRs and discussions: 
* #29896
* #30129 
* #30102 
* #30864


## Before submitting
- [ ] This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
- [ ] Did you read the [contributor guideline](https://github.com/huggingface/transformers/blob/main/CONTRIBUTING.md#create-a-pull-request),
      Pull Request section?
- [ ] Was this discussed/approved via a Github issue or the [forum](https://discuss.huggingface.co/)? Please add a link
      to it if that's the case.
- [ ] Did you make sure to update the documentation with your changes? Here are the
      [documentation guidelines](https://github.com/huggingface/transformers/tree/main/docs), and
      [here are tips on formatting docstrings](https://github.com/huggingface/transformers/tree/main/docs#writing-source-documentation).
- [ ] Did you write any new necessary tests?


## Who can review?

Anyone in the community is free to review the PR once the tests have passed. Feel free to tag
members/contributors who may be interested in your PR.

<!-- Your PR will be replied to more quickly if you can figure out the right person to tag with @

 If you know how to use git blame, that is the easiest way, otherwise, here is a rough guide of **who to tag**.
 Please tag fewer than 3 people.

Models:

- text models: @ArthurZucker
- vision models: @amyeroberts
- speech models: @sanchit-gandhi
- graph models: @clefourrier

Library:

- flax: @sanchit-gandhi
- generate: @zucchini-nlp (visual-language models) or @gante (all others)
- pipelines: @Narsil
- tensorflow: @gante and @Rocketknight1
- tokenizers: @ArthurZucker
- trainer: @muellerzr and @SunMarc

Integrations:

- deepspeed: HF Trainer/Accelerate: @muellerzr
- ray/raytune: @richardliaw, @amogkam
- Big Model Inference: @SunMarc
- quantization (bitsandbytes, autogpt): @SunMarc

Documentation: @stevhliu

HF projects:

- accelerate: [different repo](https://github.com/huggingface/accelerate)
- datasets: [different repo](https://github.com/huggingface/datasets)
- diffusers: [different repo](https://github.com/huggingface/diffusers)
- rust tokenizers: [different repo](https://github.com/huggingface/tokenizers)

Maintained examples (not research project or legacy):

- Flax: @sanchit-gandhi
- PyTorch: See Models above and tag the person corresponding to the modality of the example.
- TensorFlow: @Rocketknight1

 -->


Comments:
The docs for this PR live [here](https://moon-ci-docs.huggingface.co/docs/transformers/pr_32385). All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

Love this (Always confused about writing `tokenizer=image_processor`)

@molbap If you have capacity - do you think you could do a first review of this? Arthur and Zack are super busy so would be good to have someone who knows the processors well to review in their stead 

Asking for review from @SunMarc for Trainer as Zach is off. As this is a very public API I'd like to get a few eyes on it, especially from people who know it well, to make sure it's OK! 

_pad_tensors_to_max_len in Seq2SeqTrainer still uses tokenizer instead of  processing_class