vpc_set_chn_workspace

Applicable Products

Product

Supported (√/x)

Ascend 950PR&950DT products

√

Atlas A3 products

√

Atlas A2 products

√

Atlas training products

x

Atlas inference products

x

Atlas 200I/500 A2 inference products

√

Description

When this API is called, the system allocates an internal temporary buffer based on the maximum width and height of the input and output images. The allocated buffer is automatically released when the channel is destroyed.

Prototype

  • C Prototype
    1
    hi_s32 hi_mpi_vpc_set_chn_workspace(hi_vpc_chn chn, hi_vpc_workspace_param *workspace_param, hi_u32 param_cnt)
    
  • Python Function
    1
    ret = acl.himpi.vpc_set_chn_workspace(chn, workspace_param, param_cnt)
    

Parameters

Parameter

Description

chn

Int, channel ID for image processing.

workspace_param

List, array with elements of hi_vpc_workspace_param dictionary.

The value of hi_vpc_workspace_param["func"] needs to be set based on the used remapping or affine transformation function.

If the remapping and affine transformation functions both are involved in an app, the hi_vpc_workspace_param array can contain two elements. Set hi_vpc_workspace_param["func"] of two elements to REMAP and AFFINE, respectively.

param_cnt

Int, array length, which must be the same as the length of the workspace_param array.

Return Values

Return Value

Description

ret

Int, error code.

Constraints

For each channel, this API can be set only once and cannot be modified later.