Then try this.
-m pip install torch==2.2.0 torchvision --extra-index-url https://download.pytorch.org/whl/cu121
Perhaps.
-m pip install torch torchvision --extra-index-url https://download.pytorch.org/whl/cu121
Come to think of it, if you just want to use Stable Diffusion, it’s faster and more reliable to download the WebUI Forge all-in-one package below than to manually install all the stuff.