I would like to add the following:
for i,sample in enumerate(train_loader):
    mr = sample[0].float().to(device)
    print('input sample shape of train_loader: {}'.format(mr.shape))
    break

gives :
input sample shape of train_loader: torch.Size([5, 1, 500, 32, 32, 32])

Process finished with exit code 0

which is not the exact thing I was expecting. I wanted 5/10 patches at a time. Based on the batch_size = 5 or 10.
Do you think transpose function may come handy?