Function: get_cann_attribute

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 operating environment supports the specified CANN feature.

Prototype

  • C Prototype
    1
    aclError aclGetCannAttribute(aclCannAttr cannAttr, int32_t *value)
    
  • Python Function
    1
    value, ret = acl.get_cann_attribute(cann_attr)
    

Parameters

Parameter

Description

cann_attr

Int, the enumerated value of the feature list. One item can be specified for each query. For details, see aclCannAttr.

Return Values

Return Value

Description

value

Int, whether the function is supported.

  • 1: supported
  • 0: unsupported

ret

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