在910A NPU上运行torch-npu失败
收藏回复举报
在910A NPU上运行torch-npu失败
t('forum.solved') 已解决
发表于2024-08-14 11:45:15
0 查看

环境配置

我有一个裸金属服务器,配备了8张910A的NPU,对应安装了以下软件:

类别版本
OSEulerOS 2.0 SP8
Driver23.0.0
Firmware7.1.0.3.220
CANN-toolkoit8.0.RC3.alpha001
CANN-kernels8.0.RC3.alpha001
Python3.10

true

安装torch和torc-npu

参考配套CANN的torch版本:安装torch 2.4, torch-npu2.4.0-rc1 true

# 清华源
 pip install -i https://pypi.tuna.tsinghua.edu.cn/simple torch==2.4.0
 
 pip install -i https://pypi.tuna.tsinghua.edu.cn/simple numpy
 
 
 wget https://gitee.com/ascend/pytorch/releases/download/v6.0.rc3.alpha001-pytorch2.4.0/torch_npu-2.4.0rc1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
 
 pip install -i https://pypi.tuna.tsinghua.edu.cn/simple torch_npu-2.4.0rc1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

验证:

python3 -c "import torch;import torch_npu; a = torch.randn(3, 4).npu(); print(a + a);"

报错如下: true

对应的安装包如下:

Package           Version
----------------- --------
ascendebug        0.1.0
auto-tune         0.1.0
dataflow          0.0.1
filelock          3.15.4
fsspec            2024.6.1
hccl              0.1.0
hccl-parser       0.1
Jinja2            3.1.4
llm-datadist      0.0.1
MarkupSafe        2.1.5
mpmath            1.3.0
msadvisor         1.0.0
networkx          3.3
numpy             2.0.1
op-compile-tool   0.1.0
op-gen            0.1
op-test-frame     0.1
opc-tool          0.1.0
pip               24.2
PyYAML            6.0.2
schedule-search   0.0.1
setuptools        72.1.0
sympy             1.13.2
te                0.4.0
torch             2.4.0
torch-npu         2.4.0rc1
typing_extensions 4.12.2
wheel             0.43.0

请问这个是什么原因导致的?这些最新的CANN、torch和torch-npu是否可以在910A卡上安装运行?

我要发帖子