Low-shot visual object recognition

Bharath Hariharan, Ross B. GirshickarXiv 2016

Abstract

Low-shot visual learning---the ability to recognize novel object categories from very few examples---is a hallmark of human visual intelligence. Existing machine learning approaches fail to generalize in the same way. To make progress on this foundational problem, we present a low-shot learning benchmark on complex images that mimics challenges faced by recognition systems in the wild. We then propose a) representation regularization techniques, and b) techniques to hallucinate additional training examples for data-starved classes. Together, our methods improve the effectiveness of convolutional networks in low-shot learning, improving the one-shot accuracy on novel classes by 2.3x on the challenging ImageNet dataset.

Introduction

While modern Convolutional Neural Networks (ConvNets) excel at recognizing objects when provided with thousands of labeled images, they struggle with low-shot learning—the ability to learn a new concept from just one or a few examples. Humans do this effortlessly; show a child one picture of a platypus, and they can usually recognize another.

Existing AI approaches often fail to generalize in these data-starved scenarios. Furthermore, many previous evaluations only tested the model's ability to distinguish between a few novel classes. This paper argues for a more realistic "in the wild" scenario: a model must learn new categories without forgetting the "base" categories it was originally trained on, maintaining high performance across the entire joint label space.

Methods

The authors propose a two-pronged attack on the low-shot problem: feature hallucination and representation regularization.

The low-shot learning pipeline: Representation learning on base classes followed by low-shot learning for novel categories to create a joint classifier.

1. Feature Hallucination (Data Augmentation)

The core idea is that "modes of variation" (like changes in pose, lighting, or background) are often shared across categories. If we know how a "sparrow" looks when it transitions from "perched" to "flying," we can apply that same transformation to a single image of a novel bird species to "hallucinate" what it might look like in flight. The authors use a non-parametric approach to mine these analogies from base classes and train a generator to produce synthetic feature vectors for novel classes.

2. Squared Gradient Magnitude (SGM) Loss

The authors investigate how to learn better feature representations during the initial "base" training phase. They derive the SGM loss, which encourages the model to produce features such that a classifier trained on a tiny subset of data behaves similarly to one trained on a massive dataset. This simplifies to a form of feature activation regularization—essentially "shrinking" the magnitude of the features to ensure the model doesn't overfit to noise or irrelevant details when data is scarce.

Experimental Setup

The primary contribution is a new benchmark based on ImageNet1k:

  • Base Classes: 389 categories with many training examples, used for representation learning.
  • Novel Classes: 611 categories with only $n$ examples (where $n \in \{1, 2, 5, 10, 20\}$).
  • Evaluation: The model is tested on its ability to recognize all 1,000 classes simultaneously, ensuring that gains on new classes don't come at the expense of the old ones.

Results

The combination of better representations and hallucinated features yielded massive improvements over the baseline. On the ResNet-10 architecture, the top-5 accuracy on novel classes jumped from 14.1% (baseline) to 32.8% using their combined methods—a 2.3x improvement.

Performance comparison of various methods (baseline, triplets, decov, l2, sgm) across novel and joint class sets as the number of training examples (n) increases.

Key insights include:

  • Intra-class variation is transferable: You don't need to see a thousand "occluded" examples of a new object if you've already learned what "occlusion" looks like for hundreds of other objects.
  • Regularization is key: Penalizing feature magnitudes (SGM/L2 regularization) forces the network to focus on the most robust, discriminative information. SGM loss alone added about 9 points of accuracy.
  • Hallucination Impact: Adding hallucinated examples improved one-shot top-5 accuracy by roughly 15 points absolute.

Conclusion

This work demonstrates that low-shot learning can be significantly improved by transferring knowledge of variations from data-rich classes and regularizing feature representations. While the hallucination strategy is powerful, the authors note that synthetic features are not yet as high-quality as real images. Future work could involve more sophisticated generative models (like GANs) to create even more realistic "hallucinations" or explore applications in zero-shot learning.

Summary updated

BibTeX
@misc{hariharan2016low,
  author = {Bharath Hariharan and Ross B. Girshick},
  title = {{Low-shot visual object recognition}},
  year = {2016},
  eprint = {1606.02819},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1606.02819},
}
Figure