FileNotFoundError: Could not find module "...\c10.dll"

Trying to run my code after installing torch and receive the following error:

Traceback (most recent call last):
File “C:\Users\ויקי\Desktop\ABCD_project\gordon_correlations_algorithms\”, line 5, in
import test
File “C:\Users\ויקי\Desktop\ABCD_project\gordon_correlations_algorithms\”, line 10, in
import torch
File “C:\python38\lib\site-packages\”, line 81, in
File “C:\python38\lib\”, line 369, in init
self._handle = _dlopen(self._name, mode)
FileNotFoundError: Could not find module ‘C:\python38\lib\site-packages\torch\lib\c10.dll’. Try using the full path with constructor syntax.

c10.dll exists in the folder.
Python version: 3.8.0 64 bit
Windows 10 64 bit
pytorch install: pip install torch==1.5.1+cpu torchvision==0.6.1+cpu -f

Can you help me please?

Have you installed VS2019 redist?


This solved the problem. Thank you!

How did you solved ?

Genius solution. However I don’t understand how it’s related to pytorch not finding a file.

Just installed the VS2019 redist

Good afternoon, I still have this problem, installed pytorch using conda, for CPU. Anybody know how to solve this? The c10.dll file surely is in the specified folder.