I am well aware similar questions have been asked at least twice, but none of the answers seams to solve the issue at hand
My configuration
Windows 10.0.18363, Anaconda 4.8.5, Cuda 10.1.243
conda env create -n torch -y python 3.7
conda activate torch
conda install conda -y
conda install pytorch torchvision cudatoolkit=10.2 -c pytorch -y
Here's the bug
python -c "import torch"
Traceback (most recent call last): File "<stdin>", line 1, in <module> ModuleNotFoundError: No module named 'torch'
What I tried
Verifying python and conda
where python
C:\ProgramData\Anaconda3\envs\torch\python.exe C:\ProgramData\Anaconda3\python.exe C:\csvn\Python25\python.exe
python -c "import site; print(site.getsitepackages())"
['C:\ProgramData\Anaconda3', 'C:\ProgramData\Anaconda3\lib\site-packages']
conda update -n base -y conda
conda update --all -y
conda init
... No action taken.
Verifying the torch installation
conda list | findstr torch
_pytorch_select 0.1 cpu_0 pytorch 1.6.0 cpu_py37h538a6d7_0 torchvision 0.7.0 py37_cu102 pytorch