Struct Qnn_FloatBlockEncoding_t

Struct Documentation

struct Qnn_FloatBlockEncoding_t

A struct to express float block quantization parameters. A tensor is divided into blocks of size blockSize, where blockSize is an array of length rank.

Note

num of floatScaleOffsets (i.e. num of blocks) must be == ceil(dimensions[0]/blockSize[0])*ceil(dimensions[1]/blockSize[1]) … …. *ceil(dimensions[rank-1] / blockSize[rank-1]).

Public Members

uint32_t *blockSize

Dimensions of the block in number of tensor elements. Pointer to an array of size RANK(Weight). Each element specifies the size along the corresponding dimension

Qnn_FloatScaleOffset_t *floatScaleOffset

Array of size numBlocks of scale offset pairs.