ModuleNotFoundError: No module named 'torch._six'----please help me

Torch version: 2.0.0+cu118
Cuda version: 11.8
Device name: NVIDIA GeForce RTX 3050 Ti Laptop GPU

Unfortunately, you didn’t share any information where this issue is raised from so I assume from a 3rd party library. If so, note that torch._six was removed in this commit and is not supported anymore since also Python 2.x is dead.

Had the same issue. The issue in my case was from a later version of timm. I then downgraded it to use timm==0.6.13.
So, there’s no one works for all solution, but you will have to see where the error originated from and fix the version of the package that it occurs from.

For me, the source of this error was an old timm install. pip install --force-reinstall timmfixed it.