Ensemble Self-supervised Learning

Machine Learning
Introduced by
Multiple contributors (Grill et al., Caron et al., Chen et al.)
Year
2020–2021
Type
Ensemble of self-supervised models or objectives
Family
Machine learning

What does it do?

Ensemble Self-supervised Learning combines several self-supervised models, objectives, or augmentation views into one representation pipeline.

It is trained on unlabeled data and then evaluated on labeled downstream tasks. The motivation is that different pretext objectives capture different aspects of the data, so a combined representation may generalize better than any single objective; whether it beats the best single component is an empirical question that should be settled by ablation.

The intuition behind the method

Self-supervised learning trains a model to predict one part of its input from another, so no labels are needed. A single pretext task has blind spots: the features it learns reflect what that task rewards and may ignore other structure in the data. Combining several objectives, or training several encoders under different objectives, gives partly complementary views of the same data. The pooled representation may transfer better to later labeled tasks, but the size of that gain depends on how different the components really are.

History

BYOL (Grill et al., 2020) uses a self-distillation objective with a momentum encoder, and DINO (Caron et al., 2021) applies self-distillation with multi-crop training to Vision Transformers, which the authors describe as a form of self-distillation with no labels. The DINO abstract highlights the momentum encoder and multi-crop training as important factors. The term Ensemble SSL has no single originator; it describes combining self-supervised objectives, as in this line of work, and is best read as a descriptive label rather than a named method.

When to use it

Consider Ensemble SSL when a large pool of unlabeled data is available, labels are costly, and a single self-supervised objective yields representations that transfer poorly across tasks. It is most natural for images, audio and text, where several augmentation views or objectives can be defined. Avoid it when compute or memory is tight, because each additional encoder or loss multiplies training cost. Also avoid it when the target task is narrow enough for one well-tuned objective, or when a pretrained foundation model already covers the domain and fine-tuning it is the simpler route.

Limitations and considerations

  • Training cost and memory grow with each additional encoder or loss, and each component may need its own augmentation pipeline per batch.
  • Each component adds hyperparameters such as temperature, projection head and augmentation policy, so the tuning space grows quickly.
  • Gains may be small when the objectives are similar; combining them does not guarantee an improvement over the best component.
  • Reproducibility can be harder because randomness from several augmentation pipelines compounds across components.

Source conditions do not replace independent scientific review or validation by an analysis engine.

Strengths

  • Combining objectives with different inductive biases can capture structure that a single objective may miss, which is the main rationale for the approach.
  • Using several augmentation views may reduce reliance on any single augmentation choice; this should be tested on each dataset.
  • Components can be added incrementally, so the ensemble can be extended without collecting new labeled data.
  • Ingredients of the approach have worked well with Vision Transformers: the DINO study reports that self-distillation with multi-crop training and small patches yields strong features. DINO itself is a single objective, so it supports the building blocks rather than the ensemble as such.

Applications

  • Visual representation pretraining for image classification, the setting evaluated in the DINO study.
  • Medical imaging, where labeled data may be scarce and pretraining on unlabeled scans is attractive.
  • Audio and speech representation learning using several spectrogram augmentation views.
  • Text pretraining that combines different objectives, such as masked prediction and contrastive sentence objectives.
  • Multimodal settings in which image, text and audio encoders are trained toward a shared representation space.

How it works

How it works

1

Each input is turned into several views using augmentations such as random cropping, color jitter, Gaussian blur and grayscale conversion, applied at different scales. Different views probe different invariances, which can push the components toward complementary features. The DINO study reports that multi-crop training is one of the factors that matter, so the number and scale of crops is a design choice worth reporting.

2

One or more encoders are trained under different self-supervised objectives. Examples from the wider literature include contrastive loss (SimCLR), self-distillation (BYOL, DINO), masked reconstruction (MAE) and clustering (SwAV). The components may be trained jointly or separately; the choice should be stated and justified. Each objective encourages a different inductive bias, so the encoders may capture different aspects of the data distribution.

3

Feature vectors, embeddings or output probabilities from the components are combined by averaging, by majority voting, or by learned attention weights that reflect each component's reliability for a given input. Averaging or voting tends to help only when the components make partly different errors and produce embeddings on comparable scales; otherwise the combined representation may be no better than its best member. Any implementation should state the rule used and how any weights are learned.

4

The combined representation is passed to a lightweight linear probe or a fine-tuning head for the target task. Because the representation draws on several self-supervised signals, it may depend less on any one augmentation or objective choice, but this should be checked for the specific data rather than assumed.

5

Performance is measured on labeled downstream tasks such as image classification, object detection or sentence similarity, using linear evaluation with a frozen backbone and fine-tuning. Comparing the ensemble with each component under the same protocol isolates the contribution of the ensemble. The DINO study reports both k-NN and linear-evaluation accuracy, which illustrates why more than one protocol should be reported.

Common pitfalls

  • Combining objectives that share the same views and inductive bias, such as two contrastive losses on the same augmentations, may add cost without adding diversity.
  • Reporting only linear-probe accuracy can miss differences that appear under fine-tuning, so both should be reported.
  • Without ablating each component, the source of any observed gain cannot be identified.
  • If every encoder is needed at inference time, deployment cost can be prohibitive, and a single or distilled model may be required.
  • If a strong pretrained foundation model already covers the domain, it may be a faster baseline; compare it with the ensemble on the target task before committing to pretraining.
  • Single runs can mislead: a small gain may fall within seed-to-seed variance, so repeat each configuration with several random seeds before treating a difference as real.

Frequently asked questions

Do I need labels to train an Ensemble SSL model?

No. Pretraining is unsupervised. Labels are used only in the downstream linear evaluation or fine-tuning step, which may use a small labeled set.

How many objectives or encoders should the ensemble include?

There is no fixed rule for the number of components. A reasonable start is two complementary objectives, such as one contrastive and one self-distillation loss. Add further components only if an ablation shows a measurable gain that justifies the extra cost.

Is Ensemble SSL the same as multi-view contrastive learning?

Multi-view contrastive learning is one instance of Ensemble SSL: it uses multiple augmented views under a single contrastive objective. Ensemble SSL is the broader idea that also covers combining different loss functions, architectures or modalities.

How should I evaluate whether the ensemble actually helps?

Compare each individual component against the full ensemble using the same linear probe and fine-tuning protocol. If the ensemble does not consistently outperform the best single component, the added compute may not be justified.

Can Ensemble SSL be used with transformer architectures?

Yes, in principle. The DINO study reports that self-distillation with multi-crop training works well with Vision Transformers. That work covers vision only, so applying the same principle to other transformer encoders should be validated separately.

Related methods

Sources

  1. Grill, J.-B., Strub, F., Altché, F., Tallec, C., Richemond, P. H., Buchatskaya, E., Doersch, C., Ávila Pires, B., Guo, Z., Gheshlaghi Azar, M., Piot, B., Kavukcuoglu, K., Munos, R., & Valko, M. (2020). Bootstrap Your Own Latent: A New Approach to Self-Supervised Learning. Advances in Neural Information Processing Systems, 33, 21271–21284.

    Open publication reference
  2. Caron, M., Touvron, H., Misra, I., Jégou, H., Mairal, J., Bojanowski, P., & Joulin, A. (2021). Emerging Properties in Self-Supervised Vision Transformers. Proceedings of the IEEE/CVF International Conference on Computer Vision (ICCV), 9650–9660.

    Open DOI reference