Function: get_device_capability

Applicable Products

Product

Supported (√/x)

Ascend 950PR/Ascend 950DT

√

Atlas A3 training products/Atlas A3 inference products

√

Atlas A2 training products/Atlas A2 inference products

√

Atlas training products

√

Atlas inference products

√

Atlas 200I/500 A2 inference products

√

Description

Queries whether the device feature is supported.

Prototype

  • C Prototype
    aclError aclrtGetDeviceCapability(int32_t deviceId, aclrtDevFeatureType devFeatureType, int32_t *value)
  • Python Function
    1
    value, ret = acl.rt.get_device_capability(device_id, dev_feature_type)
    

Parameters

Parameter

Description

device_id

Int, device ID.

dev_feature_type

Int, enumerated value. For details, see aclrtDevFeatureType.

Return Values

Return Value

Description

ret

Int, error code. 0 on success; else, failure.

value

Int, whether the feature is supported.

  • 0: unsupported
  • 1: supported