Add output control for TFGPT2LMHeadModel
# What does this PR do?

Hi, guys. This pull request is going to add a parameter for `GPT2Config` and `TFGPT2LMHeadModel`, to control whether return multi-layer logits or not when training and fine-tuning.

Related issue #8503

Before this change, we need to assign the 'special' loss and metric:
```python
class MyMetrice(tf.keras.metrics.SparseCategoricalAccuracy):

    def update_state(self, y_true, y_pred, sample_weight=None):
        # It will receive output from all layers by default.
        if len(y_pred.shape) > 3:
            return 0
        return super(Mymetrice, self).update_state(y_true, y_pred, sample_weight)

model = TFGPT2LMHeadModel.from_pretrained("distilgpt2")
loss = tf.keras.losses.SparseCategoricalCrossentropy(from_logits=True)
metric = MyMetrice('accuracy')
model.compile(
    optimizer=optimizer,
    loss=[loss, *[None] * model.config.n_layer],    # It's hard to guess if there is no example
    metrics=[metric]
)
```
After this change, we can train or finetune samples easily.
```python
model = TFGPT2LMHeadModel.from_pretrained("distilgpt2", return_dict=False)
model.compile(
    optimizer=optimizer,
    loss=model.compute_loss,
    metrics=[tf.keras.metrics.SparseCategoricalAccuracy]
)

```

 GPT2: @LysandreJik, @patrickvonplaten
 tensorflow: @jplu

Hope this helps.
Hello!

Apparently you are rewriting the  `output_attentions` and `output_hidden_states` parameters.<|||||>Thanks for your advice. Yes, so it's a bad idea to only return `last_hidden_state` like this?<|||||>I mean, why you are not using the `output_attentions` or `output_hidden_states` parameters that basically do what you are proposing?<|||||>I'm sorry to make you confused, maybe my mastery of gpt2 is not enough. Could you please tell me where `output_attentions` and 
`output_hidden_states`(except last) will be used during training and text generation, I can't find the answer from the source code directly. 

I mean, if `output_attentions` or `output_hidden_states` is not using basically, it's better to hide it by default? And call something like `return_multilayer=True` to return those if we need it.

Thanks in advance. :)<|||||>No worries! Everything is nicely explained in the [documentation](https://huggingface.co/transformers/model_doc/gpt2.html#tfgpt2lmheadmodel):

```
output_attentions (bool, optional) – Whether or not to return the attentions tensors of all attention layers. See attentions under returned tensors for more detail.
output_hidden_states (bool, optional) – Whether or not to return the hidden states of all layers. See hidden_states under returned tensors for more detail.
```<|||||>Thank @jplu , this RP exactly rewriting the `output_attentions` and `output_hidden_states` parameters of `GPT2Config`, close it.

<|||||>You're welcome, happy to help :)