Few-Shot Segmentation Propagation with Guided Networks

Kate Rakelly, Evan Shelhamer, Trevor Darrell, Alexei A. Efros, Sergey LevinearXiv 2018 · arXiv

Introduction

Deep learning has significantly advanced visual segmentation, yet standard models remain "data-hungry" and rigid. Training typically requires thousands of pixel-perfect masks, a process that is both tedious and expensive. Furthermore, adapting a pre-trained model to a new task or correcting errors during inference often necessitates slow and costly fine-tuning. While interactive tools exist, they frequently lack the ability to generalize across images or video frames.

This paper introduces Guided Networks, a unified framework designed to bridge these gaps. By extracting a latent task representation from minimal supervision—such as a few sparse dots—the model can propagate annotations across images, video frames, and semantic classes near-instantaneously.

Methods: The Guided Architecture

The core of the proposed system is a branched architecture that separates task definition from task execution.

  1. The Guide Branch ($g$): This component processes a "support" set consisting of an image and sparse annotations (positive and negative points). It extracts a latent task representation ($z$) that encodes the specific object or class to be segmented.
  2. The Inference Branch ($f$): Conditioned on the task representation $z$, this branch takes a "query" image and produces the final segmentation mask.
The Guided Network architecture consists of a Guide Branch that extracts a task representation from sparse annotations and an Inference Branch that applies it to a query image.

Late Fusion and Global Guidance

A critical technical innovation is the shift from Early Fusion to Late Fusion. Unlike early fusion, which stacks images and annotations at the input level, the Guided Network extracts visual features first. Annotations are then used to mask and pool these features. This approach is computationally efficient, as features can be cached, and it unifies the visual representations of support and query images.

To ensure robustness, the model employs Global Guidance. Local task features are pooled into a single global vector, allowing the network to recognize and segment objects regardless of their position or scale within the frame.

Datasets and Training

The model was evaluated on two primary benchmarks:

  • PASCAL VOC 2012: Testing few-shot semantic segmentation on held-out, unseen classes.
  • DAVIS 2017: Testing video object segmentation to evaluate the propagation of annotations across temporal sequences.

The network is trained using episodic training, where it learns the meta-task of using guidance by solving randomly sampled tasks from fully labeled datasets.

Key Results

The Guided Network demonstrates significant improvements in both efficiency and accuracy:

  • Extreme Sparsity: The model can segment a new concept from as little as one pixel. With just two points (one positive, one negative), it outperforms existing deep interactive methods.
  • Speed: The architecture is approximately 200x faster than fine-tuning-based methods like OSVOS, enabling real-time interactive use.
  • Video Performance: On DAVIS 2017, the model achieved a 60% relative improvement in accuracy over early-fusion baselines.
  • Robustness: It retains 87% of the accuracy of dense-mask methods while using only five sparse points for guidance.
Qualitative result showing the model's ability to segment complex objects like a parrot using sparse guidance.

Conclusion and Future Work

By treating annotations as pixels, the Guided Network provides a unified "pixels in, pixels out" framework for interactive, video, and semantic segmentation. While highly effective, the authors noted that the model can sometimes become insensitive to refinement dots within the same class due to high-level category invariance. Future research will focus on balancing this generalization with the precision required for fine-grained boundary corrections.

Summary updated

Abstract

Learning-based methods for visual segmentation have made progress on particular types of segmentation tasks, but are limited by the necessary supervision, the narrow definitions of fixed tasks, and the lack of control during inference for correcting errors. To remedy the rigidity and annotation burden of standard approaches, we address the problem of few-shot segmentation: given few image and few pixel supervision, segment any images accordingly. We propose guided networks, which extract a latent task representation from any amount of supervision, and optimize our architecture end-to-end for fast, accurate few-shot segmentation. Our method can switch tasks without further optimization and quickly update when given more guidance. We report the first results for segmentation from one pixel per concept and show real-time interactive video segmentation. Our unified approach propagates pixel annotations across space for interactive segmentation, across time for video segmentation, and across scenes for semantic segmentation. Our guided segmentor is state-of-the-art in accuracy for the amount of annotation and time. See http://github.com/shelhamer/revolver for code, models, and more details.
BibTeX
@misc{rakelly2018few,
  author = {Kate Rakelly and Evan Shelhamer and Trevor Darrell and Alexei A. Efros and Sergey Levine},
  title = {{Few-Shot Segmentation Propagation with Guided Networks}},
  year = {2018},
  eprint = {1806.07373},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1806.07373},
}
Figure