Why should `attn_weights` be reshaped twice in BartAttention ?
Can anybody help to understand that? https://github.com/huggingface/transformers/blob/3437d12134893dd7b45737e422e105e511341297/src/transformers/models/bart/modeling_bart.py#L238-L244

@patrickvonplaten excuse me, could you share any idea please<|||||>See this PR for more information: https://github.com/huggingface/transformers/pull/8747<|||||>> See this PR for more information: #8747

Almost understand, although it's still weird. As #8747 explained,
```
This ensures that the returned hidden state tensors lie upstream in the graph from the model outputs (allowing their gradients to be computed)
```

Thanks!