MaskDiME: Adaptive Masked Diffusion for Precise and Efficient Visual Counterfactual Explanations
Changlu Guo, Anders Nymark Christensen, Anders Bjorholm Dahl, Morten Rieger Hannemose
Abstract
Visual counterfactual explanations aim to reveal the minimal semantic modifications that can alter a model's prediction, providing causal and interpretable insights into deep neural networks. However, existing diffusion-based counterfactual generation methods are often computationally expensive, slow to sample, and imprecise in localizing the modified regions. To address these limitations, we propose MaskDiME, a simple, fast, yet effective diffusion framework that unifies semantic consistency and spatial precision through localized sampling. Our approach adaptively focuses on decision-relevant regions to achieve localized and semantically consistent counterfactual generation while preserving high image fidelity. Our training-free framework, MaskDiME, performs inference over 30× faster than the baseline and achieves comparable or state-of-the-art performance across five benchmark datasets spanning diverse visual domains, establishing a practical and generalizable solution for efficient counterfactual explanation. The project page is available at https://clguo.github.io/MaskDiME/.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Builds on27
- Denoising Diffusion Probabilistic ModelsJonathan Ho, Ajay Jain, Pieter AbbeelNeurIPS 2020 · 35,902 citations
- High-Resolution Image Synthesis with Latent Diffusion ModelsRobin Rombach, Andreas Blattmann, Dominik Lorenz, Patrick Esser et al.CVPR 2022 · 13,123 citations
- Score-Based Generative Modeling through Stochastic Differential EquationsYang Song, Jascha Sohl-Dickstein, Diederik P. Kingma, Abhishek Kumar et al.ICLR 2021 · 1,270 citations
- I2SB: Image-to-Image Schrödinger BridgeGuan-Horng Liu, Arash Vahdat, De-An Huang, Evangelos A. Theodorou et al.ICML 2023 · 252 citations
- Explaining in Style: Training a GAN to explain a classifier in StyleSpaceOran Lang, Yossi Gandelsman, Michal Yarom, Yoav Wald et al.ICCV 2021 · 181 citations
Related papers
- V-CECE: Visual Counterfactual Explanations via Conceptual EditsNikolaos Spanos, Maria Lymperaiou, Giorgos Filandrianos, Konstantinos Thomas et al.NeurIPS 2025 · 4 citations
- CounterNet: End-to-End Training of Prediction Aware Counterfactual ExplanationsHangzhi Guo, Thanh Hong Nguyen, Amulya YadavKDD 2023 · 12 citations
- Diffusion Visual Counterfactual ExplanationsMaximilian Augustin, Valentyn Boreiko, Francesco Croce, Matthias HeinNeurIPS 2022 · 124 citations
- Minimal-Perturbation Counterfactuals through Guided Denoising Diffusion for Recommender Systems ExplanationAmir Reza Mohammadi, Andreas Peintner, Michael M. Müller, Eva ZangerleSIGIR 2026 · 1 citation
- DiCoFlex: Model-Agnostic Diverse Counterfactuals with Flexible ControlOleksii Furman, Ulvi Movsum-zada, Patryk Marszalek, Maciej Zieba et al.NeurIPS 2025 · 3 citations
