本文针对加权 KNN 的 Data Shapley 计算难题,将其转化为计数问题,提出二次时间精确算法及保持公平性的确定性近似算法,并实验验证其效率与数据质量识别优势。
摘要:
本工作旨在解决数据估值文献中一个开放问题,即如何高效计算加权 K 最近邻算法的 Data Shapley(WKNN-Shapley)。通过将采用离散化权重的硬标签 KNN 的准确率作为效用函数,我们把 WKNN-Shapley 的计算重新表述为一个计数问题,并提出一种二次时间算法,相较现有文献中的最佳结果 O(N^K) 取得显著改进。我们还开发了一种确定性近似算法,在保持 Shapley 值关键公平性的同时进一步提升计算效率。大量实验表明,WKNN-Shapley 具有计算效率,并且在识别数据质量方面相较其未加权对应方法表现更优。
英文摘要:
This work aims to address an open problem in data valuation literature concerning the efficient computation of Data Shapley for weighted $K$ nearest neighbor algorithm (WKNN-Shapley). By considering the accuracy of hard-label KNN with discretized weights as the utility function, we reframe the computation of WKNN-Shapley into a counting problem and introduce a quadratic-time algorithm, presenting a notable improvement from $O(N^K)$, the best result from existing literature. We develop a deterministic approximation algorithm that further improves computational efficiency while maintaining the key fairness properties of the Shapley value. Through extensive experiments, we demonstrate WKNN-Shapley's computational efficiency and its superior performance in discerning data quality compared to its unweighted counterpart.
Computing the k Nearest-Neighbors for all Vertices via Dijkstra
给出了一个有向图$G = (V,E)$,图中的$n$顶点和$m$边都是正的,边的权值是正的,图的参数是$k >0$ .我们展示了如何计算,为每个顶点$v \in V$,其$k$最近的邻居。该算法在$O( k ( n \log n + m ) )$时间内运行,并对Dijkstra的最短路径算法进行了一定程度的修改。这个结果可能是民间传说,但我们无法找到它的参考资料-因此,这张纸条。