# Explainable Artificial Intelligence: Advancements and Limitations
## 4 Visual Explanations
### Pixel Attribution
#### 4.2.3 Perturbation-Based Methodologies
It is rooted in the concept of Shapley values from cooperative game theory, where the goal is to fairly attribute the contribution to each player in a game based on their impact on the overall outcome. Applied to ML, SHAP assigns a value to each feature, representing its contribution to the final prediction for an individual instance. What makes SHAP particularly appealing is its theoretical rigour and  
Figure 4: The difference between LIME (**a**) and Anchors approaches (**b**). LIME fits the best possible linear line while anchors “guarantee” that almost all the examples satisfying the rules are from the same class. \(\mathcal{D}\) is the perturbation space for both approaches, the straight blue line is the linear model that LIME proposes, and the dashed box is the local area that the Anchor method “anchors” the explanations. (**a**) LIME. Adapted from [77]. (**b**) Anchors. Adapted from [78]. its ability to provide consistent, model-agnostic explanations, making it highly versatile across different types of ML models, from linear to deep learning architectures. This versatility is achieved through several specialised variants designed to enhance both efficiency and accuracy depending on the model type. For instance, Kernel SHAP is the most general version, allowing SHAP values to be computed for any ML model. However, it relies on a kernel-based approximation technique that samples many combinations of feature subsets, which can be computationally intensive, particularly for high-dimensional data. Despite its flexibility, Kernel SHAP's high computational cost often limits its scalability, especially for large datasets or complex models. To address these performance limitations, model-specific variants of SHAP have been developed, with Tree SHAP [96] standing out as a prominent example. Tailored for tree-based models like decision trees, random forests, and gradient boosting machines, Tree SHAP leverages the structure of these models to compute exact SHAP values much more efficiently than Kernel SHAP. This makes it an ideal choice for structured data, where tree-based models are often preferred due to their predictive power and interpretability. In a similar vein, Deep SHAP combines SHAP values with DeepLIFT [88] to provide efficient explanations for deep learning models. By utilising backpropagation, Deep SHAP makes it feasible to explain complex neural networks in a computationally efficient manner, which is critical for tasks involving unstructured data like images or text. These various SHAP variants highlight the method's remarkable adaptability across different ML models which helped SHAP to become one of the cornerstone techniques in XAI. Its versatility in offering both local explanations (detailing the contributions of individual features to specific predictions) and broader global insights (captured through aggregations across the entire model) makes it an invaluable tool for diagnosing model behaviour, ensuring fairness, and promoting accountability in ML systems. Perturbation-based XAI methodologies, such as SHAP and LIME, have gained considerable traction for their flexibility and ability to provide model-agnostic explanations. These methods excel at generating intuitive local explanations by estimating the contribution of individual features to a model's predictions, making them valuable tools for interpreting complex ML models. Their general applicability across different model types is a significant strength, allowing practitioners to apply them to a wide range of tasks without requiring specific model architecture knowledge. However, these methodologies are not without limitations. One significant challenge is their computational complexity. Estimating feature attributions often requires multiple model evaluations for various perturbed inputs, which can become infeasible for high-dimensional datasets or computationally expensive models. Another drawback is their reliance on assumptions about the data, such as feature independence, which is rarely true in real-world datasets.