A New Rejection Sampling Approach to $k$-$\mathtt{means}$++ With Improved Trade-Offs
Abstract
The -++ seeding algorithm (Arthur & Vassilvitskii, 2007) is widely used in practice for the -means clustering problem where the goal is to cluster a dataset into clusters. The popularity of this algorithm is due to its simplicity and provable guarantee of being competitive with the optimal solution in expectation. However, its running time is , making it expensive for large datasets. In this work, we present a simple and effective rejection sampling based approach for speeding up -++. Our first method runs in time while still being competitive in expectation. Here, is a parameter which is the ratio of the variance of the dataset to the optimal - cost in expectation and hides logarithmic factors in and . Our second method presents a new trade-off between computational cost and solution quality. It incurs an additional scale-invariant factor of in addition to the guarantee of -++ improving upon a result of (Bachem et al, 2016a) who get an additional factor of while still running in time . We perform extensive empirical evaluations to validate our theoretical results and to show the effectiveness of our approach on real datasets.
Keywords
Cite
@article{arxiv.2502.02085,
title = {A New Rejection Sampling Approach to $k$-$\mathtt{means}$++ With Improved Trade-Offs},
author = {Poojan Shah and Shashwat Agrawal and Ragesh Jaiswal},
journal= {arXiv preprint arXiv:2502.02085},
year = {2025}
}