acl.himpi.vdec_get_protocol_param

c函数原型

hi_s32 hi_mpi_vdec_get_protocol_param(hi_vdec_chn chn, hi_vdec_protocol_param* protocol_param);

Python函数

protocol_param, ret = acl.himpi.vdec_get_protocol_param(chn)

函数功能

获取协议相关的内存分配通道参数,如slice、pps(Picture Parameter Set)、sps(Sequence Parameter Set)等。

Atlas 200/300/500 推理产品,当前版本不支持该接口。

Atlas 训练系列产品,当前版本不支持该接口。

输入说明

chn:int,解码通道号。
  • Atlas 推理系列产品,该参数的取值范围:[0, 256),JPEGD功能和VDEC功能共用通道,且通道总数最多256。
  • Atlas A2训练系列产品/Atlas 800I A2推理产品,该参数的取值范围:[0, 256),JPEGD功能和VDEC功能共用通道,且通道总数最多256,其中,JPEGD解码通道总数最多256,VDEC解码通道总数最多32。
  • Atlas 200I/500 A2推理产品,该参数的取值范围:[0, 128),JPEGD功能和VDEC功能共用通道,且通道总数最多128。

返回值说明

protocol_param:dict,解码通道参数字典,具体请参见hi_vdec_protocol_param

ret:int,错误码。

约束说明

必须保证通道已创建,否则会返回错误码“HI_ERR_VDEC_UNEXIST”