# Efficient Banzhaf-Based Data Valuation for $k$-Nearest Neighbors Classification

Source: [Efficient Banzhaf-Based Data Valuation for $k$-Nearest Neighbors Classification](<https://www.sota2.com/research/paper/6a0e91b3f984739ed6738c58>)

Collection index: [llms.txt](<https://www.sota2.com/research/llms.txt>)

Data updated: 2026-05-22T05:00:12.726Z

Authors: Guangyi Zhang, Lutz Oettershagen, Lixu Wang, Aristides Gionis

Published: 2026-05-20T11:10:15.000Z

## Abstract

Data valuation, the task of quantifying the contribution of individual data points to model performance, has emerged as a fundamental challenge in machine learning. Game-theoretic approaches, such as the Banzhaf value, offer principled frameworks for fair data valuation; however, they suffer from exponential computational complexity. We address this challenge by developing efficient algorithms specifically tailored for computing Banzhaf values in $k$-nearest neighbor ($k$NN) classifiers. We first establish the theoretical hardness of the problem by proving that it is \\#P-hard. Despite this intractability, we exploit the locality properties of $k$NN classifiers to develop practical exact algorithms. Our main contribution is a dynamic programming framework that achieves significant computational improvements: we present a pseudo-polynomial algorithm with $O(Wkn^2)$ time complexity for weighted $k$NN classifiers, where $W$ is the maximum sum of top-$k$ weights, and a specialized algorithm for unweighted $k$NN that achieves $O(nk^2)$ time complexity, that is, linear in the number of data points. We also offer efficient Monte Carlo estimation methods. Extensive experiments on real-world datasets demonstrate the practical efficiency of our approach and its effectiveness in data valuation applications.

## Recorded benchmark results

A research result applies to its stated dataset, split, metric and evaluation configuration. Compare like-for-like settings, preserve the metric's unit and direction, and distinguish paper-reported results from independent reproduction. The best result recorded here is not a claim of exhaustive, current global coverage.

- [Identifying mislabeled points on click](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-click.md>): Identifying mislabeled points; Click; Recall: 14.

- [Identifying mislabeled points on click (Precision)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-click-precision.md>): Identifying mislabeled points; Click; Precision: 7.

- [Identifying mislabeled points on click (F1 score)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-click-f1-score.md>): Identifying mislabeled points; Click; F1 Score: 9.

- [Identifying mislabeled points on creditcard (Recall)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-creditcard-recall.md>): Identifying mislabeled points; creditcard; Recall: 14.

- [Identifying mislabeled points on creditcard (Precision)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-creditcard-precision.md>): Identifying mislabeled points; creditcard; Precision: 7.

- [Identifying mislabeled points on creditcard (F1 score)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-creditcard-f1-score.md>): Identifying mislabeled points; creditcard; F1 Score: 9.

- [Identifying mislabeled points on apsfail (F1 score)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-apsfail-f1-score.md>): Identifying mislabeled points; apsfail; F1 Score: 21.

- [Identifying mislabeled points on apsfail](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-apsfail.md>): Identifying mislabeled points; apsfail; Recall: 27.

- [Identifying mislabeled points on apsfail (Precision)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-apsfail-precision.md>): Identifying mislabeled points; apsfail; Precision (apsfail): 14.

- [Identifying mislabeled points on phoneme (F1 score)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-phoneme-f1-score.md>): Identifying mislabeled points; phoneme; F1 Score: 27.

- [Identifying mislabeled points on cpu](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-cpu.md>): Identifying mislabeled points; CPU; Recall: 32.

- [Identifying mislabeled points on MNIST](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-mnist.md>): Identifying mislabeled points; MNIST; Recall: 45.

- [Identifying mislabeled points on cpu (Precision)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-cpu-precision.md>): Identifying mislabeled points; CPU; Precision: 16.

- [Identifying mislabeled points on MNIST (Precision)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-mnist-precision.md>): Identifying mislabeled points; MNIST; Precision: 23.

- [F1 score on Identifying mislabeled points on cpu](<https://www.sota2.com/research/sota/f1-score-on-identifying-mislabeled-points-on-cpu.md>): Identifying mislabeled points; CPU; F1 Score: 21.

- [F1 score on Identifying mislabeled points on MNIST](<https://www.sota2.com/research/sota/f1-score-on-identifying-mislabeled-points-on-mnist.md>): Identifying mislabeled points; MNIST; F1 Score: 30.

- [Identifying mislabeled points on wind (Recall)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-wind-recall.md>): Identifying mislabeled points; Wind; Recall: 36.

- [Identifying mislabeled points on wind (Precision)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-wind-precision.md>): Identifying mislabeled points; Wind; Precision (wind): 18.

- [Identifying mislabeled points on MNIST (AUC-ROC)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-mnist-auc-roc.md>): Identifying mislabeled points; MNIST; AUC-ROC: 11.

- [Identifying mislabeled points on phoneme (AUC-ROC)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-phoneme-auc-roc.md>): Identifying mislabeled points; phoneme; AUC-ROC: 15.

- [Identifying mislabeled points on vehicle (F1 score)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-vehicle-f1-score.md>): Identifying mislabeled points; vehicle; F1 Score: 15.

- [Identifying mislabeled points on wind (F1 score)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-wind-f1-score.md>): Identifying mislabeled points; Wind; F1 Score: 24.

- [Identifying mislabeled points on 2dplanes](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-2dplanes.md>): Identifying mislabeled points; 2Dplanes; Recall: 41.

- [Identifying mislabeled points on cifar10](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-cifar10.md>): Identifying mislabeled points; CIFAR10; Recall: 14.

- [Identifying mislabeled points on fraud](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-fraud.md>): Identifying mislabeled points; Fraud; Recall: 27.

- [Identifying mislabeled points on vehicle](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-vehicle.md>): Identifying mislabeled points; vehicle; Recall: 23.

- [Identifying mislabeled points (Precision) on 2dplanes](<https://www.sota2.com/research/sota/identifying-mislabeled-points-precision-on-2dplanes.md>): Identifying mislabeled points; 2Dplanes; Precision: 20.

- [Identifying mislabeled points on fraud (Precision)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-fraud-precision.md>): Identifying mislabeled points; Fraud; Precision: 14.

- [Identifying mislabeled points on vehicle (Precision)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-vehicle-precision.md>): Identifying mislabeled points; vehicle; Precision: 11.

- [Identifying mislabeled points on 2dplanes (F1 score)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-2dplanes-f1-score.md>): Identifying mislabeled points; 2Dplanes; F1 Score: 27.

- [Identifying mislabeled points on fraud (F1 score)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-fraud-f1-score.md>): Identifying mislabeled points; Fraud; F1 Score: 18.

- [Mislabel Detection on apsfail](<https://www.sota2.com/research/sota/mislabel-detection-on-apsfail.md>): Mislabel Detection; apsfail; AUROC: 0.22.

- [Identifying mislabeled points on phoneme (Recall)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-phoneme-recall.md>): Identifying mislabeled points; phoneme; Recall: 27.

- [Identifying mislabeled points on pol (Recall)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-pol-recall.md>): Identifying mislabeled points; POL; Recall (pol): 14.

- [Identifying mislabeled points on phoneme (Precision)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-phoneme-precision.md>): Identifying mislabeled points; phoneme; Precision: 14.

- [Identifying mislabeled points on pol (Precision)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-pol-precision.md>): Identifying mislabeled points; POL; Precision: 7.

- [Identifying mislabeled points on click (AUC-ROC)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-click-auc-roc.md>): Identifying mislabeled points; Click; AUC-ROC: 4.

- [Identifying mislabeled points on pol (F1 score)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-pol-f1-score.md>): Identifying mislabeled points; POL; F1 Score (pol): 9.

- [Misclassification Detection on CIFAR10](<https://www.sota2.com/research/sota/misclassification-detection-on-cifar10.md>): Misclassification Detection; CIFAR10; AUROC: 9.

- [Mislabel Detection on fraud](<https://www.sota2.com/research/sota/mislabel-detection-on-fraud.md>): Mislabel Detection; Fraud; AUROC: 11.

- [Identifying mislabeled points on creditcard (AUC-ROC)](<https://www.sota2.com/research/sota/identifying-mislabeled-points-on-creditcard-auc-roc.md>): Identifying mislabeled points; creditcard; AUC-ROC: 2.

- [Mislabel Detection on pol](<https://www.sota2.com/research/sota/mislabel-detection-on-pol.md>): Mislabel Detection; POL; AUROC: 0.06.

- [Mislabel Detection on wind](<https://www.sota2.com/research/sota/mislabel-detection-on-wind.md>): Mislabel Detection; Wind; AUROC: 12.

- [Mislabel Detection on 2dplanes](<https://www.sota2.com/research/sota/mislabel-detection-on-2dplanes.md>): Mislabel Detection; 2Dplanes; AUROC: 0.21.

- [Mislabel Detection on vehicle](<https://www.sota2.com/research/sota/mislabel-detection-on-vehicle.md>): Mislabel Detection; vehicle; AUROC: 0.08.

- [Mislabel Detection on cpu](<https://www.sota2.com/research/sota/mislabel-detection-on-cpu.md>): Mislabel Detection; CPU; AUROC: 5.

## Original sources and implementation

[Original paper](<https://arxiv.org/abs/2605.21033>)

[PDF](<https://arxiv.org/pdf/2605.21033.pdf>)
