potentialpaper

Mini-batch kernel $k$-means

Ben Jourdan, Gregory Schwartzman

NeurIPS 2026

Edit this page

Or clone it with git

Run in a terminal:

Needs Git LFS. To push, use an API key from your profile as the password.

Or let your agent set it up

It checks and sets up everything: signing in, git, the clone, credentials and an SSH key.

Abstract. We present the first mini-batch kernel kk-means algorithm, offering an order of magnitude improvement in running time compared to the full batch algorithm. A single iteration of our algorithm takes O~(kb2)\widetilde{O}(kb^2) time, significantly faster than the O(n2)O(n^2) time required by the full batch kernel kk-means, where nn is the dataset size and bb is the batch size. Extensive experiments demonstrate that our algorithm consistently achieves a 10-100x speedup with minimal loss in quality, addressing the slow runtime that has limited kernel kk-means adoption in practice. We further complement these results with a theoretical analysis under an early stopping condition, proving that with a batch size of Ω~(kϵ−2)\widetilde{\Omega}(k\epsilon^{-2}), the algorithm terminates in O(1/ϵ)O(1/\epsilon) iterations with high probability (assuming without loss of generality the kernel is normalized), where ϵ\epsilon is a termination threshold. Our analysis holds for any reasonable center initialization, and when using kk-means++ initialization, the algorithm achieves an approximation ratio of O(log⁡k)O(\log k) in expectation. Taking ϵ=O(1)\epsilon = O(1) and b=Θ(klog⁡n)b=\Theta(k\log n), the algorithm terminates in O(1)O(1) iterations, with each iteration running in O~(k3)\widetilde{O}(k^3) time.

Are you an author? Claim this paper to see who's reading it, with views and other statistics, and to write about it here.

Claim this paper
How does this paper connect to your work? Write how you built on it, compared with it or reproduced it, or add a summary, a critique or errata.
Or make it interactive:
Start writing

edit · history

FromAToBDateVersionSubmitted toPDFEvidence
25 Sep 2024ICLR 2025submittedICLR 2025Rejected—[1]
10 May 2025NeurIPS 2025submittedNeurIPS 2025Rejected—[1]
19 Sep 2025ICLR 2026submittedICLR 2026Rejected—[1]
2 May 2026NeurIPS 2026submittedNeurIPS 2026Accept (poster)reviews ↓[1]PDF[1]
Their titles, abstracts and, where both have a PDF, the text.Missing a version?

NeurIPS 2026

Accept (poster) · 3 reviews · OpenReview

Updated 25 Nov 2026, 03:42 UTC.

Program Chairs · DecisionOpenReview ↗
Decision
Accept (poster)
Read decision
Meta-review

This paper introduces the first mini-batch algorithm for kernel kk-means allowing a speedup in practice of over an order of magnitude compared, which overcomes one of the main criticisms of kernel kk-means. The method is backed by theoretical analysis and shows competitive runtime and clustering accuracy on real-world datasets.

The strengths of the paper as pointed out by the reviewers are: originality and novelty on applying mini-batch optimization to kernel kk-means, theoretical guarantees and methods are appreciated, the writeup conveys the main intuition of the algorithm nicely and the experiments are spot on to demonstrate the promised speedups.

However, the reviewers point out a few points on confusion and suggestions for improvement. Notably, but not limited to:

  • Reviewer 8JWS commented that the error tolerance parameter (ϵ\epsilon) and its dependence on γ\gamma make the complexity analysis a bit unintuitive, and suggest a way of simplifying the analysis. In their rebuttal, the authors incorporated the reviewer's suggestion regarding on-the-fly kernel normalization (setting γ=1/2\gamma = 1/2) and provided explicit overall time complexity bounds in terms of ϵ−1\epsilon^{-1} and log⁡(ϵ−1)\log(\epsilon^{-1}).
  • Reviewer hCyZ points out some difficulties in following Lemma 4.1, that not all claims of Theorem 1.1 are addressed, and raises some questions to the authors. The authors addressed the reviewer's concerns by (i) providing a detailed and expanded proof for Lemma 4.1 that tightened the dependence on the logarithmic term from quadratic to linear, (ii) explicitly mapping the proofs for all three claims of Theorem 1.1 in the appendix, and (iii) clarifying the use of the kernel trick for center updates.
Final justification

The paper presents a valuable algorithmic contribution to scalable kernel kk-means clustering. The reviewers unanimously recommend acceptance, and the authors have committed to incorporating all discussed clarifications into the camera-ready version. I recommend acceptance as a poster.

Area Chair bwqN · Meta-reviewOpenReview ↗
Read meta-review
Meta-review

This paper introduces the first mini-batch algorithm for kernel kk-means allowing a speedup in practice of over an order of magnitude compared, which overcomes one of the main criticisms of kernel kk-means. The method is backed by theoretical analysis and shows competitive runtime and clustering accuracy on real-world datasets.

