Ho, well you can’t 
To make sure you get enough data for your training procedure, we usually use DataLoader with multiple workers. That way you have multiple processes loading and preprocessing data.
You should check the examples in the doc for how to do that.