mlsanityData to 7 Oct 2026

Masked Images Are Counterfactual Samples for Robust Fine-tuning

arXiv 2303.03052 ↗First posted 6 Mar 2023cs.CV cs.LGcited by 20

Not on the map. Why?

Abstract (arXiv)

Deep learning models are challenged by the distribution shift between the training data and test data. Recently, the large models pre-trained on diverse data have demonstrated unprecedented robustness to various distribution shifts. However, fine-tuning these models can lead to a trade-off between in-distribution (ID) performance and out-of-distribution (OOD) robustness. Existing methods for tackling this trade-off do not explicitly address the OOD robustness problem. In this paper, based on causal analysis of the aforementioned problems, we propose a novel fine-tuning method, which uses masked images as counterfactual samples that help improve the robustness of the fine-tuning model. Specifically, we mask either the semantics-related or semantics-unrelated patches of the images based on class activation map to break the spurious correlation, and refill the masked patches with patches from other images. The resulting counterfactual samples are used in feature-based distillation with the pre-trained model. Extensive experiments verify that regularizing the fine-tuning with the proposed masked images can achieve a better trade-off between ID and OOD performance, surpassing previous methods on the OOD performance. Our code is available at https://github.com/Coxy7/robust-finetuning.

Key facts. Cited by 20 papers in the map (data through 7 Oct 2026). Builds on 42 of its 54 references that are in the map. First posted on arXiv 6 Mar 2023.

Builds on

42 of 54 references.

References · 42

  1. 2021Learning Transferable Visual Models From Natural Language Supervisioncited by 33,456
  2. 2020An Image is Worth 16x16 Words: Transformers for Image Recognition at Scalecited by 29,915
  3. 2019PyTorch: An Imperative Style, High-Performance Deep Learning Librarycited by 20,160
  4. 2014Microsoft COCO: Common Objects in Contextcited by 17,498
  5. 2015Distilling the Knowledge in a Neural Networkcited by 10,076
  6. 2014ImageNet Large Scale Visual Recognition Challengecited by 8,441
  7. 2021Masked Autoencoders Are Scalable Vision Learnerscited by 7,339
  8. 2016SGDR: Stochastic Gradient Descent with Warm Restartscited by 4,993
  9. 2021On the Opportunities and Risks of Foundation Modelscited by 3,961
  10. 2021Scaling Up Visual and Vision-Language Representation Learning With Noisy Text Supervisioncited by 3,848
  11. 2019CutMix: Regularization Strategy to Train Strong Classifiers with Localizable Featurescited by 2,875
  12. 2015Learning Deep Features for Discriminative Localizationcited by 2,430
