Papers
Topics
Authors
Recent
Search
2000 character limit reached

Graph-Guided k-Means Clustering

Updated 7 July 2026
  • Graph-guided k-means clustering is a family of methods that integrates graph topology to refine centroid updates and assignments for non-Euclidean and manifold-structured data.
  • It fuses techniques from kernel, spectral, and Laplacian formulations to capture local geometry and optimize clustering through continuous relaxations and discrete assignments.
  • Recent advances focus on jointly learning graphs with cluster labels and incorporating acceleration methods to boost scalability and robustness on large complex datasets.

Graph-guided k-means clustering denotes a family of clustering methods in which graph structure guides the assignment, embedding, centroid update, or relation-extraction stages of k-means. Across the literature, the guiding graph may be an affinity graph over samples, a graph of pairwise cluster overlaps, a k-nearest-neighbor graph used to restrict centroid comparisons, a Laplacian defined on a lattice or manifold, a p-dual road-network graph, or the graph domain in which the clustered objects themselves are graphs (Lyu et al., 23 Sep 2025, Bauman et al., 2017, Deng et al., 2017, Tao et al., 2020, 0912.4598). The resulting formulations range from kernel and spectral relaxations of k-means to PageRank-based representative selection, centroid-free graph embedding, Laplacian-regularized soft assignments, and exact or approximate discrete optimization (Hajij et al., 2020, Li et al., 2024, Wang et al., 2014, Han et al., 2019).

1. Core concept and problem setting

Standard k-means partitions a dataset into KK clusters by minimizing the within-cluster sum of squares,

J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,

and returns hard assignments together with cluster centroids (Bauman et al., 2017). In its classical form, the method has no explicit notion of graph structure, manifold geometry, inter-cluster relations, or non-Euclidean similarity. Several later formulations therefore introduce a graph as an explicit computational and statistical object.

In graph-guided variants, the graph can intervene at different levels. An affinity graph over samples can define a Laplacian regularizer or a spectral embedding; a graph of clusters can represent pairwise overlaps after clustering; a k-nearest-neighbor graph can reduce the set of centroids considered during assignment; and a graph domain can replace Euclidean vectors altogether, so that centroids become graph means or central nodes rather than arithmetic averages (Lyu et al., 23 Sep 2025, Bauman et al., 2017, Deng et al., 2017, 0912.4598). This suggests that “graph-guided k-means” is best understood as a methodological family rather than a single algorithmic template.

A recurring motivation is that Euclidean centroid updates can be suboptimal when data lie on low-dimensional manifolds or have non-Euclidean structure. The graph then serves either as a proxy for local geometry, as a constraint on feasible partitions, or as an efficiency device. In some formulations the graph is fixed before clustering; in others it is learned jointly with assignments; in still others it is recovered from the clustering itself (Lyu et al., 23 Sep 2025, Kang et al., 2020).

2. Kernel, spectral, and Laplacian formulations

A central line of work treats graph-based clustering as a relaxation of kernel kk-means. With similarity matrix SKS \equiv K and normalized assignment matrix VV, kernel kk-means admits the maximization form

maxV0Tr(VSV)subject toVV1n=1n,  VV=Ik,\max_{V \ge 0} \operatorname{Tr}(V^\top S V) \quad \text{subject to} \quad V V^\top 1_n = 1_n,\; V^\top V = I_k,

together with the equivalent Frobenius formulation minV0SVVF2\min_{V \ge 0}\|S - V V^\top\|_F^2 under the same constraints (Lyu et al., 23 Sep 2025). “Graph-based Clustering Revisited: A Relaxation of Kernel kk-Means Perspective” identifies spectral clustering, symmetric NMF, and doubly stochastic normalization as relaxations that drop different subsets of the low-rank, nonnegative, doubly stochastic, and orthonormal constraints. On that basis it proposes LoRD, which keeps low-rank, nonnegativity, and doubly stochasticity while relaxing orthonormality, and B-LoRD, which adds block-diagonal regularization through γVF2\gamma \|V\|_F^2. The same work proves an equivalence between orthogonality and block diagonality under the doubly stochastic constraint, linearizes the doubly stochastic condition through a class-prior parameter J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,0, and derives a globally convergent projected gradient descent algorithm (Lyu et al., 23 Sep 2025).

Spectral graph partitioning supplies an older and closely related route. “Graph partitioning advance clustering technique” constructs the unnormalized Laplacian J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,1, computes the Fiedler vector J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,2 associated with the second smallest eigenvalue, and partitions by the sign of J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,3; for J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,4, it motivates the standard spectral J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,5-means pipeline in which one clusters the rows of the first J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,6 nontrivial eigenvectors (Madhulatha, 2012). “Spectral concentration and greedy J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,7-clustering” studies the normalized Laplacian J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,8, uses the embedding

