电子学报 ›› 2022, Vol. 50 ›› Issue (2): 295-304.DOI: 10.12263/DZXB.20210453

• 学术论文 • 上一篇    下一篇

基于样本对元学习的小样本图像分类方法

李维刚, 甘平, 谢璐, 李松涛   

  1. 武汉科技大学冶金自动化与检测技术教育部工程研究中心,湖北 武汉 430081
  • 收稿日期:2021-04-09 修回日期:2021-10-31 出版日期:2022-02-25 发布日期:2022-02-25
  • 作者简介:李维刚 男,1977年生,湖北通城人.博士、教授、博导,主要研究方向为人工智能与机器学习算法.
    甘 平(通讯作者) 男,1995年生,湖北武汉人.硕士,主要研究方向为小样本学习、GAN.E-mail: 383615194@qq.com
  • 基金资助:
    国家自然科学基金面上项目(51774219);湖北省重点研发计划(2020BAB098)

A Few-Shot Image Classification Method by Pairwise-Based Meta Learning

LI Wei-gang, GAN Ping, XIE Lu, LI Song-tao   

  1. Engineering Research Center for Metallurgical Automation and Measurement Technology(Ministry of Education),Wuhan University ofScience and Technology,Wuhan,Hubei 430081,China
  • Received:2021-04-09 Revised:2021-10-31 Online:2022-02-25 Published:2022-02-25

摘要:

本文针对小样本图像分类问题,提出一种基于样本对的元学习(Pairwise-based Meta Learning,PML)方法.利用传递迁移学习对预训练好的Resnet50模型进行微调,得到一个更适应小样本任务的特征编码器,将该特征编码器作为元学习模型的初始特征编码器来训练模型,进一步增强了元学习模型的泛化能力;同时,本文还基于支持集与查询集样本之间的相似性提出元损失函数(Meta Loss,ML),其考虑了特征空间中查询集所有样本的相互关系,以此来缩小正样本类内距离,增加正负样本类间距离,从而提高分类精度.实验结果表明,本文的方法在1-shot、5-shot任务上分别达到了77.65%、89.65%的分类精度,较最新的元学习方法Meta-baseline分别提高7.38%、5.65%.

长摘要
全监督学习的高精度预测严重依赖于海量的标签样本,由于在许多领域样本难以获取,全监督模型的泛化能力往往不足。为了解决这一问题,本文针对小样本图像分类问题,提出一种基于样本对的元学习(Pairwise-based Meta Learning,PML)方法,该方法利用迁移学习和元学习的特点,实现了对小样本数据集的高精度分类,且提升了模型的泛化能力. 首先,为了解决源域与目标域差异过大的问题,利用传递迁移学习将先验知识传递式迁移到不同领域的特点,对预训练好的Resnet50模型进行微调,得到一个更适应小样本任务的特征编码器,将该特征编码器作为元学习模型的初始特征编码器来训练模型,进一步增强了元学习模型的泛化能力;同时,本文还基于支持集与查询集样本之间的多相似性提出元损失函数(Meta Loss,ML),利用正相对相似性P粗略挖掘困难样本对,再结合自相似性 S和 负相对相似性N,进一步对样本对加权,其考虑了特征空间中查询集所有样本的相互关系,以此来缩小正样本类内距离,增加正负样本类间距离,从而提高了模型的分类精度. 实验结果表明,本文的方法在钢材显微组织图像数据集的1-shot、5-shot任务上分别达到了77.65%、89.65%的分类精度,较最新的元学习方法Meta-baseline分别提高7.38%、5.65%.

关键词: 小样本图像, 传递迁移学习, 元学习, 元损失函数

Abstract:

In this paper, a pairwise-based meta learning(PML) method is proposed for few-shot image classification. Transitive transfer learning is used to fine tune the pre-trained Resnet50 model to get a feature encoder that is more suitable for few shot task. The feature encoder is used as the initial feature encoder of the meta-learning model to train the model, which further enhances the generalization ability of the meta-learning model. Based on the similarity between the support set and the query set samples, a meta loss(ML) function is proposed, which considers the relationship between all the samples of the query set in the feature space, so as to reduce the within-class distance of positive samples and increase the between-class distance of positive and negative samples, thus improving the classification accuracy.The experimental results show that the classification accuracy of the methods in this paper is 77.65% and 89.65% on 1-shot and 5-shot tasks, respectively, and it is 7.38% and 5.65% higher than the latest meta-learning method, Meta-baseline.

Extended Abstract
Fully supervised learning models have achieved high precision prediction of many datasets, but it rely heavily on a large number of labeled samples. In many fields, it is difficult to obtain enough labeled samples, so the generalization ability of the fully supervised models is insufficient. In order to solve this problem, this paper proposes a pairwise-based meta learning (PML) method for few-shot image classification. Inspired by the characteristics of transfer learning and meta learning, the PML achieves high-precision classification of the few-shot datasets, and improves the generalization ability of the model. Firstly, the characteristics of transfer learning is transferring the prior knowledge to different fields, in order to reduce the difference of the source domain and target domain, the pre-trained Resnet50 model is fine-tuned to obtain a feature encoder that is more suitable for the few-shot tasks by transfer learning. The feature encoder is utilized as the initial feature encoder of the meta learning model to train the model, further enhancing the generalization ability of the meta learning model; at the same time, this paper also proposes a meta loss function (ML) based on the multiple similarities between the support set and the query set samples, it uses the positive relative similarity P to roughly mine teh difficult pairwise samples, and then combines the self similarity S and negative relative similarity N to further weight the pairwise samples, which takes into account the relationship of all samples in the query set in the feature space, so as to reduce the intra class distance of the positive samples and increase the inter class distance of the positive and negative samples, thus the classification accuracy of the model is improved. The experimental results show that the proposed method achieve 77.65% and 89.65% classification accuracy respectively on 1-shot and 5-shot tasks of steel microstructure image data set, which are 7.38% and 5.65% higher than the latest meta learning method meta baseline.

Key words: few-shot image, transitive transfer learning, meta learning, meta loss function

中图分类号: