Deconfounding to Explanation Evaluation in Graph Neural Networks

Explainability of graph neural networks ( GNNs ) aims to answer “ Why the GNN made a certain prediction ? ” , which is crucial to interpret the model prediction . The feature attribution framework distributes a GNN ’ s prediction to its input features ( e.g. , edges ) , identifying an influential subgraph as the explanation . When evaluating the explanation ( i.e. , subgraph importance ) , a standard way is to audit the model prediction based on the subgraph solely . However , we argue that a distribution shift exists between the full graph and the subgraph , causing the out-ofdistribution problem . Furthermore , with an in-depth causal analysis , we find the OOD effect acts as the confounder , which brings spurious associations between the subgraph importance and model prediction , making the evaluation less reliable . In this work , we propose Deconfounded Subgraph Evaluation ( DSE ) which assesses the causal effect of an explanatory subgraph on the model prediction . While the distribution shift is generally intractable , we employ the front-door adjustment and introduce a surrogate variable of the subgraphs . Specifically , we devise a generative model to generate the plausible surrogates that conform to the data distribution , thus approaching the unbiased estimation of subgraph importance . Empirical results demonstrate the effectiveness of DSE in terms of explanation fidelity . 1 INTRODUCTION . Explainability of graph neural networks ( GNNs ) ( Hamilton et al. , 2017 ; Dwivedi et al. , 2020 ) is crucial to model understanding and reliability in real-world applications , especially when about fairness and privacy ( Ying et al. , 2019 ; Luo et al. , 2020 ) . It aims to provide insight into how predictor models work , answering “ Why the target GNN made a certain prediction ? ” . Towards this end , a variety of explainer models are proposed for feature attribution ( Selvaraju et al. , 2017 ; Ying et al. , 2019 ; Luo et al. , 2020 ; Vu & Thai , 2020 ) , which decomposes the predictor ’ s prediction as contributions ( i.e. , importance ) of its input features ( e.g. , edges , nodes ) . While feature attribution assigns the features with importance scores , it redistributes the graph features and creates a new distribution different from that of the original full graphs , from which a subgraph is sampled as the explanation . Such sampling process is referred to as feature removal ( Covert et al. , 2020 ) . Then , to assess the explanatory subgraph , the current evaluation frameworks use the feature removal principle — ( 1 ) only feed the subgraph into the target predictor , discarding the other features ; ( 2 ) measure the importance of the subgraph based on its information amount to recover the model ’ s prediction . Such subgraph-prediction correlations uncovered by the removal-based evaluator should offer a faithful inspection of the predictor ’ s decision-making process and assess the fidelity of the explainers reliably . However , feature removal brings the out-of-distribution ( OOD ) problem ( Frye et al. , 2020 ; Chang et al. , 2019 ; Lukas Faber , 2021 ) : the distribution shift from full graphs to subgraphs likely violates underlying properties , including node degree distribution ( Leskovec et al. , 2005 ) and domain-specific constraints ( Liu et al. , 2018 ) of the full graphs . For example , graph properties of chemical molecules , such as the valency rules , impose some constraints on syntactically valid molecules ( Liu et al. , 2018 ) ; hence , simply removing some bonds ( edges ) or atoms ( nodes ) creates invalid molecular subgraphs that never appear in the training dataset . Such OOD subgraphs could manipulate the predictor ’ s Under review as a conference paper at ICLR 2022 𝑮 : Full Graph 𝑮𝒔 : Subgraph 𝒀 : Predicate Logits 𝐬 𝓖 House Cycle Crane 0.21 0.70 Target Predictor Crane 𝓖Cycle House𝓖𝒔𝟏𝑫 : Distribution Shift 𝓖𝒔𝟐 𝒔∗ 𝐬 Front-door Adjustment𝓖𝒔𝟐𝓖𝒔𝟏 ( a ) Feature Removal to Evaluate Explanatory Subgraph Gs 𝑮 : Full Graph 𝑮𝒔 : Subgraph 𝒀 : Predicate Logits 𝐬 𝓖 House Cycle Crane 0.21 0.70 Target Predictor Crane 𝓖Cycle House𝓖𝒔𝟏𝑫 : Distribution Shift 𝓖𝒔𝟐 𝒔∗ 𝐬 Front-door Adjustment𝓖𝒔𝟐𝓖𝒔𝟏 ( b ) SCM I Figure 1 : ( a ) A real example in TR3 . The GNN predictor classifies the full graph as ‘ House ” . On subgraphs Gs1 and Gs2 , the prediction probabilities of being “ House ” are respectively 0.21 and 0.70 . ( b ) The structural causal model represents the causalities among variables : G as the input graph , D as the unobserved distribution shift , Gs as the explanatory subgraph , and Y as the model prediction . outcome arbitrarily ( Dai et al. , 2018 ; Zügner et al. , 2018 ) , generates erroneous predictions , and limits the reliability of the evaluation process . Here we demonstrate the OOD effect by a real example in Figure 1a , where the trained ASAP ( Ranjan et al. , 2020 ) predictor has classified the input graph as “ House ” for its attached motif ( see Section 4 for more details ) . On the ground-truth explanation Gs1 , the output probability of the “ House ” class is surprisingly low ( 0.21 ) . While for Gs2 with less discriminative information , the outputs probability of the “ House ” class ( 0.70 ) is higher . Clearly , the removal-based evaluator assigns the OOD subgraphs with unreliable importance scores , which are unfaithful to the predictor ’ s decision . The OOD effect has not been explored in evaluating GNN explanations , to the best of our knowledge . We rigorously investigate it from a causal view ( Pearl et al. , 2016 ; Pearl , 2000 ; Pearl & Mackenzie , 2018 ) . Figure 1b represents our causal assumption via a structural causal model ( SCM ) ( Pearl et al. , 2016 ; Pearl , 2000 ) , where we target the causal effect of Gs on Y . Nonetheless , as a confounder between Gs and Y , distribution shift D opens the spurious path Gs ← D → Y . By “ spurious ” , we mean that the path lies outside the direct causal path from Gs to Y , making Gs and Y spuriously correlated and yielding an erroneous effect . And one can hardly distinguish between the spurious correlation and causative relations ( Pearl et al. , 2016 ) . Hence , auditing Y on Gs suffers from the OOD effect and wrongly evaluates the importance of Gs . Motivated by our causal insight , we propose a novel evaluation paradigm , Deconfounded Subgraph Evaluator ( DSE ) , to faithfully measure the causal effect of explanatory subgraphs on the prediction . 𝑮 : Full Graph 𝑮𝒔 : Subgraph 𝒀 : Predicate Logits 𝑮𝐬𝑮 𝒀 𝑫 𝑮𝒔∗ 𝑮𝐬𝑮 𝒀 𝑫 Front-door Adjustment reliably and further guide explainers to generate faithful explanations . In a nutshell , our contributions are : • From a causal perspective , we argue that the OOD effect is the confounder that causes spurious correlations between subgraph importance and model prediction . • We propose a deconfounding paradigm , DSE , which exploits the front-door adjustment to mitigate the out-of-distribution effect and evaluate the explanatory subgraphs unbiasedly . • We validate the effectiveness of our framework over various explainers , target GNN models , and datasets . Significant boosts are achieved over the conventional feature removal techniques . Code and datasets are available at : https : //anonymous.4open.science/r/DSE-24BC/ . 2 A CAUSAL VIEW OF EXPLANATION EVALUATION . Here we begin with the causality-based view of feature removal in Section 2.1 and present our causal assumption to inspect the OOD effect in Section 2.2 . 2.1 PROBLEM FORMULATION . Without loss of generality , we focus on the graph classification task : a well-trained GNN predictor f takes the graph variable G as input and predicts the class Y ∈ { 1 , · · · , K } , i.e. , Y = f ( G ) . Generation of Explanatory Subgraphs . Post-hoc explainability typically considers the question “ Why the GNN predictor f made certain prediction ? ” . A prevalent solution is building an explainer model to conduct feature attribution ( Ying et al. , 2019 ; Luo et al. , 2020 ; Pope et al. , 2019 ) . It decomposes the prediction into the contributions of the input features , which redistributes the probability of features according to their importance and sample the salient features as an explanatory subgraph Gs . Specifically , Gs can be a structure-wise ( Ying et al. , 2019 ; Luo et al. , 2020 ) or featurewise ( Ying et al. , 2019 ) subgraph of G. In this paper , we focus on the structural features . That is , for graph G = ( N , E ) with the edge set E and the node set N , the explanatory subgraph Gs = ( Ns , Es ) consists of a subset of edges Es ⊂ E and their endpoints Ns = { u , v| ( u , v ) ∈ Es } . Evaluation of Explanatory Subgraphs . Insertion-based evaluation by feature removal ( Covert et al. , 2020 ; Dabkowski & Gal , 2017 ) aims to check whether the subgraph is the supporting substructure 1 that alone allows a confident classification . We systematize this paradigm as three steps : ( 1 ) divide the full graph G into two parts , the subgraph Gs and the complement Gs ; ( 2 ) feed Gs into the target GNN f , while discarding Gs ; and ( 3 ) obtain the model prediction on Gs , to assess its discriminative information to recover the prediction on G. Briefly , at the core of the evaluator is the subgraphprediction correlation . However , as discussed in Section 1 , the OOD effect is inherent in the removal-based evaluator , hindering the subgraph-prediction correlation from accurately estimating the subgraph importance . 2.2 STRUCTURAL CAUSAL MODEL . To inspect the OOD effect rigorously , we take a causal look at the evaluation process with a Structural Causal Model ( SCM I ) in Figure 1b . We denote the abstract data variables by the nodes , where the directed links represent the causality . The SCM indicates how the variables interact with each other through the graphical definition of causation : • G→ Gs ← D. We introduce an abstract distribution shift variable D to sample a subgraph Gs from the edge distributions of the full graph G. • Gs → Y ← D. We denote Y as the prediction variable ( e.g. , logits output ) , which is determined by ( 1 ) the direct effect from Gs , and ( 2 ) the confounding effect caused by D. In particular , the former causation that led to the result is the focus of this work . We suggest readers to refer to Appendix A where we offer an elaboration of D. With our SCM assumption , directly measuring the importance of explanatory subgraphs is distracted by the backdoor path ( Pearl , 2000 ) , Gs ← D → Y . This path introduces the confounding associations between Gs and Y , which makes Gs and Y spuriously correlated , i.e. , biases the subgraph-prediction correlations , thus making the evaluator invalid . How to mitigate the OOD effect and quantify Gs ’ s genuine causal effect on Y remains largely unexplored in the literature and is the focus of our work .

Summary: In this paper, the authors use a causal view to investigate the OOD effect on the explanation evaluation of GNNs. They find the confounder between the extracted subgraphs and the model prediction, which makes the evaluation less reliable. To solve this problem, the authors proposed a deconfounding evaluation method based on the front-door adjustment from causal discovery. To generate a reliable surrogate subgraph, they proposed a generative model, which contains three losses for training. The experimental results show the effectiveness of the proposed method (DSE).