DataShapleyEvaluator<T>

Models & Types ยท AiDotNet.FederatedLearning.Fairness

Data Shapley evaluator: efficient Monte Carlo approximation of Shapley values.

Inheritance: FederatedLearningComponentBase<T> โ†’ DataShapleyEvaluator<T>

Implements: IClientContributionEvaluator<T>

For Beginners

Exact Shapley values require evaluating all possible subsets (2^N), which is impractical for more than ~15 clients. Data Shapley instead randomly samples client orderings (permutations) and averages the marginal contributions. With enough samples, it converges to the true Shapley value while running in polynomial time.

How It Works

How it works:

Recommended for: Federations with 10+ clients where exact Shapley is too expensive.

Constructors

Constructor Summary
DataShapleyEvaluator(ContributionEvaluationOptions options) Initializes a new instance of DataShapleyEvaluator.

Properties

Property Summary
string MethodName { get; }

Methods

Method Summary
Dictionary<int, double> EvaluateContributions(Dictionary<int, Tensor<T>> clientModels, Tensor<T> globalModel, Dictionary<int, List<Tensor<T>>> clientHistories)
HashSet<int> IdentifyFreeRiders(Dictionary<int, double> contributionScores)