The strengths of the paper as pointed out by the reviewers are: originality and novelty on applying mini-batch optimization to kernel kk-means, theoretical guarantees and methods are appreciated, the writeup conveys the main intuition of the algorithm nicely and the experiments are spot on to demonstrate the promised speedups.

However, the reviewers point out a few points on confusion and suggestions for improvement. Notably, but not limited to:

  • Reviewer 8JWS commented that the error tolerance parameter (ϵ\epsilon) and its dependence on γ\gamma make the complexity analysis a bit unintuitive, and suggest a way of simplifying the analysis. In their rebuttal, the authors incorporated the reviewer's suggestion regarding on-the-fly kernel normalization (setting γ=1/2\gamma = 1/2) and provided explicit overall time complexity bounds in terms of ϵ−1\epsilon^{-1} and log⁡(ϵ−1)\log(\epsilon^{-1}).
  • Reviewer hCyZ points out some difficulties in following Lemma 4.1, that not all claims of Theorem 1.1 are addressed, and raises some questions to the authors. The authors addressed the reviewer's concerns by (i) providing a detailed and expanded proof for Lemma 4.1 that tightened the dependence on the logarithmic term from quadratic to linear, (ii) explicitly mapping the proofs for all three claims of Theorem 1.1 in the appendix, and (iii) clarifying the use of the kernel trick for center updates.
Final justification

The paper presents a valuable algorithmic contribution to scalable kernel kk-means clustering. The reviewers unanimously recommend acceptance, and the authors have committed to incorporating all discussed clarifications into the camera-ready version. I recommend acceptance as a poster.

Reviewer hCyZOpenReview ↗
Rating
5/6
Confidence
4/5
Quality
4/4
Clarity
4/4
Significance
3/4
Originality
3/4
Contribution type
general
Ethical concerns
NO or VERY MINOR ethics concerns only
Read review
Summary

This paper introduces a new method of applying the mini-batch k-means algorithm to kernelized k-means. To save computation, it proposes a way of truncating which points are consideration if they were used in batches too far in the past. The paper gives theoretical and experimental results.

Strengths and weaknesses
  • The examples in figure 2 are not highly compelling. The image segmentations are fairly noisy, and it's unclear how many clusters are being used.

  • There has been work to accelerate kernel k-means with distance bounds (using triangle inequalities to bound how center movements affect point-center distances), and I think that that work could possibly combine with mini-batch k-means. It would be good to mention this as well.

  • Line 61: "Applying the mini-batch approach for kernel k-means is even more difficult because the assumption that cluster centers are always the mean of some subset of X in feature space no longer holds." -- this is an incorrect, or at least misleading, statement. The centers are the mean of some subset of X that has been mapped to the feature space H.

  • "This is a considerable speedup compared to the best known quadratic update time." This is true because b < n, but it is not because of the derivation (which is how the sentence reads). The asymptotic complexity of O(n(b+k)) is really no different than the standard quadratic formulation. In other words, if b = n, then they have the same asymptotic complexity of O(n^2).

  • Line 202: "from i to i-t" -- it feels more natural to me to use increasing order, so "from i-t to i" would read better.

  • Line 203: "It is the case that ... <= \tau + b" -- this is not obvious to me.

  • The proof of Lemma 4.1 is unclear:

    • what allows the first equality?
    • explain why the product (inside the norm) is upper-bounded by e^{-\sum}
    • it's not clear at all why \sqrt{\tau / b} is greater than or equal to \ln(28\gamma / \epsilon).
    • the second-to-last quantity has \ln(\epsilon / 28 \gamma), which could be misinterpreted as \ln((\epsilon / 28) \gamma). Extra parentheses would help here.
  • Somehow I read almost the entire paper before I realized that the proposed algorithm is keeping explicit representations for the cluster centers in the feature space (rather than employing the kernel trick). This point is made around line 61, but that point is much too subtle (and I disagreed with it the first time I read it, so I thought that the claim was incorrect). The point needs to be justified and emphasized. Further, it becomes unclear how something like an infinite-dimensional feature space (e.g. with a Gaussian kernel) could be used with the proposed formulation without the kernel trick.

    The proposed algorithm can be implemented via the kernel trick. Suppose that c represents the previous center, and c' represents the center of mass based on a new batch. Then ||x - a*c - (1-a)c'||^2 can be written using only inner products between x, the points that comprise c, and the points that comprise c'. And the proposed algorithm could still truncate "old" points (those whose contribution disappears) in much the same way (by pruning the members of the old "c"). This would permit the algorithm to use the kernel trick exclusively.

  • The paper defines f_x(C), but never uses it in the paper (only in the appendix).

  • There are 3 claims given in Theorem 1.1, but after reading the paper only the first claim appears to be addressed in the paper (but not proven). The second claim is not addressed within the paper itself (it is in the appendix). The third claim is never supported in either.

  • There is no conclusion section in the paper.

  • The paper claims that the algorithm halts in O(1) iterations, but does not provide an experimental evaluation of that claim (all experiments run for a fixed number of iterations).

