I’m using python 3.7.10 with torch 1.81 and torchvision 0.9.1 in my machine and while importing dset from torchvision.dataset this error shows up:
Traceback (most recent call last):
  File "train.py", line 23, in <module>
    from dataloader import load_data
  File "/home/rdb/Prithviraj/Image-Restoration-in-Occluded-Images-using-GANs/dataloader.py", line 3, in <module>
    import torchvision.datasets as dset
  File "/home/rdb/.local/lib/python3.7/site-packages/torchvision/__init__.py", line 7, in <module>
    from torchvision import datasets
  File "/home/rdb/.local/lib/python3.7/site-packages/torchvision/datasets/__init__.py", line 6, in <module>
    from .mnist import MNIST, EMNIST, FashionMNIST, KMNIST, QMNIST
  File "/home/rdb/.local/lib/python3.7/site-packages/torchvision/datasets/mnist.py", line 11, in <module>
    import lzma
  File "/usr/local/lib/python3.7/lzma.py", line 27, in <module>
    from _lzma import *
ModuleNotFoundError: No module named '_lzma'

This means that the torchvision I have is broken or buggy. Can someone suggest a fix for this error.
If u need a demo code to run then please use this 2 tutorial .
Any help would be great!!