TL;DR
This paper introduces FSDA (Few-Shot Domain Adaptation), a framework that unifies domain adaptation and few-shot learning for semantic segmentation. By extracting domain-invariant class prototypes from just a few annotated target images, the model can accurately segment complex, high-resolution scenes in a single training stage, bypassing the instability of adversarial training and the complexity of multi-stage self-training.
What Problem Does This Paper Address?
Deep learning models for semantic segmentation are data-hungry. While synthetic datasets (like GTA5) provide "free" labels, models trained on them fail on real-world data (like Cityscapes) due to domain shift.
Existing solutions generally fall into two camps:
- Adversarial Training: Uses GAN-like structures to align distributions, but these are notoriously difficult to tune and computationally expensive.
- Self-training: Generates "pseudo-labels" for the target domain, but this requires multiple rounds of training and a high-quality initial model.
The authors identify a missed opportunity: Domain Adaptation (DA) and Few-Shot Learning (FSL) are two sides of the same coin. Both aim to recognize unseen data distributions using knowledge from a "seen" source. This paper tackles the challenge of making DA easier to train while extending FSL to handle high-resolution images with an arbitrary number of object classes.
Methods
The core of the proposed method is Prototype Learning. Instead of learning a rigid linear classifier, the model learns to extract a "prototype" (a representative feature vector) for each class.
- Domain-Invariant Prototypes: The model uses a Siamese Network to embed both source (query) and target (support) images. It extracts class prototypes from a few annotated target images using Masked Average Pooling (MAP).
- Similarity-Based Classification: Pixels are classified by calculating their cosine similarity to these prototypes. If a pixel's feature vector is closest to the "car" prototype, it's labeled as a car.
- Feature Refinement Module (FRM): To capture high-level semantics, the authors add an FRM that combines features from different layers of the backbone (VGG-16) and uses Pyramid Pooling to gather multi-scale context.
- Support Image Adaptive Training: Standard few-shot methods often fail on high-res images because they assume only one class is present. The authors developed a strategy where the model dynamically adjusts the classes it recognizes in each training step based on what is actually present in the current support image.
Datasets
The authors evaluated their framework on standard synthetic-to-real benchmarks:
- Source Domains (Synthetic): GTA5 (24,966 images from Grand Theft Auto V) and SYNTHIA (9,400 synthetic images).
- Target Domain (Real): Cityscapes (5,000 high-resolution images of urban traffic scenes).
- Support Sets: They created "Cityscapes-5Shot" (33 image-label pairs) and "Cityscapes-1Shot" (7 image-label pairs) to simulate the few-shot scenario.
Key Insights and Ideas
- The Human Analogy: The authors argue that humans recognize a "tiger" in a drawing vs. a photo because we have a domain-invariant concept (prototype) of a tiger. Replicating this "similarity comparison" process makes models more robust.
- One-Stage Efficiency: Unlike self-training methods that require pre-training and multiple iterations, FSDA is trained in a single stage.
- Robustness to Source Change: A major finding was that while standard DA methods see a massive performance drop when switching from GTA5 to SYNTHIA as a source, FSDA remains stable. This suggests the prototypes are truly capturing domain-invariant features rather than just memorizing the source distribution.
- Handling "Stuff" vs. "Things": Most few-shot methods focus on "things" (discrete objects like cars). This framework successfully segments "stuff" (amorphous regions like sky, road, and vegetation) simultaneously.
Key Results
- Competitive Performance: On the GTA5-to-Cityscapes task, the 5-shot FSDA achieved 39.4% mIoU. While slightly lower than the absolute state-of-the-art (SAC at 49.9%), it is significantly easier to train and more flexible.
- Superiority over Baselines: FSDA outperformed the "Source Only" baseline (21.8% mIoU) by a wide margin, proving the effectiveness of using even a tiny amount of target data.
- Open Set Capability: The model naturally handles Open Set Domain Adaptation (OSDA), where the target domain contains classes not present in the source domain, simply by providing a few examples of those new classes.
Limitations and Future Work
- Backbone Constraints: The authors noted that Batch Normalization (BN) in architectures like ResNet poses a challenge. BN relies on large-batch statistics, which are hard to estimate when you only have a few support images. Consequently, they had to use VGG-16.
- Reliance on Labels: While it only requires a "few" labels, it still requires some manual annotation in the target domain, whereas unsupervised DA requires none.
- Future Direction: The authors suggest exploring unsupervised feature learning on the target domain before applying the few-shot adaptation to help the model better understand target-specific textures without needing more labels.
Summary updated