Questions

The key question I have is about whether the proposed algorithm actually uses the kernel trick, or instead keeps explicit centers in the feature space. The exposition of the paper leaves this unclear to me.

Limitations

The primary limitation of this paper is how effectively it can communicate the correctness of the proposed method, as well as the method with clarity enough to replicate the work (see my comments earlier about being uncertain about use of the kernel trick).

Final justification

I have considered the rebuttals from the authors, especially the clarifications on the kernel trick and the proof of Lemma 4.1.

Formatting concerns

Typo on line 127: "The authors do not"

1 comment
Authors · RebuttalOpenReview ↗
Rebuttal

Thank you for the positive evaluation and constructive feedback.

Reviewer comment: The examples in Figure 2 are not highly compelling.

We would be happy to remove this figure if that is the consensus of the reviewers. In previous iterations, we were advised to include a qualitative demonstration of the difference between kk-means and kernel kk-means. The number of clusters shown in the figure was taken from the number of ground-truth clusters.

Reviewer comment: There has been work to accelerate kernel k-means with distance bounds (using triangle inequalities to bound how center movements affect point-center distances), and I think that that work could possibly combine with mini-batch k-means. It would be good to mention this as well.

We would be happy to reference this work. Are you referring to Section 5 of Kernel k-means, Spectral Clustering and Normalized Cuts?

Reviewer comment: “Applying the mini-batch approach to kernel kk-means is even more difficult because the assumption that cluster centers are always the mean of some subset of XX in feature space no longer holds.” This is incorrect, or at least misleading. The centers are the mean of some subset of XX that has been mapped to the feature space H\mathcal{H}.

You are correct for full-batch kernel kk-means and for the initial centers of mini-batch kernel kk-means when using kk-means++ initialization. However, after the mini-batch updates begin, the learning-rate-weighted centers are not generally equal to the unweighted mean of a subset of the input points. Instead, each center moves only part of the way towards the corresponding batch mean.

Reviewer comment: “This is a considerable speedup compared to the best-known quadratic update time.” This is true because b<nb<n, but it is not a consequence of the derivation, which is how the sentence currently reads. The asymptotic complexity of O(n(b+k))O(n(b+k)) is not fundamentally different from the standard quadratic formulation. In particular, if b=nb=n, both have complexity O(n2)O(n^2).

We will revise the wording to make clear that the speedup comes from operating in the regime b≪nb\ll n, rather than from the algebraic derivation alone. In the regime established by Theorem 1.1, bb grows only logarithmically with nn. Thus, the case b=nb=n is not the regime targeted by our theoretical result.

Reviewer comment: Line 202: “from ii to i−ti-t.” It feels more natural to use increasing order, so “from i−ti-t to ii” would read better.

We will change this.

Reviewer comment: Line 203: “It is the case that ... ≤τ+b\leq\tau+b.” This is not obvious to me.

This is by the definition of QijQ_i^j to be the smallest set of consecutive t indices up to i such that cluster j had at least tau points assigned. The upper bound follows because to achieve at least tau points we may include up to an extra b points in the sum (that is bij≤bb_i^j \leq b for all i,j). For example, assume both b=10 and τ=20\tau=20, then for some i it might be the case that bij=10b_i^j =10 and bi−1j=9b_{i-1}^j =9 and then the sum contains also bi−2jb_{i-2}^j which is at most 10.

Reviewer comment: The proof of Lemma 4.1 is unclear.

You are right that the proof should be clearer. We provide a detailed proof at the end of this rebuttal and will add it to the final version of the paper. The revised proof also reduces the dependence of τ\tau on the logarithmic term from quadratic to linear.

Reviewer comment: The second-to-last quantity contains ln⁡(ϵ/28γ)\ln(\epsilon/28\gamma), which could be misinterpreted as ln⁡((ϵ/28)γ)\ln((\epsilon/28)\gamma). Extra parentheses would help.

We will add the parentheses.

Reviewer comment: Somehow I read almost the entire paper before I realized that the proposed algorithm is keeping explicit representations for the cluster centers in the feature space (rather than employing the kernel trick). This point is made around line 61, but that point is much too subtle (and I disagreed with it the first time I read it, so I thought that the claim was incorrect). The point needs to be justified and emphasized. Further, it becomes unclear how something like an infinite-dimensional feature space (e.g. with a Gaussian kernel) could be used with the proposed formulation without the kernel trick.

