I installed PyTorch by opening a Windows command prompt. In it, I pasted, "pip install torch==1.4.0+cpu torchvision==0.5.0+cpu -f https://download.pytorch.org/whl/torch_stable.html” , (as I said in my original post). The Windows PATH commands would then cause pip to run in the Python/Python38/Scripts folder. It successfully(?) installed PyTorch and TorchVision in Python/Python38/Lib/sitepackages, in the same folder as the sci-py, numpy, sklearn packages.
I had this problem when I only had Python 3.6.1 installed. I reinstalled PyTorch many times. I then installed Python 3.8, to see if PyTorch would work with that, and I have the same problem. I start Python from the Windows IDLE program which is installed with Python. But even if I start Python from a Windows command prompt and type “import torch,” I get the same failure.
I’m not sure what you mean when you say, “create a new environment,” or “your current working directory is inside the pytorch folder.” But, my Python file structure looks good to me.It got me through 20 data science courses from DataCamp, and books like “Deep Learning from Scratch.”