[Quantization] Add new PaddleSeg models quantization support. (#953)

* Fix links in readme

* Fix links in readme

* Update PPOCRv2/v3 examples

* Update auto compression configs

* Add neww quantization  support for paddleclas model

* Update quantized Yolov6s model download link

* Improve PPOCR comments

* Add English doc for quantization

* Fix PPOCR rec model bug

* Add  new paddleseg quantization support

* Add  new paddleseg quantization support

* Add  new paddleseg quantization support

* Add  new paddleseg quantization support
This commit is contained in:
yunyaoXYY
2022-12-25 16:33:57 +08:00
committed by GitHub
parent 2431890f73
commit 2d3d941372
5 changed files with 120 additions and 3 deletions

View File

@@ -0,0 +1,38 @@
Global:
model_dir: ./Unet_cityscapes_without_argmax_infer/
format: paddle
model_filename: model.pdmodel
params_filename: model.pdiparams
qat_image_path: ./train_stuttgart
ptq_image_path: ./train_stuttgart
input_list: ['x']
qat_preprocess: ppseg_cityscapes_qat_preprocess
ptq_preprocess: ppseg_cityscapes_ptq_preprocess
qat_batch_size: 2
Distillation:
alpha: 1.0
loss: l2
node:
- conv2d_37.tmp_1
QuantAware:
onnx_format: True
quantize_op_types:
- conv2d
- depthwise_conv2d
TrainConfig:
epochs: 10
eval_iter: 180
learning_rate: 0.0005
optimizer_builder:
optimizer:
type: SGD
weight_decay: 4.0e-05
PTQ:
calibration_method: 'avg' # option: avg, abs_max, hist, KL, mse
skip_tensor_list: None