Quantization Configuration Parameters
Description |
QAT enable |
|---|---|
Type |
bool |
Value |
true or false |
Command-Line Options |
|
Recommended |
true |
Required/Optional |
This function is optional. |
Description |
Activation quantization configuration |
|---|---|
Type |
dict |
Value |
- |
Command-Line Options |
Includes the following parameters:
|
Recommended Value |
- |
Required/Optional |
This function is optional. |
Description |
Weight quantization configuration |
|---|---|
Specification |
dict |
Value |
- |
Command-Line Options |
Includes the following parameters:
|
Recommended Value |
- |
Required/Optional |
This function is optional. |
Description |
Quantization algorithm |
|---|---|
Type |
string |
Value |
- |
Command-Line Options |
|
Recommended Value |
arq_retrain |
Required/Optional |
Optional |
Description |
Whether to use different quantization factors for each channel |
|---|---|
Specification |
bool |
Value |
true or false |
Command-Line Options |
|
Recommended |
true |
Required/Optional |
This function is optional. |
Description |
Batch count used for quantization. |
|---|---|
"Type" |
int |
The options are as follows: |
Greater than 0 |
Command-line options |
Defaults to 1. You are advised to keep the calibration dataset size within 50 images. Calculate batch_num based on batch_size as follows: batch_num x batch_size = Calibration dataset size batch_size indicates the number of images per batch. |
Recommended Value |
1 |
Required/Optional |
This function is optional. |
Description |
Fixed lower bound switch for the activation quantization algorithm |
|---|---|
Type |
bool |
Value |
true or false |
Parameter Description |
|
Recommended Value |
Do not include this parameter. |
Required/Optional |
This function is optional. |
Description |
Upper bound for the activation quantization algorithm |
|---|---|
Type |
float |
Value |
clip_max>0 Find the maximum max based on the distribution of the activation values at different layers. The recommended value range is [0.3 x max, 1.7 x max]. |
Command-Line Options |
If this parameter is included, the upper bound of the clipping-based activation quantization algorithm is fixed. If this parameter is not included, the upper bound is learned using the IFMR algorithm. |
Recommended Value |
Do not include this parameter. |
Required/Optional |
This function is optional. |
Description |
Lower bound for the activation quantization algorithm |
|---|---|
Type |
float |
Value |
clip_min<0 Find the minimum min based on the distribution of the activation values at different layers. The recommended value range is [0.3 x min, 1.7 x min]. |
Command-Line Options |
If this parameter is included, the lower bound of the clipping-based activation quantization algorithm is fixed. If this parameter is not included, the lower bound is learned using the IFMR algorithm. |
Recommended Value |
Do not include this parameter. |
Required/Optional |
This function is optional. |
Description |
Quantization bit width select |
|---|---|
Type |
string |
Value |
Currently, only INT8 (default) is supported. |
Command-Line Options |
Selects the quantization bit width during quantization. |
Recommended Value |
- |
Required/Optional |
This function is optional. |