arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2304.09785cs.CV
收藏

改进基于任务损失引导的Lp度量的目标检测后训练量化

Improving Post-Training Quantization on Object Detection with Task Loss-Guided Lp Metric

Huazhong University of Science & Technology(华中科技大学);Houmo AI(后摩智能)

Lin Niu, Jiawei Liu, Zhihang Yuan, Dawei Yang, Xinggang Wang, Wenyu Liu

AI总结:

针对目标检测后训练量化中固定Lp度量参数p导致精度下降的问题,提出DetPTQ框架,利用任务损失自适应分配各层p值,显著提升2D和3D检测器的量化性能。

摘要:

目标检测网络的高效推理是边缘设备上的一个主要挑战。后训练量化(PTQ)直接将全精度模型转换为低比特宽度,是降低模型推理复杂度的一种有效且便捷的方法。但将其应用于目标检测等复杂任务时,会遭受严重的精度下降。PTQ通过不同的度量优化量化参数,以最小化量化的扰动。量化前后特征图的p范数距离(Lp)被广泛用作评估扰动的度量。针对目标检测网络的特殊性,我们观察到Lp度量中的参数p会显著影响其量化性能。我们指出,使用固定的超参数p无法达到最优的量化性能。为缓解此问题,我们提出了一个框架DetPTQ,通过目标检测输出损失(ODOL)为不同层分配不同的p值进行量化,该损失代表目标检测的任务损失。DetPTQ采用基于ODOL的自适应Lp度量来选择最优量化参数。实验表明,我们的DetPTQ在2D和3D目标检测器上均显著优于最先进的PTQ方法。例如,在RetinaNet-ResNet18上,采用4比特权重和4比特激活时,我们实现了31.1/31.7(量化/全精度)的mAP。

英文摘要:

Efficient inference for object detection networks is a major challenge on edge devices. Post-Training Quantization (PTQ), which transforms a full-precision model into low bit-width directly, is an effective and convenient approach to reduce model inference complexity. But it suffers severe accuracy drop when applied to complex tasks such as object detection. PTQ optimizes the quantization parameters by different metrics to minimize the perturbation of quantization. The p-norm distance of feature maps before and after quantization, Lp, is widely used as the metric to evaluate perturbation. For the specialty of object detection network, we observe that the parameter p in Lp metric will significantly influence its quantization performance. We indicate that using a fixed hyper-parameter p does not achieve optimal quantization performance. To mitigate this problem, we propose a framework, DetPTQ, to assign different p values for quantizing different layers using an Object Detection Output Loss (ODOL), which represents the task loss of object detection. DetPTQ employs the ODOL-based adaptive Lp metric to select the optimal quantization parameters. Experiments show that our DetPTQ outperforms the state-of-the-art PTQ methods by a significant margin on both 2D and 3D object detectors. For example, we achieve 31.1/31.7(quantization/full-precision) mAP on RetinaNet-ResNet18 with 4-bit weight and 4-bit activation.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