Function: get_aipp_type

Applicability

Product

Supported (√/x)

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

Function Usage

Obtains the AIPP type (dynamic or static) supported by an input of a model, and the index of the input configured with dynamic AIPP.

Prototype

  • C Prototype
    1
    aclError aclmdlGetAippType(uint32_t modelId, size_t index, aclmdlInputAippType *type, size_t *dynamicAttachedDataIndex)
    
  • Python Function
    1
    type, dynamic_attached_data_index, ret = acl.mdl.get_aipp_type(model_id, index)
    

Parameter Description

Parameter

Description

model_id

Int, model ID.

You can obtain the model ID after the model is successfully loaded by calling the following APIs:

index

Int, index of the model input.

Return Value Description

Return Value

Description

type

Int, AIPP type of the specified model input. For details, see aclmdlInputAippType.

dynamic_attached_data_index

Int, returned information.

  • When type is not ACL_DATA_WITH_DYNAMIC_AIPP, 0xFFFFFFFF is returned, indicating a failure.
  • When type is ACL_DATA_WITH_DYNAMIC_AIPP, the index of the input configured with dynamic AIPP is returned.

ret

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

Reference

For the API call example, see Dynamic AIPP (Multiple Dynamic AIPP Inputs).