The proposed algorithm can be implemented via the kernel trick. Suppose that c represents the previous center, and c' represents the center of mass based on a new batch. Then ∣∣x−a∗c−(1−a)c′∣∣2||x - a*c - (1-a)c'||^2 can be written using only inner products between x, the points that comprise c, and the points that comprise c'. And the proposed algorithm could still truncate "old" points (those whose contribution disappears) in much the same way (by pruning the members of the old "c"). This would permit the algorithm to use the kernel trick exclusively.

We're not quite sure what you mean. We only store the linear combination coefficients for each centre, and don't try to represent points in feature space explicitly; this makes implementing our algorithm straightforward with the kernel trick. I think we are agreeing on the same thing but please elaborate if we are wrong.

Reviewer comment: The paper defines fx(C)f_x(C) but never uses it in the main paper; it is used only in the appendix.

We will move this definition to the appendix.

Reviewer comment: Theorem 1.1 contains three claims. After reading the paper, only the first appears to be addressed in the main paper, although it is not proved there. The second is addressed only in the appendix, and the third does not appear to be supported in either location.

All three claims are proved, but you are right that their locations are not identified clearly:

  1. Claim 1 is proved in Appendix A.
  2. Claim 2 is proved in Appendix B.
  3. Claim 3 is proved in Appendix B as Lemma B.13.

We will make these references explicit in the final version of the paper.

Reviewer comment: There is no conclusion section in the paper.

We will add a conclusion section.

Reviewer comment: The paper claims that the algorithm halts after O(1)O(1) iterations but does not experimentally evaluate that claim, as all experiments use a fixed number of iterations.

We thought running each algorithm for 200 iterations would be the fairest and most intuitive approach as this was almost certainly long enough for each method to converge. We did consider using early stopping for comparison instead, but controlling the effect of early stopping across the full batch and mini-batch algorithms with various batch sizes is not obvious. If you have a specific experimental evaluation in mind, we will be happy to add it.

Expanded proof of Lemma 4.1

Lemma 4.1. Setting $ \tau=\left\lceil b\ln\left(\frac{28\gamma}{\epsilon}\right)\right\rceil$, it holds that, for every i∈Ni\in\mathbb{N} and j∈[k]j\in[k],

∥C^i+1j−Ci+1j∥≤ϵ28.\left\Vert\widehat{\mathcal{C}}_{i+1}^j-\mathcal{C}_{i+1}^j\right\Vert\leq\frac{\epsilon}{28}.

Proof. Recall that QijQ_i^j is the shortest consecutive suffix of iterations ending at iteration ii during which at least τ\tau points were assigned to cluster jj. Thus, min⁡Qij\min\\{Q_i^j\\} is the earliest iteration retained in the truncated center. If min⁡Qij=1\min\\{Q_i^j\\}=1, then the truncated center equals the full center by definition, and the claim follows immediately. We therefore consider the remaining case, in which

min⁡Qij>1and∑ℓ∈Qijbℓj≥τ.\min\\{Q_i^j\\}>1 \qquad\text{and}\qquad \sum_{\ell\in Q_i^j}b_\ell^j\geq\tau.

At each iteration ℓ\ell, the center update is $ \mathcal{C}_{\ell+1}^j=(1-\alpha_\ell^j)\mathcal{C}_\ell^j+\alpha_\ell^j\operatorname{cm}(B_\ell^j). $ Starting from Ci+1j\mathcal{C}_{i+1}^j, we repeatedly substitute the update rule backwards through the iterations in QijQ_i^j, stopping at min⁡Qij\min\\{Q_i^j\\}. This gives

Ci+1j=Cmin⁡Qijj∏ℓ∈Qij(1−αℓj)+∑ℓ∈Qijαℓjcm⁡(Bℓj)∏z∈Qij,,z>ℓ(1−αzj).\mathcal{C}_{i+1}^j=\mathcal{C}_{\min\\{Q_i^j\\}}^j\prod_{\ell\in Q_i^j}(1-\alpha_\ell^j)+\sum_{\ell\in Q_i^j}\alpha_\ell^j\operatorname{cm}(B_\ell^j)\prod_{z\in Q_i^j,\\,z>\ell}(1-\alpha_z^j).

The first term is the contribution of the center from before the retained updates. The truncated center discards exactly this term and retains the sum:

C^i+1j=∑ℓ∈Qijαℓjcm⁡(Bℓj)∏z∈Qij,,z>ℓ(1−αzj).\widehat{\mathcal{C}}_{i+1}^j=\sum_{\ell\in Q_i^j}\alpha_\ell^j\operatorname{cm}(B_\ell^j)\prod_{z\in Q_i^j,\\,z>\ell}(1-\alpha_z^j).

Therefore, the identical sums cancel when the two centers are subtracted:

∥C^i+1j−Ci+1j∥=∥Cmin⁡Qijj∏ℓ∈Qij(1−αℓj)∥.\left\Vert\widehat{\mathcal{C}}_{i+1}^j-\mathcal{C}_{i+1}^j\right\Vert=\left\Vert\mathcal{C}_{\min\\{Q_i^j\\}}^j\prod_{\ell\in Q_i^j}(1-\alpha_\ell^j)\right\Vert.