J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,9

and proves recovery guarantees for strong partitions under a spectral-gap condition, while also showing a near-linear-time greedy alternative to spectral kk0-means (Dey et al., 2014).

Laplacian regularization can also be combined directly with centroid learning. “The Laplacian K-modes algorithm for clustering” optimizes

kk1

where kk2 is a simplex-constrained soft assignment matrix and kk3 contains Gaussian data-centroid affinities (Wang et al., 2014). The kk4-step is a convex quadratic program, while the kk5-step is a mean-shift update that makes each centroid a mode of a cluster density estimate. This yields valid patterns as centroids and supports highly nonconvex or manifold-structured clusters (Wang et al., 2014).

3. Jointly learning the graph and the labels

A major development in graph-guided k-means is the move from fixed graphs to jointly optimized graphs and assignments. “Structured Graph Learning for Clustering and Semi-supervised Classification” learns an affinity matrix kk6 by combining a global self-expressiveness term with an adaptive-neighbor term, while enforcing a Laplacian rank condition so that the learned graph has exactly kk7 connected components if there are kk8 clusters (Kang et al., 2020). The paper shows that, when kk9 is large enough to enforce the rank condition and SKS \equiv K0, its objective reduces to the sum of a kernel SKS \equiv K1-means objective in feature space and a standard SKS \equiv K2-means objective in input space. In that sense, the learned graph acts as a structural device that makes the spectral embedding “SKS \equiv K3-means friendly” (Kang et al., 2020).

“Unified Spectral Clustering with Optimal Graph” makes a similar critique of the standard three-step pipeline of graph construction, continuous label learning, and k-means discretization (Kang et al., 2017). It jointly learns the similarity matrix SKS \equiv K4, the spectral embedding SKS \equiv K5, the discrete indicator SKS \equiv K6, and an orthogonal rotation SKS \equiv K7, while driving the bottom SKS \equiv K8 eigenvalues of the Laplacian toward zero so that the similarity graph has exact SKS \equiv K9 connected components. Its multiple-kernel extension learns a convex combination of kernels rather than fixing one a priori (Kang et al., 2017). “Discrete Optimal Graph Clustering” pushes this line further by explicitly optimizing a discrete label matrix VV0 and replacing post hoc k-means discretization with a discrete transformation VV1, together with an adaptive robust prediction module for unseen data (Han et al., 2019). Both works treat k-means sensitivity in the discretization stage as a central weakness of older graph-based clustering pipelines (Kang et al., 2017, Han et al., 2019).

A related but distinct formulation appears in “Self-Supervised Graph Embedding Clustering,” which proves that standard k-means can be written in centroid-free graph form through VV2, then uses this observation to build a one-step self-supervised graph embedding framework (Li et al., 2024). In that framework, labels generated in low-dimensional space determine similarities between neighbors, and maximizing the VV3-norm of VV4 is shown to maintain class balance and enforce discrete labels. The two main variants, Our-LPP and Our-MFA, alternate between solving for a projection VV5 and updating the assignment matrix VV6 row by row (Li et al., 2024).

Deep graph representation learning brings the same theme into neural models. “Embedding Graph Auto-Encoder for Graph Clustering” proves that relaxed VV7-means obtains an optimal partition in the inner-products used space under non-negativity and spectral-dominance assumptions, then implements this view through a GCN-based encoder and dual decoders (Zhang et al., 2020). One decoder reconstructs the adjacency by VV8; the other optimizes the relaxed VV9-means objective kk0. The model alternates between updating encoder parameters and updating kk1 via the relaxed kk2-means solver, so that graph reconstruction and clustering are learned simultaneously (Zhang et al., 2020).

4. Graphs of cluster relations, constrained spaces, and non-Euclidean domains

Not all graph-guided formulations use the graph to regularize assignments. In “Discovering the Graph Structure in the Clustering Results,” pairwise overlapping k-means modifies the assignment rule so that each point may belong to one or two clusters and then derives a graph of inter-cluster relations from the resulting overlaps (Bauman et al., 2017). Its objective is

kk3

with kk4 controlling the overlap level. The relative overlap kk5 and kk6 are linked exactly by

kk7

and an edge between clusters kk8 and kk9 is created when maxV0Tr(VSV)subject toVV1n=1n,  VV=Ik,\max_{V \ge 0} \operatorname{Tr}(V^\top S V) \quad \text{subject to} \quad V V^\top 1_n = 1_n,\; V^\top V = I_k,0 (Bauman et al., 2017). The resulting graph is intended to capture structural connectivity that centroid distances may miss.

