There are some details of reading and implementing the Relation Network for few-shot learning.
Contents
Paper & Code & note
Paper: Learning to Compare: Relation Network for Few-Shot Learning(CVPR 2018 paper)
Code: PyTorch(Few-Shot Learning part)
Note: RN for FSL
Paper
Abstract
As abstract
of the paper, their work mainly proposed a method called Realation Network (RN) to recognise new classes given only few examples from each.
- It based on meta-learning. That is to say, the RN learns a
deep distance metric
to compare a number of images with episodes, and it is aepisode-based
method.- It classify images of new classes by computing relation scores. That is to say, there is a score in each
query
image with their relations ofsample
images in each class.
Problem Description
It shows the task of few-shot learning and the exists model.
Problem Solution
It includes Embedding module and Relation module of the RN.
References: [36, 39], RNNs: [39, 32, 29], Fine-tuning: [29, 10].
Conceptual Understanding
It describes what is meta-learning and how to classify query images.
Remaining Problem
It is the question in my mind in terms of the paper and the code.
Core Conception
It denotes the
most important
conception of Relation Network (RN) and explains the Embedding module and Relation module respectively.
Besides, the network architecture shows below.
Experimental Results
There are results of carring RN on Omniglot and miniImagenet datasets in paper, which shows that RN got better performance when comparing with other state-of-the-art methods.
Code
Program block
It divides program files to three blocks, which are pre-process, train and test as well as the function list of the blocks.
Program explanation
It explains the details of the code blocks in each process.
Program improvement
Main work in my improved code are tackling problems and optimizing functions as well as train and test my personnal datasets.
References
[1] Sung F, Yang Y, Zhang L, et al. Learning to compare: Relation network for few-shot learning[C]//Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition. 2018: 1199-1208.
[2] LearningToCompare_FSL. https://github.com/floodsung/LearningToCompare_FSL.
[3] Pytorch. https://github.com/pytorch/pytorch.
Note