|
pulsatrix
|
KernelSHAP – model-agnostic Shapley value approximation via weighted linear regression (charter Part 1, Phase 3; theory: xai_context.aDNA's technique_shap.md). More...
#include <cstdint>#include <functional>#include <stdexcept>#include <string>#include <vector>#include "pulsatrix/assert.hpp"#include "pulsatrix/attribution.hpp"#include "pulsatrix/device_backend.hpp"#include "pulsatrix/tensor.hpp"#include "pulsatrix/weighted_linear_regression.hpp"
Go to the source code of this file.
Classes | |
| class | pulsatrix::KernelSHAP |
| Approximates Shapley values via full coalition enumeration + SHAP-kernel-weighted linear regression, reusing fit_weighted_linear_regression for the reduced (n-1)-dimensional problem the efficiency-axiom substitution produces. More... | |
Namespaces | |
| namespace | pulsatrix |
| namespace | pulsatrix::detail |
Functions | |
| double | pulsatrix::detail::BinomialCoefficient (int64_t n, int64_t k) |
| Binomial coefficient C(n,k), computed iteratively to avoid factorial overflow. | |
| float | pulsatrix::detail::ShapKernelWeight (int64_t n, int64_t coalition_size) |
| The SHAP kernel pi(z') = (n-1) / [C(n,|z'|) * |z'| * (n-|z'|)], for 1 <= |z'| <= n-1. | |
KernelSHAP – model-agnostic Shapley value approximation via weighted linear regression (charter Part 1, Phase 3; theory: xai_context.aDNA's technique_shap.md).