Solved by russellizadi in post #2 
              
              
                I suggest you to define your own dataset so that you can use only one loader while taking batches from both tensors. For example, you can use something like this: 
import torch
size = 16
a = torch.randn(size,3,224,224)
b = torch.randn(size,3,224,224)

class Dataset(torch.utils.data.Dataset):
    def…