[Paper Review] Boosting Few-Shot Learning With Adaptive Margin Loss
This paper proposes an adaptive margin loss for few-shot learning that dynamically adjusts margin penalties between classes based on their semantic similarity, improving generalization in metric-based meta-learning. By incorporating class-relevant and task-relevant semantic context, the method achieves state-of-the-art performance on miniImageNet and CIFAR-FS under both standard and generalized few-shot learning settings, with gains up to 4.3% in 5-way 1-shot accuracy.
Few-shot learning (FSL) has attracted increasing attention in recent years but remains challenging, due to the intrinsic difficulty in learning to generalize from a few examples. This paper proposes an adaptive margin principle to improve the generalization ability of metric-based meta-learning approaches for few-shot learning problems. Specifically, we first develop a class-relevant additive margin loss, where semantic similarity between each pair of classes is considered to separate samples in the feature embedding space from similar classes. Further, we incorporate the semantic context among all classes in a sampled training task and develop a task-relevant additive margin loss to better distinguish samples from different classes. Our adaptive margin method can be easily extended to a more realistic generalized FSL setting. Extensive experiments demonstrate that the proposed method can boost the performance of current metric-based meta-learning approaches, under both the standard FSL and generalized FSL settings.
Motivation & Objective
- To improve the generalization ability of metric-based meta-learning in few-shot learning by addressing the challenge of distinguishing similar classes with few examples.
- To develop a margin mechanism that adapts based on semantic similarity between classes, rather than using fixed margins.
- To extend the method to the more realistic generalized few-shot learning setting where test data include both base and novel classes.
- To demonstrate that incorporating semantic context within a meta-training task enhances discriminative embedding learning.
- To validate the effectiveness of adaptive margins through ablation and comparative studies on standard and generalized FSL benchmarks.
Proposed method
- Proposes a class-relevant additive margin loss that generates adaptive margins between each pair of classes using their semantic similarity in a pre-trained semantic space.
- Introduces a task-relevant margin generator that computes margins based on the relative semantic context of all classes within a sampled meta-training task.
- Integrates the adaptive margin into the classification loss, modifying the standard metric learning objective to penalize inter-class distances more for semantically similar classes.
- Uses a learnable coefficient α to scale the margin based on semantic similarity, with α > 0 confirming that similar classes require larger margins.
- Applies the method to prototypical networks and other metric-based models, enabling extension to generalized FSL by modifying the inference and training procedure.
- Employs cosine or Euclidean distance as the base metric in the embedding space, with the adaptive margin applied to logits or distance scores.
Experimental results
Research questions
- RQ1Can adaptive margins based on semantic similarity improve generalization in few-shot learning?
- RQ2Does considering the semantic context among all classes in a meta-training task lead to better discriminative embedding learning?
- RQ3Can the proposed adaptive margin loss be effectively extended to the generalized few-shot learning setting?
- RQ4How does the performance of adaptive margin loss compare to fixed-margin baselines like additive angular and cosine margin losses?
- RQ5Does the learned margin scale α reflect the intuition that similar classes should have larger margins?
Key findings
- The proposed method achieves 67.10% accuracy on miniImageNet under 5-way 1-shot standard FSL, a 1.89% improvement over the original classification loss.
- In 5-way 5-shot evaluation, the method reaches 79.54% accuracy, a 4.34% gain over the baseline, demonstrating strong generalization.
- The task-relevant margin loss outperforms the class-relevant version by 0.74% in 1-shot and 2.33% in 5-shot, confirming the benefit of intra-task semantic context.
- Compared to additive angular and cosine margin losses, the proposed method achieves 66.92% and 67.10% accuracy respectively, showing superior performance.
- The learned margin coefficient α is consistently positive, validating the design intuition that similar classes require larger margins.
- The method generalizes effectively to the generalized FSL setting, maintaining strong performance when test data include both base and novel classes.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.