[Paper Review] Layer Grafted Pre-training: Bridging Contrastive Learning And Masked Image Modeling For Label-Efficient Representations
This paper proposes Layer Grafted Pre-training, a novel method that sequentially applies Masked Image Modeling (MIM) to lower layers and Contrastive Learning (CL) to higher layers to avoid gradient conflicts. By grafting MIM-trained lower layers and fine-tuning upper layers with CL, the approach achieves state-of-the-art label efficiency, attaining 65.5% Top-1 accuracy on ImageNet-1k with only 1% labeled data—14.4% higher than MIM and 2.1% higher than CL baselines.
Recently, both Contrastive Learning (CL) and Mask Image Modeling (MIM) demonstrate that self-supervision is powerful to learn good representations. However, naively combining them is far from success. In this paper, we start by making the empirical observation that a naive joint optimization of CL and MIM losses leads to conflicting gradient directions - more severe as the layers go deeper. This motivates us to shift the paradigm from combining loss at the end, to choosing the proper learning method per network layer. Inspired by experimental observations, we find that MIM and CL are suitable to lower and higher layers, respectively. We hence propose to combine them in a surprisingly simple, "sequential cascade" fashion: early layers are first trained under one MIM loss, on top of which latter layers continue to be trained under another CL loss. The proposed Layer Grafted Pre-training learns good visual representations that demonstrate superior label efficiency in downstream applications, in particular yielding strong few-shot performance besides linear evaluation. For instance, on ImageNet-1k, Layer Grafted Pre-training yields 65.5% Top-1 accuracy in terms of 1% few-shot learning with ViT-B/16, which improves MIM and CL baselines by 14.4% and 2.1% with no bells and whistles. The code is available at https://github.com/VITA-Group/layerGraftedPretraining_ICLR23.git.
Motivation & Objective
- To address the inherent conflict between Masked Image Modeling (MIM) and Contrastive Learning (CL) when jointly optimized in self-supervised representation learning.
- To investigate whether MIM and CL exhibit layer-specific preferences in feature learning, particularly regarding local detail vs. semantic invariance.
- To improve label efficiency in downstream tasks, especially few-shot and linear evaluation, by strategically combining MIM and CL in a sequential, non-conflicting manner.
- To demonstrate that a simple, cascaded training strategy—MIM first, then CL—outperforms joint optimization and existing pretraining paradigms without additional components.
Proposed method
- The method trains lower layers using MIM loss to capture local spatial structures and fine-grained details through masked reconstruction.
- After MIM pre-training, the lower layers are partially fine-tuned while higher layers are trained under CL loss to learn semantic invariance and clustering structures.
- The grafting process is 'smoothed' by allowing gradual tuning of lower layers during CL training, reducing disruption to learned representations.
- The approach avoids gradient conflicts by separating MIM and CL losses across different network depth levels, rather than optimizing them jointly.
- The method is applied in a sequential cascade: MIM is applied first to early layers, followed by CL on deeper layers, with the order shown to be critical.
- The framework is evaluated using standard benchmarks such as ImageNet-1k, with linear evaluation and few-shot fine-tuning protocols to assess label efficiency.
Experimental results
Research questions
- RQ1Do MIM and CL exhibit conflicting gradient directions when jointly optimized, particularly in deeper network layers?
- RQ2Do lower and higher layers of a vision transformer prefer different self-supervised objectives—specifically, is MIM more beneficial for lower layers and CL for higher layers?
- RQ3Can a sequential, layer-wise application of MIM followed by CL outperform joint optimization and standard pretraining baselines in label-efficient learning?
- RQ4Does the order of applying MIM and CL matter for final representation quality and downstream performance?
- RQ5Can a simple, modular pretraining strategy combining MIM and CL achieve state-of-the-art few-shot performance without additional components or bells and whistles?
Key findings
- The proposed Layer Grafted Pre-training achieves 65.5% Top-1 accuracy on ImageNet-1k under 1% few-shot learning, outperforming MIM and CL baselines by 14.4% and 2.1%, respectively.
- In linear evaluation, the method achieves 74.9% Top-1 accuracy, a 9.7% improvement over MIM and 1.0% over CL baselines.
- The performance gain is most pronounced in low-data regimes, confirming the method’s superior label efficiency.
- Ablation studies show that reversing the grafting order (CL before MIM) leads to significant performance degradation, proving the importance of layer-specific loss assignment.
- The method demonstrates that MIM and CL are not directly combinable via joint optimization due to severe gradient conflicts in deeper layers.
- The success of the approach is attributed to the strategic separation of MIM (for local structure in early layers) and CL (for semantic invariance in deeper layers), avoiding conflicting optimization signals.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.