Lune

NeurIPS2025Top-tier venue

A Single-Swap Local Search Algorithm for k-Means of Lines

Ting Liang, Xiaoliang Wu, Junyu Huang, Jianxin Wang, Qilong Feng

Abstract

Clustering is a fundamental problem that has been extensively studied over past few decades, with most research focusing on point-based clustering such as kmeans, k-median, and k-center. However, numerous real-world applications, such as motion analysis, computer vision, and missing data analysis, require clustering over structured data, including lines, time series and affine subspaces (flats), where traditional point-based clustering algorithms often fall short. In this paper, we study the k-means of lines problem, where the input is a set L of lines in R d , and the goal is to find k centers C in R d such that the sum of squared distances from each line in L to its nearest center in C is minimized. The local search algorithm is a well-established strategy for point-based k-means clustering, known for its efficiency and provable approximation guarantees. However, extending local search algorithm to the k-means of lines problem is nontrivial, as the capture relation used in point-based clustering does not generalize to the line setting. This is because that the point-to-line distance function lack the triangle inequality property that supports geometric analysis in point-based clustering. Moreover, since lines extend infinitely in space, it is difficult to identify effective swap points that can significantly reduce the clustering cost. To overcome above obstacles, we introduce a proportional capture relation that links optimal and current centers based the assignment proportions of lines, enabling a refined analysis that bypasses the triangle inequality barrier. We also introduce a CrossLine structure, which provides a principled discretization of the geometric space around line pairs, and ensures coverage of high-quality swap points essential for local search, thereby enabling effective execution of the local search process. Consequently, based on the proposed components, we develop the first single-swap local search algorithm for the k-means of lines problem, achieving a (500 + ε)-approximation in polynomial time for low-dimensional Euclidean space.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

Questions to start from

Lune can draw on

the full paper · related work

Get the answer

Free to start. No credit card required.

Lineage

  • Linear Time Algorithms for k-means with Multi-Swap Local Search cites Improved Guarantees for k-means++ and k-means++ Parallel
  • Linear Time Algorithms for k-means with Multi-Swap Local Search cites Improved approximations for Euclidean k-means and k-median, via nested quasi-independent sets
Builds onCited byLeft to right by year; the more cited, the higher.

Builds on4

  1. Improved Guarantees for k-means++ and k-means++ ParallelKonstantin Makarychev, Aravind Reddy, Liren ShanNeurIPS 2020 · 34 citations
  2. Improved approximations for Euclidean k-means and k-median, via nested quasi-independent setsVincent Cohen-Addad, Hossein Esfandiari, Vahab S. Mirrokni, Shyam NarayananSTOC 2022 · 15 citations
  3. Linear Time Algorithms for k-means with Multi-Swap Local SearchJunyu Huang, Qilong Feng, Ziyun Huang, Jinhui Xu et al.NeurIPS 2023 · 4 citations
  4. Coreset for Line-Sets ClusteringSagi Lotan, Ernesto Evgeniy Sanches Shayda, Dan FeldmanNeurIPS 2022 · 4 citations

Related papers

  1. Linear Time Algorithms for Individually Fair k-means via Multi-Swap Local SearchBeirong Cui, Qilong Feng, Junyu HuangAAAI 2026
  2. Local Search for Clustering in Almost-linear TimeShaofeng H.-C. Jiang, Yaonan Jin, Jianing Lou, Pinyan LuSODA 2026
  3. EPTAS for k-means Clustering of Affine SubspacesEduard Eiben, Fedor V. Fomin, Petr A. Golovach, William Lochet et al.SODA 2021 · 1 citation
  4. Consistent k-Clustering for General MetricsHendrik Fichtenberger, Silvio Lattanzi, Ashkan Norouzi-Fard, Ola SvenssonSODA 2021 · 7 citations
  5. Modified K-means Algorithm with Local Optimality GuaranteesMingyi Li, Michael R. Metel, Akiko TakedaICML 2025
Dusk over the sea between two cliffs drawn in fine vertical lines