Why spyder shows:No moudle named 'torch'

File “C:/Users/CT/Desktop/TIAN/VasNet-pytorch-code/src/train-new_dataloader.py”, line 2, in
import torch

ModuleNotFoundError: No module named ‘torch’

R0QFE{CQR3}3ESR$T56DYYA !

Most likely you are starting spyder in another environment than the one which is used in your terminal.
Make sure the env is correctly activated before starting the IDE.

Thank you for your reply!
It seemed that I didn’t run the spyder from the ‘pytorch_gpu’ in the Anaconda Navigator.
Now i am installing the spyder in pytorch_gpu.