The code can be found here.
Note that this code is for the reproducible purpose. A wrapper for these modulars is on the plan.
This code is implemented using PaddlePaddle and InterpretDL. A demo using HuggingFace models and InterpretDL can be found here. A demo using Pytorch models and InterpretDL can be found here.
Paper:
Xuhong Li, Mengnan Du, Jiamin Chen, Yekun Chai, Himabindu Lakkaraju, Haoyi Xiong. “M4: A Unified XAI Benchmark for Faithfulness Evaluation of Feature Attribution Methods across Metrics, Modalities and Models.” Neurips 2023, Dataset and Benchmark Track. https://openreview.net/forum?id=6zcfrSz98y.