Using 1−x≤e−x1-x\leq e^{-x}, we obtain

∥C^i+1j−Ci+1j∥≤∥Cmin⁡Qijj∥exp⁡(−∑ℓ∈Qijαℓj).\left\Vert\widehat{\mathcal{C}}_{i+1}^j-\mathcal{C}_{i+1}^j\right\Vert\leq\left\Vert\mathcal{C}_{\min\\{Q_i^j\\}}^j\right\Vert\exp\left(-\sum_{\ell\in Q_i^j}\alpha_\ell^j\right).

Here, the inequality 1−x≤e−x1-x\leq e^{-x} is applied to each x=αℓjx=\alpha_\ell^j.

For every ℓ\ell, we have

αℓj=bℓjb.\alpha_\ell^j=\sqrt{\frac{b_\ell^j}{b}}.

Since 0≤bℓj/b≤10\leq b_\ell^j/b\leq1, it follows that

bℓjb≥bℓjb.\sqrt{\frac{b_\ell^j}{b}}\geq\frac{b_\ell^j}{b}.

Therefore,

∑ℓ∈Qijαℓj=∑ℓ∈Qijbℓjb≥∑ℓ∈Qijbℓjb≥τb≥ln⁡(28γϵ).\sum_{\ell\in Q_i^j}\alpha_\ell^j=\sum_{\ell\in Q_i^j}\sqrt{\frac{b_\ell^j}{b}}\geq\sum_{\ell\in Q_i^j}\frac{b_\ell^j}{b}\geq\frac{\tau}{b}\geq\ln\left(\frac{28\gamma}{\epsilon}\right).

The second-to-last inequality follows from the definition of QijQ_i^j, and the last follows from $\tau=\left\lceil b\ln\left(\frac{28\gamma}{\epsilon}\right)\right\rceil. $ Finally, Cmin⁡Qijj\mathcal{C}_{\min\\{Q_i^j\\}}^j is a convex combination of points in XX, so its norm is at most γ\gamma. Therefore,

∥Cmin⁡Qijj∥exp⁡(−∑ℓ∈Qijαℓj)≤γexp⁡(−ln⁡(28γϵ))=ϵ28.\left\Vert\mathcal{C}_{\min\\{Q_i^j\\}}^j\right\Vert\exp\left(-\sum_{\ell\in Q_i^j}\alpha_\ell^j\right)\leq\gamma\exp\left(-\ln\left(\frac{28\gamma}{\epsilon}\right)\right)=\frac{\epsilon}{28}.
Reviewer SVAPOpenReview ↗
Rating
5/6
Confidence
4/5
Quality
3/4
Clarity
3/4
Significance
3/4
Originality
4/4
Contribution type
general
Ethical concerns
NO or VERY MINOR ethics concerns only
Read review
Summary

The authors provided the first mini-batch kernel k means algorithm. While preserving performances similar to the regular kernel k means algorithm, the authors' method is significantly faster. The authors also provided theoretical guarantees and experiments on 4 real datasets to illustrate the accuracy and speed of their method.

Strengths and weaknesses

One strength of the paper is its originality. I was not able to find other papers that combined mini-batch and kernel k means. Regarding fundamental papers in each area, I think the authors properly cited the fundamental work in mini-batch k means, Sculley 2010 Web-scale k-means clustering, and also the fundamental work in kernel k means, Dhillon 2004 Kernel k-means, Spectral Clustering and Normalized Cuts.

Another strength of the paper is its significance. I think the authors did a great job in providing Figure 1 to illustrate the need to kernel k-means (as otherwise Sculley 2010 would be sufficient for practical purposes), and also providing Figure 2 to show their method’s improvement over the standard kernel k-means.

The paper also described most of the intuition of the algorithms well, for example on line 180. This significantly increased clarity and made it a lot easier to grasp the main ideas of the two algorithms.

I don’t think the paper has any significant weaknesses. I do have some suggestions that might be worth considering:

On line 201, when considering truncating the centers, there is the important parameter τ\tau. Line 209 showed that when τ\tau is sufficiently large theoretical guarantees hold, and also in the Discussion on line 258 it was said that even small values of τ\tau works. What would be a good value of tau in practical situations, or equivalently, how should we determine the value of tau given a dataset? (for example, how was the value 50 selected on line 265)? It looks from line 230 that τ\tau should be a lot smaller than b.

The batch size b is an input on line 172, and Algorithm 1 and Algorithm 2. How is the batch size, b, determined in practice? And how will the value of b affect computational speed or result accuracy?

On line 181, it might be helpful to define Ci+1jC_{i+1}^j (even though the reader might already inferred what it is).

On line 185, second from last line, the inner product can be commutative only when both inputs are real numbers right? (which should be the case here)

