Is your Dataset working without the DataLoader?
Try to call dataset[0] and see if you’ll get the same error.
Also, is data stored on the GPU?
Could you check, if CUDA works at all:
import torch
x = torch.randn(10, 10, device='cuda')
print(x)