我正在try 使用下面的任一命令安装pytorch,但我收到了很多错误.我只使用Windows CPU.

conda install pytorch::pytorch

or 
conda install pytorch torchvision torchaudio cpuonly -c pytorch

其中一些错误是

CondaVerificationError: The package for pytorch located at C:\Users\test\miniconda3\pkgs\pytorch-2.2.1-py3.10_cpu_0
appears to be corrupted. The path 'Lib/site-packages/torchgen/static_runtime/gen_static_runtime_ops.py'
specified in the package manifest cannot be found.

CondaVerificationError: The package for pytorch located at C:\Users\test\miniconda3\pkgs\pytorch-2.2.1-py3.10_cpu_0
appears to be corrupted. The path 'Lib/site-packages/torchgen/static_runtime/generator.py'
specified in the package manifest cannot be found.

CondaVerificationError: The package for pytorch located at C:\Users\test\miniconda3\pkgs\pytorch-2.2.1-py3.10_cpu_0
appears to be corrupted. The path 'Lib/site-packages/torchgen/utils.py'
specified in the package manifest cannot be found.

CondaVerificationError: The package for pytorch located at C:\Users\test\miniconda3\pkgs\pytorch-2.2.1-py3.10_cpu_0
appears to be corrupted. The path 'Lib/site-packages/torchgen/yaml_utils.py'
specified in the package manifest cannot be found.

CondaVerificationError: The package for pytorch located at C:\Users\test\miniconda3\pkgs\pytorch-2.2.1-py3.10_cpu_0
appears to be corrupted. The path 'Scripts/convert-caffe2-to-onnx-script.py'
specified in the package manifest cannot be found.

CondaVerificationError: The package for pytorch located at C:\Users\test\miniconda3\pkgs\pytorch-2.2.1-py3.10_cpu_0
appears to be corrupted. The path 'Scripts/convert-onnx-to-caffe2-script.py'
specified in the package manifest cannot be found.

CondaVerificationError: The package for pytorch located at C:\Users\test\miniconda3\pkgs\pytorch-2.2.1-py3.10_cpu_0
appears to be corrupted. The path 'Scripts/torchrun-script.py'
specified in the package manifest cannot be found.

推荐答案

您的一个包裹似乎已损坏.您可以try 从缓存中清除程序包并重新安装pytorch:

conda clean -p

Python相关问答推荐

如何在msgraph.GraphServiceClient上进行身份验证?

将特定列信息移动到当前行下的新行

如何使用Python将工作表从一个Excel工作簿复制粘贴到另一个工作簿?

输出中带有南的亚麻神经网络

使用@ guardlasses. guardlass和注释的Python继承

删除字符串中第一次出现单词后的所有内容

我如何使法国在 map 中完全透明的代码?

Python—从np.array中 Select 复杂的列子集

组/群集按字符串中的子字符串或子字符串中的字符串轮询数据框

调用decorator返回原始函数的输出

UNIQUE约束失败:customuser. username

Python Pandas—时间序列—时间戳缺失时间精确在00:00

在Python中从嵌套的for循环中获取插值

如何设置nan值为numpy数组多条件

修改.pdb文件中的值并另存为新的

将像素信息写入文件并读取该文件

Django更新视图未更新

如何在不不断遇到ChromeDriver版本错误的情况下使用Selify?

根据边界点的属性将图划分为子图

如何计算Pandas 中具有特定条件的行之间的天差