mindspore.hal.get_arch_list

mindspore.hal.get_arch_list(device_target=None)[source]

Get the architecture list this MindSpore was compiled for.

Note

If device_target is not specified, get the device name of the current backend set by context.

Parameters

device_target (str, optional) – The device name of backend, should be one of “CPU”, “GPU” and “Ascend”.

Returns

str for GPU. None for Ascend and CPU.

Examples

>>> import mindspore as ms
>>> device_target = ms.context.get_context("device_target")
>>> print(ms.hal.get_arch_list(device_target))