30 more
  1. 2021BEiT: BERT Pre-Training of Image Transformerscited by 2,360
  2. 2021Masked-attention Mask Transformer for Universal Image Segmentationcited by 2,338
  3. 2020The Many Faces of Robustness: A Critical Analysis of Out-of-Distribution Generalizationcited by 1,842
  4. 2019Invariant Risk Minimizationcited by 1,832
  5. 2019Do ImageNet Classifiers Generalize to ImageNet?cited by 1,507
  6. 2019Natural Adversarial Examplescited by 1,401
  7. 2022Model soups: averaging weights of multiple fine-tuned models improves accuracy without increasing inference timecited by 1,366
  8. 2021SimMIM: A Simple Framework for Masked Image Modelingcited by 1,147
  9. 2019Learning Robust Global Representations by Penalizing Local Predictive Powercited by 1,010
  10. 2018Robustness May Be at Odds with Accuracycited by 873
  11. 2021Robust fine-tuning of zero-shot modelscited by 785
  12. 2020Out-of-Distribution Generalization via Risk Extrapolation (REx)cited by 737
  13. 2022Fine-Tuning can Distort Pretrained Features and Underperform Out-of-Distributioncited by 722
  14. 2018Recognition in Terra Incognitacited by 655
  15. 2021Masked Feature Prediction for Self-Supervised Visual Pre-Trainingcited by 573
  16. 2019Variational Autoencoders and Nonlinear ICA: A Unifying Frameworkcited by 494
  17. 2020Measuring Robustness to Natural Distribution Shifts in Image Classificationcited by 452
  18. 2020What is being transferred in transfer learning?cited by 365
  19. 2021Generic Attention-model Explainability for Interpreting Bi-Modal and Encoder-Decoder Transformerscited by 316
  20. 2021Accuracy on the Line: On the Strong Correlation Between Out-of-Distribution and In-Distribution Generalizationcited by 248
  21. 2021Towards Causal Representation Learningcited by 207
  22. 2020Invariant Risk Minimization Gamescited by 188
  23. 2019A Meta-Transfer Objective for Learning to Disentangle Causal Mechanismscited by 158
  24. 2020Counterfactual Samples Synthesizing for Robust Visual Question Answeringcited by 153
  25. 2020Learning Causal Semantic Representation for Out-of-Distribution Predictioncited by 60
  26. 2021Out of Distribution Generalization in Machine Learningcited by 59
  27. 2021Systematic Evaluation of Causal Discovery in Visual Model Based Reinforcement Learningcited by 53
  28. 2022SwapMix: Diagnosing and Regularizing the Over-Reliance on Visual Context in Visual Question Answeringcited by 38
  29. 2022Can Foundation Models Talk Causality?cited by 30
  30. 2022On the Generalization and Adaption Performance of Causal Modelscited by 8

Built on by

Cited by year (2026 to 7 Oct)

Citing papers per year: 2023: 5; 2024: 6; 2025: 7; 2026: 2.

20 papers.

Sort:

By area:

  1. 2024Masked Image Modeling: A Surveycited by 28
  2. 2026Causal-JEPA: Learning World Models through Object-Level Latent Maskingcited by 25
  3. 2024DGMamba: Domain Generalization via Generalized State Space Modelcited by 21
  4. 2024Decompose-and-Compose: A Compositional Approach to Mitigating Spurious Correlationcited by 18
  5. 2023Masked Modeling for Self-supervised Representation Learning on Vision and Beyondcited by 13
  6. 2024Toward a Holistic Evaluation of Robustness in CLIP Modelscited by 13
  7. 2024Efficient and Versatile Robust Fine-Tuning of Zero-shot Modelscited by 7
  8. 2023Foundation Model-oriented Robustness: Robust Image Model Evaluation with Pretrained Modelscited by 6
  9. 2025Generalized Semantic Contrastive Learning via Embedding Side Information for Few-Shot Object Detectioncited by 6
  10. 2023CausalVLR: A Toolbox and Benchmark for Visual-Linguistic Causal Reasoningcited by 5
  11. 2025Evaluating and Improving Robustness in Large Language Models: A Survey and Future Directionscited by 5
  12. 2023Rethinking Radiology Report Generation via Causal Inspired Counterfactual Augmentationcited by 3
8 more
  1. 2025Just as Humans Need Vaccines, So Do Models: Model Immunization to Combat Falsehoodscited by 3
  2. 2025DGFamba: Learning Flow Factorized State Space for Visual Domain Generalizationcited by 1
  3. 2025Two-stage Vision Transformers and Hard Masking offer Robust Object Representationscited by 1
  4. 2025Did Models Learn Sufficiently? Attribution-Guided Training via Subset-Selected Counterfactual Augmentationcited by 1
  5. 2023Towards Debiasing Frame Length Bias in Text-Video Retrieval via Causal Interventioncited by 0
  6. 2024Approximate Nullspace Augmented Finetuning for Robust Vision Transformerscited by 0
  7. 2025CaFlow: Enhancing Long-Term Action Quality Assessment with Causal Counterfactual Flowcited by 0
  8. 2026Clinically-Grounded Counterfactual Reasoning for Medical Video Diagnosiscited by 0