An Ensemble of Epoch-Wise Empirical Bayes for Few-Shot Learning

Yaoyao Liu, Bernt Schiele, Qianru SunLecture Notes in Computer Science 2020 · DOI · OpenReview

Introduction

Few-shot learning (FSL) aims to enable models to recognize new concepts from a minimal number of examples. However, the inherent data scarcity in FSL often leads to models with high prediction variance or low confidence. Traditional meta-learning approaches, such as Model-Agnostic Meta-Learning (MAML), typically focus on finding a single optimal initialization and then performing a few steps of gradient descent to reach a final model. This approach often discards the valuable information contained within the intermediate states of the model during the adaptation process.

In this paper, we present E³BM (Ensemble of Epoch-wise Empirical Bayes Models), a framework designed to leverage the entire training trajectory. By treating the sequence of models produced across training epochs as a robust ensemble and using meta-learned "hyperprior learners" to automate hyperparameter selection, E³BM significantly improves the performance and reliability of few-shot classification.

The E³BM Framework

The E³BM approach is built on two primary conceptual pillars: epoch-wise ensembling and empirical Bayes hyperpriors.

1. Epoch-wise Ensembling

In standard few-shot adaptation, a model is updated over several epochs, and only the final state is used for inference. E³BM posits that early epochs capture broad, general adaptation patterns, while later epochs specialize in task-specific details. By ensembling these epoch-wise models, the framework reduces the variance associated with any single model state, leading to more stable and accurate predictions.

2. Empirical Bayes Hyperpriors

To effectively combine these models, the system requires specific hyperparameters, such as learning rates ($\alpha$) and ensemble weights ($v$). Rather than relying on manual tuning or fixed global values, E³BM employs "hyperprior learners." These are small neural networks trained during the meta-learning phase to generate task-specific hyperparameters based on the gradients and data of the current few-shot episode. This "empirical" approach allows the model to adapt its learning strategy dynamically to the difficulty of each specific task.

Hyperprior Learner Variations

The authors explored four distinct configurations for these hyperprior learners, categorized by two main dimensions:

  • Information Scope (Inductive vs. Transductive): Inductive learners generate parameters based solely on labeled training data. Transductive learners also incorporate information from unlabeled test data, allowing for more informed adaptation.
  • Temporal Modeling (Epoch-independent vs. Epoch-dependent): Epoch-independent learners use simple fully connected (FC) layers to generate parameters for each epoch in isolation. Epoch-dependent learners utilize Long Short-Term Memory (LSTM) networks to capture the sequential "trajectory" of the training process, adjusting parameters based on the history of the adaptation.

The epoch-dependent transductive configuration was found to be the most effective, as it captures the richest set of information regarding both the task data and the optimization path.

Experimental Evaluation

E³BM was evaluated as a "plug-in" module for several established meta-learning algorithms, including MAML, Meta-Transfer Learning (MTL), and Synthetic Information Bottleneck (SIB). Testing was conducted on three major benchmarks:

  • miniImageNet: 100 classes, standard FSL benchmark.
  • tieredImageNet: A larger, hierarchical dataset with 608 classes.
  • FC100 (Few-shot CIFAR100): Low-resolution images with a strict split between training and testing super-classes to emphasize generalization.

Key Results

  • Performance Gains: E³BM consistently improved the accuracy of its base models. Notably, it provided a boost of up to 4.5% when applied to MAML on the miniImageNet dataset.
  • Efficiency: The framework is remarkably lightweight. When integrated with the SIB model, it added only 0.04% more learnable parameters. It maintains memory efficiency by updating prediction scores incrementally rather than storing full model weights for every epoch.
  • Robustness: Ablation studies confirmed that both the ensembling and the empirical hyperprior components contribute to higher prediction confidence and lower variance across different few-shot tasks.

Conclusion

E³BM demonstrates that the intermediate states of model adaptation are not merely stepping stones but valuable components of a robust predictive ensemble. By automating the generation of task-specific hyperparameters through empirical Bayes, the framework provides a flexible and efficient way to enhance existing few-shot learning algorithms. Future work may explore applying this epoch-wise logic to broader domains such as continual learning or more complex hyperprior architectures.

Summary updated

BibTeX
@inproceedings{liu2020ensemble,
  author = {Yaoyao Liu and Bernt Schiele and Qianru Sun},
  title = {{An Ensemble of Epoch-Wise Empirical Bayes for Few-Shot Learning}},
  booktitle = {Lecture Notes in Computer Science},
  year = {2020},
  doi = {10.1007/978-3-030-58517-4\_24},
}
Figure