A more application-specific graph appears in “Graph Based Multi-layer K-means++ (G-MLKM) for Sensory Pattern Analysis in Constrained Spaces,” where targets move on a road network and each observation is only a velocity-time pair maxV0Tr(VSV)subject toVV1n=1n,  VV=Ik,\max_{V \ge 0} \operatorname{Tr}(V^\top S V) \quad \text{subject to} \quad V V^\top 1_n = 1_n,\; V^\top V = I_k,1 (Tao et al., 2020). The method first performs multi-layer k-means++ locally on each segment, then constructs a p-dual graph whose nodes are segment endpoints maxV0Tr(VSV)subject toVV1n=1n,  VV=Ik,\max_{V \ge 0} \operatorname{Tr}(V^\top S V) \quad \text{subject to} \quad V V^\top 1_n = 1_n,\; V^\top V = I_k,2 and maxV0Tr(VSV)subject toVV1n=1n,  VV=Ik,\max_{V \ge 0} \operatorname{Tr}(V^\top S V) \quad \text{subject to} \quad V V^\top 1_n = 1_n,\; V^\top V = I_k,3 and whose edges connect outgoing to incoming endpoints across intersections. Intersection-level pairing is performed after time alignment to a virtual reference, followed by error detection and Hungarian correction. The paper reports that, with maxV0Tr(VSV)subject toVV1n=1n,  VV=Ik,\max_{V \ge 0} \operatorname{Tr}(V^\top S V) \quad \text{subject to} \quad V V^\top 1_n = 1_n,\; V^\top V = I_k,4 and maxV0Tr(VSV)subject toVV1n=1n,  VV=Ik,\max_{V \ge 0} \operatorname{Tr}(V^\top S V) \quad \text{subject to} \quad V V^\top 1_n = 1_n,\; V^\top V = I_k,5, MLKM with error correction achieves maxV0Tr(VSV)subject toVV1n=1n,  VV=Ik,\max_{V \ge 0} \operatorname{Tr}(V^\top S V) \quad \text{subject to} \quad V V^\top 1_n = 1_n,\; V^\top V = I_k,6 average accuracy versus maxV0Tr(VSV)subject toVV1n=1n,  VV=Ik,\max_{V \ge 0} \operatorname{Tr}(V^\top S V) \quad \text{subject to} \quad V V^\top 1_n = 1_n,\; V^\top V = I_k,7 without error correction, and that full G-MLKM with error correction reaches maxV0Tr(VSV)subject toVV1n=1n,  VV=Ik,\max_{V \ge 0} \operatorname{Tr}(V^\top S V) \quad \text{subject to} \quad V V^\top 1_n = 1_n,\; V^\top V = I_k,8 average accuracy versus maxV0Tr(VSV)subject toVV1n=1n,  VV=Ik,\max_{V \ge 0} \operatorname{Tr}(V^\top S V) \quad \text{subject to} \quad V V^\top 1_n = 1_n,\; V^\top V = I_k,9 without error correction for minV0SVVF2\min_{V \ge 0}\|S - V V^\top\|_F^20 and minV0SVVF2\min_{V \ge 0}\|S - V V^\top\|_F^21 (Tao et al., 2020).

Graph-guided k-means can also mean replacing Euclidean centroids with graph-central representatives. “PageRank and The K-Means Clustering Algorithm” generalizes Lloyd’s procedure to directed and undirected graphs by assigning nodes through graph-distance Voronoi cells and then updating each cluster representative to the node with highest PageRank in the induced subgraph (Hajij et al., 2020). The paper emphasizes that this applies when there is no canonical arithmetic centroid, and it allows other centrality measures such as eigenvector, Katz, closeness, harmonic, or betweenness centrality in place of PageRank. It also states that the method does not introduce a scalar objective analogous to Euclidean sum-of-squares and does not provide a proven global potential function (Hajij et al., 2020).

5. Optimization, acceleration, and scalability

Several graph-guided methods are motivated as much by computational efficiency as by statistical structure. For LoRD and B-LoRD, the quadratic doubly stochastic constraint minV0SVVF2\min_{V \ge 0}\|S - V V^\top\|_F^22 is replaced by the linear convex constraints minV0SVVF2\min_{V \ge 0}\|S - V V^\top\|_F^23 and minV0SVVF2\min_{V \ge 0}\|S - V V^\top\|_F^24, and the projected gradient step

minV0SVVF2\min_{V \ge 0}\|S - V V^\top\|_F^25

