LeGrad:一种基于特征形成敏感性的 Vision Transformers 可解释性方法
计算机视觉与模式识别
2025-01-09 v2
摘要
Vision Transformers (ViTs) 凭借其通过自注意力机制建模长程依赖的能力,已成为计算机视觉中的标准架构。然而,这些模型的可解释性仍然是一个挑战。为了解决这个问题,我们提出了 LeGrad,一种专门为 ViT 设计的可解释性方法。LeGrad 计算关于 ViT 各层注意力图的梯度,并将梯度本身视为可解释性信号。我们在所有层上聚合该信号,结合最后一层以及中间 token 的激活来生成合并的可解释性图。这使得 LeGrad 成为增强 ViT 透明度的概念上简单且易于实现的工具。我们在具有挑战性的分割、扰动和开放词汇设置中评估了 LeGrad,展示了其与其他 SotA 可解释性方法相比的多功能性,证明了其卓越的空间保真度和对扰动的鲁棒性。演示和代码可在 https://github.com/WalBouss/LeGrad 获取。
引用
@article{arxiv.2404.03214,
title = {LeGrad: An Explainability Method for Vision Transformers via Feature Formation Sensitivity},
author = {Walid Bousselham and Angie Boggust and Sofian Chaybouti and Hendrik Strobelt and Hilde Kuehne},
journal= {arXiv preprint arXiv:2404.03214},
year = {2025}
}
备注
Code available at https://github.com/WalBouss/LeGrad