安装torchtext
(pytorch) D:\Study\Python\pythonProject>pip install torchtext -i https://pypi.tuna.tsinghua.edu.cn/simple
如图
ERROR: pip’s dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
torchvision 0.11.1 requires torch1.10.0, but you have torch 1.10.1 which is incompatible.
torchaudio 0.10.0 requires torch1.10.0, but you have torch 1.10.1 which is incompatible.
最后没办法,重新装pytorch以及配套的torchvision和torchaudio
conda install pytorch torchvision torchaudio cpuonly -c pytorch
解决了