Add TF ResNet model
Author: amyeroberts
Pull request: yes
Labels: name: New model

Adds a tensorflow implementation of the ResNet model + associated tests.


## Before submitting
- [ ] This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
- [x] Did you read the [contributor guideline](https://github.com/huggingface/transformers/blob/main/CONTRIBUTING.md#start-contributing-pull-requests),
      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.
- [x] 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.

Comments:
_The documentation is not available anymore as the PR was closed or merged._

Swapping @sgugger and @LysandreJik as Lysandre's off and adding @Rocketknight1 for the TF side. 

I'm seeing a failure in `test_keras_fit` - it looks like the outputs are different depending on whether the labels are passed in the input dict or separately. That might actually have nothing to do with the labels and instead be caused by some random differences in the model outputs, though - maybe the `training` flag isn't being passed correctly so layers like dropout are still being run in training mode during eval time? Alternatively, maybe the tolerances we use for NLP models are just too strict for this one?

Please also incorporate the updates made in #17731 

> I'm seeing a failure in test_keras_fit - it looks like the outputs are different depending on whether the labels are passed in the input dict or separately. That might actually have nothing to do with the labels and instead be caused by some random differences in the model outputs, though - maybe the training flag isn't being passed correctly so layers like dropout are still being run in training mode during eval time? Alternatively, maybe the tolerances we use for NLP models are just too strict for this one?

@Rocketknight1 Digging into this - I believe this is because of the batch norm layers. Every time the layer is called it updates its `moving_mean` and `moving_variance` parameters. During training, the batches are normalised based on the batch stats, which will be exactly the same for both fit calls, because the data isn't shuffled. And we see this - the training loss for the two histories in `test_keras_fit` are exactly the same. However, at inference the batches are normalised based on the `moving_mean` and `moving_var` params. I'm not really sure how to address this. @ydshieh have we handled anything like this with tests before? 

Weirdly, the test was passing before. I'm guessing just a fluke? 

Ahhh, of course! I had thought that running a single iteration of training with a learning rate of 0 would leave the weights unchanged, but that isn't true for `BatchNorm`, because `BatchNorm` weights aren't updated by gradient descent. The test was broken and we only got away with it because NLP models generally don't use `BatchNorm`. I'll fix it tomorrow!

@sgugger Sorry - I didn't mean to re-request for you as you'd already approved! 

@NielsRogge @Rocketknight1 friendly nudge - let me know if there's any other changes or if I'm good to merge :)