Algorithm 1.
The dual explanation algorithm.
| Require: Training set ; the black-box model f; explainable point x0; the number of nearest neighbors K |
| Ensure: Important features of x0 (vector of the linear surrogate model coefficients) |
| 1: Determine a set of K nearest neighbors for x0 adding x0 itself |
| 2: Construct the largest convex hull of |
| 3: Find extreme points of and their number d ≤ K+1 |
| 4: Generate uniformly n points λ(j), j = 1, ..., n, from the unit simplex Δd−1 |
| 5: Find predictions zi of the black-box model in accordance with associated input for all i = 1, ..., n |
| 6: Construct a new dual dataset |
| 7: Train the linear regression (Equation 8) on dataset and find the vector of coefficients |
| 8: Find vector a by solving optimization problem (Equation 15) |