摘要
当前卷积神经网络模型的训练和分发流程中,云端拥有充足的计算资源和数据集,但难以应对边缘场景中碎片化的需求。边缘侧能够直接进行模型的训练和推理,但难以直接使用云端按照统一规则训练的卷积神经网络模型。针对在边缘侧资源受限的情况下,卷积神经网络算法进行模型压缩的训练和推理有效性低的问题,首先,提出了一种基于云边协同的模型分发和训练框架,该框架可以结合云端和边缘侧各自的优势进行模型再训练,满足边缘对指定识别目标、指定硬件资源和指定精度的需求。其次,基于云边协同框架训练的思路,对知识蒸馏技术进行改进,提出了新的基于Logits和基于Channels两种子类知识蒸馏方法(SLKD和SCKD),云服务端先提供具有多目标识别的模型,而后通过子类知识蒸馏的方法,在边缘侧将模型重新训练为一个可以在资源受限的场景下部署的轻量化模型。最后,在CIFAR-10公共数据集上,对联合训练框架的有效性和两种子类蒸馏算法进行了验证。实验结果表明,在压缩比为50%的情况下,相比具有全部分类的模型,所提模型推理准确率得到了显著的提升(10%~11%);相比模型的重新训练,通过知识蒸馏方法训练出的模型精度也有显著提高,并且压缩比率越高,模型精度提升越明显。
In the current training and distribution process of convolutional neural network models,the cloud has sufficient computing resources and datasets,but it is difficult to cope with the demand for fragmentation in edge scenes.The edge side can directly train and infer models,but it is difficult to directly use the convolutional neural network models trained in the cloud according to unified rules.To address the issue of low training and inference effectiveness of convolutional neural network algorithms for model compression in the context of limited resources on the edge side,a model distribution and training framework based on cloud edge collaboration is firstly proposed.This framework can combine the advantages of both cloud and edge sides for model retraining,meeting the edge's requirements for specified recognition targets,specified hardware resources,and specified accuracy.Secondly,based on the training approach of the cloud edge collaborative framework,new subclass knowledge distillation methods based on logits and channels(SLKD and SCKD)are proposed to improve knowledge distillation technology.The cloud server first provides a model with multi-target recognition,and then through the subclass knowledge distillation method,the model is retrained on the edge side into a lightweight model that can be deployed in resource limited scenarios.Finally,the effectiveness of the joint training framework and the two subcategory distillation algorithm are validated on the CIFAR-10 dataset.The experimental results show that at a compression ratio of 50%,the inference accuracy is improved by 10%to 11%compared to models with full classification.Compared to the retraining of the model,the accuracy of the model trained through knowledge distillation method has also been greatly improved,and the higher the compression ratio,the more significant the improvement in model accuracy.
作者
孙婧
王晓霞
SUN Jing;WANG Xiaoxia(Department of Intelligent Science and Information Law,East China University of Political Science and Law,Shanghai 201620,China;School of Computer Science and Engineering,Northwest Normal University,Lanzhou,730070,China)
出处
《计算机科学》
CSCD
北大核心
2024年第5期313-320,共8页
Computer Science
基金
国家自然科学基金(12161080)。
关键词
云边协同
深度学习
知识蒸馏
模型压缩
特征提取
Cloud edge collaboration
Deep learning
Knowledge distillation
Model compression
Feature extraction