module not found error: no module named ‘_lzma’ when import torchvision using pyenv in M1 Mac
It is because you didn’t have XZ Utils in your mac when you compiled your python. In my case, uninstall my current python version and install xz using homebrew and reinstall the python version that I removed.