My dataset is too huge to hold the entire data in the buffer, so I would like to hold only intermediate batches returned by the dataloader in the buffer.
If I have static buffer, can I provide a custom collate function to the datalaoder, which writes the batch into a buffer directly?
If so, do I need to do special handling for cases where num_workers > 0?