Multi-Scale Positive Sample Refinement for Few-Shot Object Detection

Jiaxi Wu, Songtao Liu, Di Huang, Yunhong Wang

Abstract

Few-shot object detection (FSOD) aims to detect novel objects using only a few annotated examples. A significant challenge in this domain is the "sparse scale distribution," where limited training data fails to cover the diverse sizes at which objects appear. This paper proposes Multi-Scale Positive Sample Refinement (MPSR), an auxiliary training branch that generates multi-scale object crops and manually assigns them to feature pyramids. This approach enriches the scale diversity of positive samples without introducing harmful background noise. MPSR achieves state-of-the-art performance on PASCAL VOC and MS COCO benchmarks with zero additional computational cost during inference.

Introduction

Standard object detection models require thousands of labeled images to achieve high accuracy. Few-Shot Object Detection (FSOD) seeks to lower this barrier by enabling models to recognize new classes from as few as 1 to 10 examples. However, FSOD models often struggle with scale variation. In large datasets, objects naturally appear at various scales (small, medium, large). In a few-shot scenario, the available examples might only represent a narrow range of sizes, leading to poor generalization when the model encounters the same object at a different scale.

Scale distribution of object instances in the original dataset vs. few-shot samples for 'Bus' and 'Cow' classes.

The authors identify that standard techniques like image pyramids or Feature Pyramid Networks (FPN) are often insufficient for FSOD. Aggressively scaling entire images in a data-scarce regime introduces "improper negative samples"—background regions that the model hasn't seen enough of to correctly classify as noise. This interference often outweighs the benefits of the additional positive scale information.

Multi-Scale Positive Sample Refinement (MPSR)

To address scale sparsity without the noise of full-image scaling, the authors introduce the Multi-Scale Positive Sample Refinement (MPSR) framework. Built upon a Faster R-CNN with FPN, MPSR adds an auxiliary branch dedicated to refining the model's scale invariance.

Object Pyramids and Auxiliary Branch

Instead of scaling the whole image, MPSR crops positive objects from the few available training images and resizes them to a predefined set of scales (ranging from $32^2$ to $800^2$ pixels). These crops form "Object Pyramids." These scaled crops are processed by an auxiliary branch that shares weights with the main detection network.

The MPSR architecture: Object crops are resized into pyramids, processed into feature pyramids, and used to refine the RPN and Detection heads.

Manual Anchor Assignment

A key innovation in MPSR is the departure from standard Intersection-over-Union (IoU) based anchor matching. In typical training, anchors are assigned as positive or negative based on their overlap with ground truth. For tightly cropped objects in the auxiliary branch, this process can generate false negatives from the surrounding padding. MPSR bypasses this by manually assigning each scaled object to its corresponding FPN level and center location. This ensures the network receives "pure" positive signals at various scales.

Inference Efficiency

Crucially, the MPSR branch is only active during the training phase to update the shared weights of the Region Proposal Network (RPN) and Region of Interest (RoI) heads. During inference, the auxiliary branch is discarded, meaning the improved performance comes with no extra latency or computational overhead.

Experimental Results

The MPSR method was evaluated on several standard benchmarks:

  • PASCAL VOC: MPSR set new state-of-the-art records. In the extreme 1-shot scenario, it achieved 41.7% mAP, a significant jump from the 25.5% baseline and previous methods like Meta R-CNN (19.9%).
  • MS COCO: On this more complex dataset, MPSR reached 14.1% mAP in the 30-shot setup, outperforming previous leaders. It showed consistent improvements across small, medium, and large object categories.
  • Cross-Dataset Generalization: When pre-trained on COCO and fine-tuned on VOC novel classes (10-shot), MPSR achieved 42.3% mAP, demonstrating robust domain transfer capabilities.

Conclusion

MPSR highlights that scale sparsity is a primary bottleneck in few-shot object detection. By focusing on targeted positive sample refinement rather than global image scaling, the method effectively teaches the model scale invariance without the penalty of background noise. While the current implementation relies on manual assignment rules tailored for two-stage detectors, the core principle of positive sample refinement offers a promising direction for future FSOD research.

Summary updated

BibTeX
@inproceedings{wu2020multi,
  author = {Jiaxi Wu and Songtao Liu and Di Huang and Yunhong Wang},
  title = {{Multi-Scale Positive Sample Refinement for Few-Shot Object Detection}},
  booktitle = {European Conference on Computer Vision},
  year = {2020},
  doi = {10.1007/978-3-030-58517-4\_27},
}
Figure