Hello, I can’t import torch and here is my error. I don’t know what is wrong with it.
import torch
File "C:\Users\Tsai\anaconda3\envs\tf\lib\site-packages\torch\__init__.py", line 688, in <module>
from torch import multiprocessing as multiprocessing
File "C:\Users\Tsai\anaconda3\envs\tf\lib\site-packages\torch\multiprocessing\__init__.py", line 18, in <module>
from .reductions import init_reductions
File "C:\Users\Tsai\anaconda3\envs\tf\lib\site-packages\torch\multiprocessing\reductions.py", line 7, in <module>
from multiprocessing.util import register_after_fork
ModuleNotFoundError: No module named 'multiprocessing.util'; 'multiprocessing' is not a package
It seems you are hitting the same issue as described here which seems to be solved after reinstalling PyTorch in a new environment, if I’m not misunderstanding the EDIT.
No, I built a virtual environment and reinstall torch in it, and the problem still exist.
Can you provide the related packages final version combination for me? Thank you.
Including python version, torch, torchvision, pytorch