UnboundLocalError: local variable 'params_docstring' referenced before assignment
### System Info

https://github.com/huggingface/transformers/blob/v4.27.4/src/transformers/utils/doc.py#L130
BUG about 'params_docstring' is reported

### Who can help?

_No response_

### Information

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

### Tasks

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

### Reproduction

It occurs when "if i < len(lines):" not match

### Expected behavior

Fix bugs or add assertion
For Reproduction:
It occurs when we define a new subClass with no definition<|||||>No one will be able to help without a clear reproducer.<|||||>For example, we define a subclass of BaseModelOutputWithPoolingAndCrossAttentions, but with no args explanations. 
```
class NewBaseModelOutputWithPoolingAndCrossAttentions(BaseModelOutputWithPoolingAndCrossAttentions):
    final_text_self_embedding: Optional[torch.FloatTensor] = None
    final_text_visual_embedding: Optional[torch.FloatTensor] = None
    text_visual_states: Optional[Tuple[torch.FloatTensor]] = None
```
`lines = output_docstring.split("\n")`  would return a null result, then `if i < len(lines):` would not be executed.<|||||>Why would you use our internal tools for the documentation if you are not documenting the class?<|||||>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.