Need to split the text data into train and test split in PyTorch as we do it for vision datasetLoader

Hi All,

Please could you help me with the pseudo code to split the text data into train-test split using datasetLoader as we do it for vision .

Regards,
Niranjan