On line 186, it is claimed that “Furthermore, it is possible to use dynamic programming to update the center”. I think it would be really helpful to give an intuition of the dynamic programming algorithm here.

Some algebra in this paper is above my current level. For example I was not able to fully understand the proof on line 213, or where the value 28 came from on line 212.

To the best of my knowledge, I did not find significant errors in Algorithm 1 and Algorithm 2, as well as the computational time of O(k(τ+b)2)O(k(\tau+b)^2) on line 230.

Questions

On lines 254 and 255, would it be possible if you can be a bit more detailed on what accuracy scores are here? For example does accuracy here means how well the clustering result matched the actual label, or does it mean something else?

On top of page 9, in the plot mnist_784, it seems that by using β\beta-minibatch kernel, the ARI, NMI, ACC criterion showed the mini-batch version actually outperformed the regular kernel version. Could you please provide some insight on how an algorithm using a subset of the data can actually outperform an algorithm using the entire dataset?

Limitations

I did not find the authors directly discussing the limitations. I want to ask if there could be a possible (maybe uncommon) situation where mini-batch kernel k means could lead to poor results compared regular kernel k means? In addition, would there be a situation where only regular kernel k means could be used (and mini-batch kernel k means cannot be used)? Thank you.

Final justification

Thank you to the authors for their response on my comments.

I would like to keep my rating of 5: Accept.

The authors addressed many of my questions, including the one on the selection of the value of τ\tau, which could be for a future study. The authors also agreed to modifications (for example agreed to clarify Ci+1jC_{i+1}^j on line 181 and adding a note on the Hungarian algorithm on lines 254,255).

I might be missing something here but did not fully understand the reason why "using mini-batches can allow us to escape bad local minima". It would be really helpful for the authors to elaborate a bit more on this point (this is a question regarding the top of page 9, in the mnist_784 plot, the ARI, NMI, and ACC criteria appear to show that the mini-batch kernel version outperformed the regular kernel version). However, I still think the current paper (with the modifications the authors mentioned) is a good paper.

Formatting concerns

I did not find formatting concerns.

4 comments
Authors · RebuttalOpenReview ↗
Rebuttal

Thank you for the positive evaluation and constructive feedback.

Reviewer comment: What would be a good value of τ\tau in practical situations, or, equivalently, how should we determine the value of τ\tau for a given dataset?

This is an excellent question. We don't really know and this would be an interesting topic for future work. If we had to guess, it may be because many clusters in real world kernel spaces follow the low dimensional manifold hypothesis: only a few points are needed to accurately represent them.

Reviewer comment: How is the batch size, bb, determined in practice? How does the value of bb affect computational speed and result accuracy?

This value is also determined by trial and error in practice. For example, the default batch size in mini-batch k-means in sklearn was 100 for a long time and recently increased to 1000. Larger b is slower but usually more accurate.

Reviewer comment: On line 181, it might be helpful to define Ci+1jC_{i+1}^j.

We will define it in the text.

Reviewer comment: On line 186, it is claimed that “Furthermore, it is possible to use dynamic programming to update the center.” I think it would be helpful to give some intuition for the dynamic-programming algorithm here.

We will add some intuition to the main body.

Reviewer comment: Some algebra in this paper is above my current level. For example, I was not able to fully understand the proof on line 213 or where the value 28 on line 212 came from.

As reviewer hCyZ also noticed, clarity can be improved here. Please see our response to hCyZ which contains a detailed version of the proof which we will add to the final version. This version also reduces the quadratic dependence on the log in τ\tau to linear.

Reviewer comment: On lines 254 and 255, would it be possible to provide more detail about what the accuracy scores represent? For example, does accuracy measure how well the clustering result matches the ground-truth labels?

We will add more details. We use the Hungarian algorithm to match the labels generated by the algorithm to the true labels in a way that maximizes accuracy.

Reviewer comment: At the top of page 9, in the mnist_784 plot, the ARI, NMI, and ACC criteria appear to show that the mini-batch kernel version outperformed the regular kernel version. Could you provide some insight into how an algorithm using a subset of the data can outperform an algorithm using the entire dataset?

In full-batch (kernel) k-means we are only guaranteed to reach a local minimum. Using mini-batches can allow us to escape bad local minima.

Reviewer comment: I want to ask if there could be a possible (maybe uncommon) situation where mini-batch kernel k means could lead to poor results compared regular kernel k means? In addition, would there be a situation where only regular kernel k means could be used (and mini-batch kernel k means cannot be used)?

We will add a section on limitations. If tau and the batch size are set inappropriately, then performance can suffer. We think the only place you would want to avoid using mini-batch kernel kk-Means is when the problem is so tiny that full batch kernel kk-Means can be run quickly.

Reviewer SVAP · CommentOpenReview ↗

Dear authors,

