Great, thank you, this is perfect.
I didn’t realize ConcatDataset was what I needed, but after concatenating the MNIST data with my modified data, torch.utils.data.DataLoader works fine on the new combined dataset.