PaddleSlim icon indicating copy to clipboard operation
PaddleSlim copied to clipboard

yolo post training quantization

Open junghyun-avikus opened this issue 1 year ago • 1 comments

Hi, I was following along the post training quantization, and I am wondering if given examples codes can convert yolov5m as well.

The given yaml for yolov5 is yolov5s_ptq.yaml, so is the code specific to yolov5s only?

When I ran post_quant on the yolov5m onnx, directly exported from the ultralytics pretrained model on coco, I get the following error.

[WARNING] Incomplete symbolic shape inference 2023-03-24 17:30:56,985-WARNING: [ShapeInferenceError] (op_type:Split, node name: x2paddle__model_24_Split_output_0): [ShapeInferenceError] Inferred shape and existing shape differ in dimension 4: (2) vs (28) 2023-03-24 17:30:56,986-ERROR: x2paddle threw an exception, you can ask for help at: https://github.com/PaddlePaddle/X2Paddle/issues

Do I need to make some modifications in the code, or is it the environment that I am running on.

The environments are the followings: Paddle 2.4.1 cuda 11.7 PaddleSlim 2.4 x2paddle 1.3.9

junghyun-avikus avatar Mar 24 '23 08:03 junghyun-avikus

Sorry for not replying in time. It seems that there is something wrong with ShapeInference. Can you provide more information about the code and model you use?

XGZhang11 avatar Feb 06 '24 06:02 XGZhang11