is implemented with a Dykstra-style projection onto nonnegativity and affine constraints (Lyu et al., 23 Sep 2025). For dense minV0SVVF2\min_{V \ge 0}\|S - V V^\top\|_F^26, the per-iteration cost is minV0SVVF2\min_{V \ge 0}\|S - V V^\top\|_F^27; for sparse minV0SVVF2\min_{V \ge 0}\|S - V V^\top\|_F^28-NN graphs with minV0SVVF2\min_{V \ge 0}\|S - V V^\top\|_F^29, the total per-iteration cost becomes kk0, with memory kk1 for kk2 and kk3 for kk4 (Lyu et al., 23 Sep 2025).

“Fast kk5-means based on KNN Graph” uses an approximate k-nearest-neighbor graph to make the assignment cost independent of the total number of clusters (Deng et al., 2017). For each point kk6, the candidate centroid set kk7 is restricted to the clusters occupied by its kk8 nearest neighbors, so the assignment cost drops from kk9 to γVF2\gamma \|V\|_F^20, with γVF2\gamma \|V\|_F^21. The graph itself is refined by repeatedly clustering the data into many small clusters and performing local exhaustive neighbor updates within those clusters. On 10 million 512-dimensional data, the method takes only 5.2 hours to produce 1 million clusters, whereas traditional k-means is estimated to take 3 years for the same scale (Deng et al., 2017).

Acceleration has also been developed for clustering when the objects are graphs. “Elkan’s k-Means for Graphs” defines a permutation-invariant metric

γVF2\gamma \|V\|_F^22

uses subgradient-based sample-mean computation for graph centroids, and adapts Elkan’s triangle-inequality pruning through upper and lower bounds on graph distances (0912.4598). The pruning conditions use inequalities such as γVF2\gamma \|V\|_F^23 and γVF2\gamma \|V\|_F^24 to avoid unnecessary graph-distance evaluations. On the Fingerprint dataset with γVF2\gamma \|V\|_F^25, the paper reports γVF2\gamma \|V\|_F^26 per-iteration and γVF2\gamma \|V\|_F^27 total speedup, while on Molecules with γVF2\gamma \|V\|_F^28 it reports approximately γVF2\gamma \|V\|_F^29, indicating that acceleration depends strongly on the presence of cluster structure (0912.4598).

6. Emerging reinterpretations, empirical patterns, and limitations

Recent work extends the graph-guided k-means perspective into reasoning systems. “Clustering as Reasoning: A J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,00-Means Interpretation of Chain-of-Thought Graph Learning” proves a formal correspondence between a Transformer block and soft J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,01-means assignment/update dynamics on text-attributed graphs (Xie et al., 24 May 2026). Under a specific parameterization with centroid tokens and attention masking, the attention weights become

J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,02

which exactly matches soft J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,03-means assignments. The framework then combines structure-grounded neighbors, semantic neighbors, a Semantic Discriminating Prompt, and a CondNet gating mechanism; its alignment theorem states that the semantic-structural misalignment score satisfies J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,04, with J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,05 (Xie et al., 24 May 2026).

A common misconception is that graph-guided k-means is synonymous with spectral clustering followed by k-means. Several formulations instead learn the graph jointly with the partition, replace post hoc k-means discretization with Procrustes-type or explicitly discrete optimization, or eliminate explicit centroids altogether (Kang et al., 2017, Han et al., 2019, Li et al., 2024). Another misconception is that graph guidance always improves robustness. The literature repeatedly notes sensitivity to graph construction, neighborhood size, bandwidth parameters, and cluster imbalance. LoRD and B-LoRD share sensitivity to graph construction and may struggle when J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,06 is extremely noisy or when class priors are highly skewed and J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,07 is badly mismatched without tuning J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,08; the self-supervised graph embedding framework states that the J({μk},{Ck})=k=1KxCkxμk2,J(\{\mu_k\}, \{C_k\}) = \sum_{k=1}^K \sum_{x \in C_k} \|x-\mu_k\|^2,09-based balance mechanism may be undesirable for intrinsically imbalanced data (Lyu et al., 23 Sep 2025, Li et al., 2024).

Taken together, these works suggest three durable themes. First, graph guidance is used either to encode geometry, to learn a partition-compatible similarity, to recover relations between clusters, or to accelerate search. Second, the strongest recent formulations tend to narrow the gap between continuous relaxations and discrete assignments by enforcing low-rank, connected-component, orthogonality, or one-hot structure more explicitly. Third, there is no single privileged graph object: the relevant graph may be over samples, centroids, clusters, road segments, text-attributed nodes, or graphs themselves. In that broad sense, graph-guided k-means is less a single algorithm than a unifying viewpoint on how relational structure can reshape the classical assignment-and-update paradigm.

Topic to Video (Beta)

No one has generated a video about this topic yet.

Whiteboard

No one has generated a whiteboard explanation for this topic yet.

Follow Topic

Get notified by email when new papers are published related to Graph-Guided K-Means Clustering.