Distilling Visual Priors from Self-Supervised Learning

Bingchen Zhao, Xin Wen

Abstract

Deep learning models often struggle with overfitting when training data is scarce. This paper introduces a two-phase training pipeline designed to mitigate this issue by first learning general "visual priors" through self-supervised contrastive learning and then transferring these priors to a student model via knowledge distillation. This approach yields a significant 16.7% accuracy improvement over standard supervised baselines on data-deficient datasets.

Introduction: The Challenge of Data Scarcity

While deep learning has achieved remarkable success on massive datasets like ImageNet, real-world applications often face "data-deficient" scenarios. When high-capacity Convolutional Neural Networks (CNNs) are trained on small datasets, they tend to memorize specific training instances—overfitting—rather than learning generalizable features. Standard regularization techniques like Dropout and BatchNorm often fall short when labels are extremely limited. This research explores leveraging Self-Supervised Learning (SSL) to establish a robust feature foundation before any category labels are introduced.

Methodology: A Two-Phase Pipeline

The authors propose a framework that separates the learning of visual features from the learning of class labels using a two-phase approach.

The two-phase training pipeline: Phase 1 involves self-supervised pre-training to learn visual priors, and Phase 2 uses feature distillation to guide supervised learning.

Phase 1: Self-Supervised Pre-training

The first phase utilizes a modified version of MoCo v2 (Momentum Contrast). The model learns to distinguish between different augmented views of the same image versus other images in the dataset.

  • Innovation: Margin Loss. Standard contrastive learning typically requires a large "memory bank" of negative samples. To adapt this to smaller datasets, the authors introduced a Margin Loss to the contrastive task. This forces the model to maintain a larger distance between data samples, enabling high-quality representation learning even with fewer negative samples.

Phase 2: Self-Distillation

Instead of conventional fine-tuning, the authors employ a teacher-student distillation setup to prevent the model from discarding general features in favor of label-specific noise:

  • Teacher: The frozen model resulting from Phase 1.
  • Student: Initialized with the Phase 1 weights but trained on labeled data.
  • Optimization: The student is trained using a combination of standard classification loss and Overhaul Feature Distillation (OFD). This ensures the student retains the general visual priors from Phase 1 while mastering the specific classification task.

Experimental Setup and Datasets

The study was evaluated using the VIPriors Image Classification Challenge dataset, a subset of ImageNet containing 1,000 classes with only 50 images per class (150,000 total). The challenge strictly forbids external data or pre-trained models, making it a rigorous test of learning efficiency from scratch.

Key Results

The proposed pipeline demonstrated substantial gains over traditional supervised training. As shown in the performance breakdown, the integration of Phase 1 (SSL) and Phase 2 (Distillation) provides the best performance.

Comparison of validation accuracy across different training strategies using a ResNet50 backbone. The full pipeline achieves a 16.7% gain over the supervised baseline.
  • Supervised Baseline: 27.9% Top-1 Accuracy.
  • SSL + Linear Classifier: 34.5%, indicating that SSL alone captures more useful features than supervised learning on small data.
  • Full Pipeline (SSL + Distillation): 44.6%, a total gain of 16.7% over the baseline.

By incorporating additional techniques such as ResNeXt101 backbones, Auto-Augment, and model ensembling, the final accuracy reached 68.8%, placing the method at the top of the VIPriors challenge leaderboard.

Conclusion

The core insight of this work is that self-supervised representations act as a powerful regularizer. By distilling these unbiased "visual priors" into the supervised phase, the model is tethered to general visual patterns, preventing it from finding non-generalizable "shortcuts" in small labeled sets. Future work may explore applying this distillation concept to other domains like object detection or segmentation where labeled data is even more costly to acquire.

Summary updated

BibTeX
@inproceedings{zhao2020distilling,
  author = {Bingchen Zhao and Xin Wen},
  title = {{Distilling Visual Priors from Self-Supervised Learning}},
  booktitle = {Workshops @ ECCV},
  year = {2020},
  doi = {10.1007/978-3-030-66096-3\_29},
}
Figure