FilesLast commitLast update
10 days ago
1 month ago
1 month ago
8 days ago
4 months ago
8 days ago
8 days ago
5 days ago
8 days ago
1 month ago
17 days ago
README

Quantize

English | 简体中文

Applicable Products

Product Support
Ascend 950PR&950DT products √
Atlas A3 products √
Atlas A2 products √
Atlas 200I/500 A2 inference products ×
Atlas inference products √
Atlas training products √

Function

  • Operator function: Performs quantization processing on the input tensor x.

  • Formula:

    out=round((x/scales)+zeroPoints)out=round((x/scales)+zeroPoints)

Parameters

Parameter name Input/Output/Attribute Description Data type Data format
x Input x in the formula FLOAT, FLOAT16, BFLOAT16 ND
scales Input scales in the formula FLOAT, BFLOAT16 ND
zero_points Input zeroPoints in the formula FLOAT, INT32, INT8, UINT8, BFLOAT16 -
y Output Output tensor out in the formula INT8, UINT8, INT32, HIFLOAT8, FLOAT8_E5M2, FLOAT8_E4M3FN ND

Invocation Description

Invocation method Sample code Description
aclnn API test_aclnn_quantize.cpp Invoke the operator through the aclnnQuantize.md API.