Running MLM pretraining with not "line_by_line" big dataset
# 🚀 Feature request

BERT pretraining with not line_by_line big dataset.

## Motivation
I'm trying to pretrain a BERT model with the classic masking task (without NSP), using examples/pytorch/language_modeling/run_mlm.py script. As with the original BERT, I would not like to construct each example of the batch using only one sentence, but would like to take a portion of text as long as max_sequence_lenght. This feature is provided if you set the "line_by_line" parameter to false with the "group_texts" function.
The problem is that I have a big dataset and I have to use "on-the-fly" tokenization with set_transform (as suggested in #10204). Given that, I can't map my dataset with group_texts anymore.

Is it possible to make it possible?

@sgugger 

Hi there!

As mentioned in the README, examples are just examples. We can't show every single usecase everyone will want, so it's up to you to adapt them to your needs :-). If you need help, you can reach out on the [forums](https://discuss.huggingface.co/) or our Discord.<|||||>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/master/CONTRIBUTING.md) are likely to be ignored.