CANN8.5.0,在910A[Atlas 800(型号9000)]/ARM上,存在兼容性问题
收藏回复举报
CANN8.5.0,在910A[Atlas 800(型号9000)]/ARM上,存在兼容性问题
t('forum.solved') 已解决
发表于2026-02-05 10:34:12
0 查看

问题详细描述

            

环境信息CANN 8.5.0/HDK 25.5.0/910A【Atlas 800(型号9000)】/EulerOS 2.15(ARM)/Python 3.11.4

问题总结如下

在同一NPU容器中:

安装使用mindspore 2.7.2,执行mindspore的基础NPU能力测试代码,失败,见日志1和测试代码1.

安装使用mindspore 2.8.0,执行import mindspore,报错:Segmentation fault (core dumped),见日志2

在同一CPU容器中:

安装使用mindspore 2.7.2,使用mindspore的CPU能力,正常

安装使用mindspore 2.8.0,使用mindspore的CPU能力,正常

另,在910B上(其他环境信息都一样),mindspore 2.7.2/2.8.0都执行正常

详细的环境信息描述

环境信息:CANN 8.5.0/HDK 25.5.0/Atlas 800(型号9000)/EulerOS 2.15(ARM)/Python 3.11.4

其他辅助信息

版本信息

当前使用MindSpore 2.7.2和MindSpore 2.8.0两个版本。

日志

日志1:

/***/.local/lib/python3.11/site-packages/numpy/core/getlimits.py:549: UserWarning: The value of the smallest subnormal for <class 'numpy.float64'> type is zero.

  setattr(self, word, getattr(machar, word).flat[0])

/***/.local/lib/python3.11/site-packages/numpy/core/getlimits.py:89: UserWarning: The value of the smallest subnormal for <class 'numpy.float64'> type is zero.

  return self._float_to_str(self.smallest_subnormal)

/***/.local/lib/python3.11/site-packages/numpy/core/getlimits.py:549: UserWarning: The value of the smallest subnormal for <class 'numpy.float32'> type is zero.

  setattr(self, word, getattr(machar, word).flat[0])

/***/.local/lib/python3.11/site-packages/numpy/core/getlimits.py:89: UserWarning: The value of the smallest subnormal for <class 'numpy.float32'> type is zero.

  return self._float_to_str(self.smallest_subnormal)

=============================ms, cann 8.5 debug==============================================

Traceback (most recent call last):

  File "/***/msnpu.py", line 9, in <module>

    context.set_context(mode=context.GRAPH_MODE, device_target="Ascend")

  File "/***/.local/lib/python3.11/site-packages/mindspore/_checkparam.py", line 1397, in wrapper

    return func(*args, **kwargs)

           ^^^^^^^^^^^^^^^^^^^^^

  File "/***/.local/lib/python3.11/site-packages/mindspore/context.py", line 1538, in set_context

    ctx.set_device_target(kwargs['device_target'])

  File "/***/.local/lib/python3.11/site-packages/mindspore/context.py", line 490, in set_device_target

    self.set_param(ms_ctx_param.device_target, target)

  File "/***/.local/lib/python3.11/site-packages/mindspore/context.py", line 185, in set_param

    self._context_handle.set_param(param, value)

RuntimeError: Unsupported device target Ascend. This process only supports one of the ['CPU']. Please check whether the Ascend environment is installed and configured correctly, and check whether current mindspore wheel package was built with "-e Ascend". For details, please refer to "Device load error message".

----------------------------------------------------

- Device load error message:

----------------------------------------------------

Load dynamic library: libmindspore_ascend.so.2 failed. /usr/local/Ascend/cann/lib64/libnnopbase.so: undefined symbol: rtGetSocSpec

Load dynamic library: libmindspore_ops_ascend.so failed. /usr/local/Ascend/cann/lib64/libhccl.so: undefined symbol: HcclRankGraphGetRankSizeByLayer

----------------------------------------------------

- C++ Call Stack: (For framework developers)

----------------------------------------------------

mindspore/core/utils/ms_context.cc:279 SetDeviceTargetFromInner

日志2:

>>> import mindspore

Segmentation fault (core dumped)

测试代码

测试代码1:

import numpy as np

import mindspore.context as context

import mindspore.nn as nn

from mindspore import Tensor

from mindspore.ops import operations as P

print("=============================ms, cann 8.5 debug==============================================")

context.set_context(mode=context.GRAPH_MODE, device_target="Ascend")



class Net(nn.Cell):

    def __init__(self):

        super(Net, self).__init__()

        self.add = P.Add()

    def construct(self, x_, y_):

        return self.add(x_, y_)



x = np.ones([1, 3, 3, 4]).astype(np.float32)

y = np.ones([1, 3, 3, 4]).astype(np.float32)



if __name__ == '__main__':

    add = Net()

    output = add(Tensor(x), Tensor(y))

    print(x)

    print(y)

    print(output.asnumpy())

本帖最后由 匿名用户2026/02/06 09:20:50 编辑

我要发帖子