Thanks man ! I finally got it.
The versions are identical, I also ran the line
next(iter(data_loader))
and it did raise the same error.
Weirdly enough, the problem seems to be related to how I import transforms…
When I use this :
import torchvision.transforms as T
it raises an error, but when I replaced it with :
import transforms as T
It worked fine.
No idea why!