A squared-exponential kernel turns distance into similarity: nearby inputs receive large weights, while distant inputs receive rapidly smaller weights. It is useful when a model should emphasize what happens locally around one example. section 9.4.1
For a perturbed point x′ around an example x:
- Compute the distance D(x, x′), such as Euclidean distance. section 9.4.1
- Calculate πx(x′) = exp(−γ · D(x, x′)²). section 9.4.1
- Use the resulting weights to prioritize nearby samples when fitting a local linear surrogate. section 9.4.1
Figure 9.14 LIME creates a surrogate training set of examples in the locality of the example whose prediction needs to be explained. These examples are further weighted by their distance. This is indicated by the sizes of the surrogate examples, with closer examples getting higher weights (and shown larger). A weighted loss function is used to fit a linear surrogate model, which provides local explanations.
Visualizes locality through larger markers for closer samples and a weighted loss for the surrogate model. section 9.4.1