Thank you for addressing my comments. They clarified most of my questions.

I might be missing something here but did not fully understand the reason why "using mini-batches can allow us to escape bad local minima". It would be really helpful for you to elaborate a bit more on this point (this is a question regarding the top of page 9, in the mnist_784 plot, the ARI, NMI, and ACC criteria appear to show that the mini-batch kernel version outperformed the regular kernel version). However, I still think the current paper (with the modifications you mentioned) is a good paper.

Authors · CommentOpenReview ↗

We are glad that we managed to address most of your concerns. Unlike full-batch (kernel) kk-means, mini-batch updates are stochastic and need not decrease the objective on the full dataset at every iteration. This noise can cause them to converge to a different, sometimes better, local minimum. This is a plausible explanation for the MNIST result.

Consider a one-dimensional dataset with ten points at −0.49, ten points at 0.49, and one point at 1. The ground-truth assigns the points at −0.49 to the first cluster and the points at 0.49 together with the outlier at 1 to the second cluster. Initialize the two centers at 0 and 1. In full-batch k-means, all points at −0.49 and 0.49 are assigned to the center at 0, while the point at 1 is assigned to the other center. The updated centers therefore remain at 0 and 1, so this suboptimal clustering is stable.

With mini-batches, however, a batch may omit the point at 1 and contain slightly more points at −0.49 than at 0.49. This moves the first center slightly to the left. Once it moves below −0.02, the points at 0.49 become closer to the second center, which then moves from 1 toward 0.49. The algorithm can thus recover the ground-truth clustering by separating the negative and positive points.

Reviewer SVAP · CommentOpenReview ↗

Ok I see. Thank you for providing this helpful example.

Reviewer 8JWSOpenReview ↗
Rating
5/6
Confidence
4/5
Quality
3/4
Clarity
4/4
Significance
3/4
Originality
3/4
Contribution type
general
Ethical concerns
NO or VERY MINOR ethics concerns only
Read review
Summary

The manuscript presents mini batch based training algorithm for kernel k-means, whose running time with a fixed error tolerance has only logarithmic dependence on the number of data. The running time and clustering results are shown to be competitive with prior work.

Strengths and weaknesses

The content is clearly written. The presented running time complexities are typical for mini batch based training algorithms but the proposed truncation technique to algorithmically achieve them for the kernelized version is an original contribution that makes the manuscript worth publising. As the main weakness regarding clarity and significance, I was left missing the complexity considerations from the error tolerance point of view and the error tolerance parameter's calibration (see the questions part).

Questions

To me, it appears that the presentation of the main time complexity and convergence results is unnecessarily complicated, because the stopping threshold parameter epsilon's range of sensible values depends on the value of gamma, the maximum value of the feature vector's norm in the kernel induced feature space. This also made it cumbersome to analyze some of the results' practical details. The running time's only logarithmic dependence on the number of data given a fixed epsilon is nice of course but the narrative mostly evades the runtime's dependence on epsilon relative to its range of sensible values, which I feel to be at least as important for practitioners.

To fix this, one can in most practical cases calculate an empirical estimate of gamma from data such that with a high probability bounds the feature space norm of a large majority of the data, and use a redefined kernel function K(x,y)= 1/2*1/gamma <phi(x),phi(y)> with 1/2 ensuring that the range of sensible epsilon values is restricted within range (0,1) by Lemma B.2. This would get rid of the gamma parameter from the math and the results almost throughout the article's main content, which would make it far more intuitive for both the method's users and the readers of the article in general.

My main questions regarding the above suggestion are whether the above modification could be done as suggested and how the runtime's dependence as a function of e.g. 1/epsilon or -log(epsilon) compares with related work, when epsilon is calibrated to be within its range of sensible values?

Limitations

yes

Final justification

The authors have resolved everything I raised, so the article is acceptable.

Formatting concerns

No concerns.

3 comments
Authors · RebuttalOpenReview ↗
Rebuttal

Thank you for the positive evaluation and constructive feedback. This is a great suggestion, and we would be happy to implement it in the final version of the paper. Please see the details below, and let us know if we have missed anything.

Let the input kernel be K′K' with feature map ϕ′\phi', and let

γ′=max⁡x∈X∥ϕ′(x)∥=max⁡x∈XK′(x,x).\gamma' = \max_{x\in X}\lVert\phi'(x)\rVert = \max_{x\in X}\sqrt{K'(x,x)}.

We compute γ′\gamma' using nn diagonal kernel evaluations and normalize the kernel as follows:

K(x,y)=K′(x,y)4(γ′)2.K(x,y)=\frac{K'(x,y)}{4(\gamma')^2}.

Since K′(x,y)=⟨ϕ′(x),ϕ′(y)⟩K'(x,y)=\langle\phi'(x),\phi'(y)\rangle, this gives

