Thanks for the reply! You were right, I loaded the data in the __init__ in order to keep it in memory. Since the dataset is quite large (approximately 12gb) the problem you mentioned occurred. I tried lazy loading and it does work and kinda solves the problem, thank you for that! Still, isn’t copying the data to all processes weird as it is already in the ram in the first place? Shouldn’t the dataloader just give markers to the subprocesses which then get their samples from the data loaded with __init__ ? Because otherwise I would load 8 times the same 12gb dataset into the ram, right?