2.4K Star 8.2K Fork 4.4K

GVPMindSpore / mindspore

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
mindspore.hal.is_available.rst 473 Bytes
一键复制 编辑 原始数据 按行查看 历史
ZPaC 提交于 2024-01-18 09:20 . Add hal device doc

mindspore.hal.is_available

.. py:function:: mindspore.hal.is_available(device_target)

    查询指定后端是否可用。
    若指定后端是可用的,那么所有依赖库需要被成功加载。

    参数:
        - **device_target** (str) - 用户指定的后端类型,必须是 ``"CPU"`` , ``"GPU"`` 以及 ``"Ascend"`` 的其中一个。


    返回:
        bool,指定后端在当前MindSpore包中是否可用。
Python
1
https://gitee.com/mindspore/mindspore.git
git@gitee.com:mindspore/mindspore.git
mindspore
mindspore
mindspore
master

搜索帮助