K(x,y)=⟨ϕ′(x)2γ′,ϕ′(y)2γ′⟩.K(x,y)=\left\langle\frac{\phi'(x)}{2\gamma'},\frac{\phi'(y)}{2\gamma'}\right\rangle.

The corresponding feature map is therefore

ϕ(x)=ϕ′(x)2γ′.\phi(x)=\frac{\phi'(x)}{2\gamma'}.

Because this transformation simply scales the data, it does not otherwise affect the execution of the algorithm, provided that ϵ\epsilon is interpreted as an early-stopping threshold in the normalized feature space. Once γ′\gamma' is known, the factor 1/(4(γ′)2)1/(4(\gamma')^2) can be applied to each kernel evaluation on the fly. Thus, we never normalize the full kernel matrix and do not incur an O(n2)O(n^2) normalization cost.

This gives γ=1/2\gamma=1/2, and the stated bounds follow by substituting γ=1/2\gamma=1/2.

Let bb denote the batch size and tt the stopping time. The resulting batch-size bound is

b=Ω(max⁡γ4,γ2kϵ−2log⁡(nγ2ϵ)).b=\Omega\left(\max\\{\gamma^4,\gamma^2\\}k\epsilon^{-2}\log\left(\frac{n\gamma^2}{\epsilon}\right)\right).

For γ=O(1)\gamma=O(1), this becomes $ b=\Omega\left(k\epsilon^{-2}\log\left(\frac{n}{\epsilon}\right)\right). $

Similarly, the stopping-time bound is $ t=O\left(\gamma^2\epsilon^{-1}\right), $ which becomes $ t=O\left(\epsilon^{-1}\right) $ when γ=O(1)\gamma=O(1).

Each iteration takes $ O\left(kb^2\log^2\left(\frac{\gamma}{\epsilon}\right)\right) $ time. For γ=O(1)\gamma=O(1), this becomes $ O\left(kb^2\log^2\left(\frac{1}{\epsilon}\right)\right). $

We can apply the same normalization to the result of Schwartzman (2023). The analysis of Schwartzman (2023) uses a union bound over the dimension dd, so it retains a factor of dd even after normalization. Our martingale-based analysis is tighter and recovers the same bounds as for our kernel kk-means algorithms:

b=Ω(kϵ−2log⁡(nϵ)),t=O(ϵ−1).b=\Omega\left(k\epsilon^{-2}\log\left(\frac{n}{\epsilon}\right)\right), \qquad t=O\left(\epsilon^{-1}\right).
Reviewer 8JWS · CommentOpenReview ↗

Acknowledgment of Rebuttal

Dear authors, thank you for confirming this. I can most likely increase my score. Could you please still consider writing explicitly how the overall running time i.e. the number of required iterations multiplied by the time required by a single iteration behaves (when epsilon is calibrated to be between 0 and 1) in terms of fraction F=1/epsilon and its logarithm LF=log_2 (1/epsilon), as these would be more intuitive for the end users. While the former would tell the overall running time cost as a function of shrinking error tolerance, the latter would indicate even more intuitively how much more running time is needed if one wants to, say, cut the termination threshold in half.

Authors · CommentOpenReview ↗

Sorry for not including this in our original rebuttal. We agree that stating the complete dependence on ϵ\epsilon will make the result more useful and intuitive, and will add this in the final version of the paper.

From the previous comment we have the sufficient batch size and iteration bound as

b=Θ(kϵ−2log⁡(nϵ)),t=O(ϵ−1)b=\Theta\left( k\epsilon^{-2}\log\left(\frac{n}{\epsilon}\right) \right), t=O\left(\epsilon^{-1}\right)

The truncation parameter τ\tau is given asymptotically below (the dependence on the logarithm is now linear after tightening Lemma 4.1 - see response to reviewer hCyZ)

τ=Θ(blog⁡(1ϵ))\tau=\Theta\left( b\log\left(\frac{1}{\epsilon}\right) \right)

The time required by one iteration is therefore

O(k(b+τ)2)=O(kb2log⁡2(1ϵ)).O\left(k(b+\tau)^2\right)=O\left( kb^2\log^2\left(\frac{1}{\epsilon}\right) \right).

Plugging in bb, the per-iteration runtime becomes

O(k3ϵ−4log⁡2(nϵ)log⁡2(1ϵ)).O\left( k^3\epsilon^{-4} \log^2\left(\frac{n}{\epsilon}\right) \log^2\left(\frac{1}{\epsilon}\right) \right).

Multiplying this by the stopping-time bound gives the overall runtime

O(k3ϵ−5log⁡2(nϵ)log⁡2(1ϵ)).O\left( k^3\epsilon^{-5} \log^2\left(\frac{n}{\epsilon}\right) \log^2\left(\frac{1}{\epsilon}\right) \right).

From OpenReview, CC BY 4.0. Authors as signed there; shown unedited.

Missing a submission?

Loading the discussion…