Aggregating Dataloader : how?

Hello,

I am trying to find a proper solution to create a custom DataLoader able to handle multiple datasets with a specific strategy when yielding data.

More specifically, given a list of Datasets, I want the loader to take all of them in account and consider that a batch of data is actually a concatenation of a batch of each of those datasets.
Ideally I would like to handle samplers for each of those datasets too.

The problem is that a Dataloader only consider one dataset, and writing a custom Dataset doesn’t allow me to implement the fetching strategy that I want (batch/sampling) because this logic is in the Dataloader.

How could I pull through this issue ? Technically, rewriting another Dataloader may work but it’s kind of low-level so not the preferred solution at all.

Thanks :slight_smile: