arXiv Science⌕ Search

arXiv · 2611.39057

MA-Means: Bounded-Memory $k$-Means via Elastic Multi-Candidate Contraction, Coordinate-Wise Over-Relaxation, and Zero-Error Out-of-Core Bypass

Abstract

Large-scale k-means faces a memory-convergence trilemma: full-batch Lloyd needs O(nKD) per step and traps in local minima; memoryless EMA solvers (Sculley's MBKM, Meta FAIR's e-means) match 25-epoch Lloyd at a fraction of the cost on uniform embeddings using scalar counts, but cannot cross uphill barriers, destroy rare modes under mass-gated revival, and do no out-of-core filtering; staleness methods hold an unbounded Theta(n) table. Extending the EMA scaling law beyond convex single-trajectory updates, MA-Means holds O(1)-in-n statistics (0.1-51 MB for n=1e4 to 1e10) on a fused Triton BF16 + C++17 pipeline, uniting (i) an elastic K->K'->K candidate pool that spans non-monotone barriers and contracts via Benzecri Ward merging plus O(K) distortion-aware revival; (ii) coordinate-wise Aitken over-relaxation (w>1), proving the O(1/(T^2 rho_min)) optimality of fixed-basin linear EMA schedules yet eliminating moving-boundary bias in one step; and (iii) int8_chord checkpoints with zero-error transfer refusal. Across five public benchmarks (n up to 2e7, 10 seeds for Layer-2 and 5 for Layer-1, zero tuning) and 14 baselines, MA-Means wins 12 of 15 Layer-1 cells at 5 epochs (three 1M-row K=4096 cells are +0.05-0.07% MSE), including 1.69-1.78x equal-MSE speedup at 3 epochs vs. 5-epoch e-means on full 10M Deep10M. In Layer-2 BF16 it reaches equal MSE 1.32-1.90x faster, wins 10/10 seeds on ImageNet-CLIP (-0.61% MSE at K=1024, beating 25ep e-means and exact Hamerly; -0.26% at K=4096), cuts NYC-Taxi-20M MSE by 54.8-63.3% vs. e-means, eliminates 14.4-26.4% of out-of-core traffic with 0 false positives, and on one RTX 4090 runs 1.85x faster than e-means at n=100M with -0.7% to -1.0% MSE.

Explore related subjects

Keep this discovery

Explore connections, maps & timelines

BibTeXRIS

Meng Zhu. 2026-11-28. MA-Means: Bounded-Memory $k$-Means via Elastic Multi-Candidate Contraction, Coordinate-Wise Over-Relaxation, and Zero-Error Out-of-Core Bypass. https://arxiv.science/abs/2611.39057

Citations retain the original authors and DOI and include this site’s record URL. If this discovery service contributed to your research, you can also cite arXiv Science by Indiciae: BibTeX · RIS.

KEEP EXPLORING

Related papers

The Causal Case Against Algorithmic Discrimination: A Framework for Fairness Auditing in Law

As Artificial Intelligence (AI) increasingly influences decisions in critical societal sectors, understanding and establishing causality becomes essential for evaluating the fairness of automated systems. This article explores the significance of causal reasoning in addressing algorithmic discrimination, emphasizing both legal and societal perspectives. By reviewing landmark cases and regulatory frameworks, particularly within the European Union, we illustrate the challenges inherent in proving causal claims when confronted with opaque AI decision-making processes. The discussion outlines practical obstacles and methodological limitations in applying causal inference to real-world fairness scenarios, proposing actionable solutions to enhance transparency, accountability, and fairness in algorithm-driven decisions.

cs.LG↗

Implicit Dynamical Flow Fusion (IDFF) for Generative Modeling

Conditional Flow Matching (CFM) generates high-quality samples by learning a deterministic transport from noise to data, but typically requires more than a hundred network function evaluations (NFEs) per sample. We propose Implicit Dynamical Flow Fusion (IDFF), which augments the CFM vector field with $K$th-order score-derivative terms and attains comparable sample quality while requiring significantly fewer NFEs. At first order ($K=1$), the method reduces to a Langevin-augmented flow, and we prove that the marginal $p_t$ is preserved exactly in continuous time; the empirical NFE reduction is therefore a statement about discretization robustness, not about continuous-time acceleration, and we make that reading explicit. For $K=2$, we further provide an error analysis that justifies the optional second-order curvature correction we introduce, showing that its deviation is bounded by the weighted score-matching loss already minimized by our objective; the bound is formulated for general $K$ and guarantees that this correction cannot worsen the order of the overall scheme. The practical enabler behind both regimes is a re-parameterization identity: every higher-order marginal derivative can be obtained from the learned first-order score by automatic differentiation, so no additional networks are trained. Empirically, IDFF reduces NFEs by an order of magnitude with no loss in sample quality. On CIFAR-10 the $K=1$ configuration achieves an FID of 2.78 at 10 NFEs, the best result at that budget among the CFM variants we retrain at a matched backbone and training budget, and on par with methods that need over a hundred evaluations. For time-series modelling, IDFF performs strongly on molecular-dynamics simulation and sea-surface-temperature forecasting at a fraction of the compute. Code is available: https://github.com/MrRezaeiUofT/Implicit_Dynamical_Flow_Fusion_for_Genereative_Modeling.

cs.LG↗

Sampling with Adaptive Variance for Multimodal Distributions

Motivated by our previous work on adaptive diffusion for global optimization, we propose and analyze a class of adaptive sampling algorithms for multimodal distributions on a bounded domain. These algorithms share the structure of classical overdamped Langevin dynamics. We first demonstrate that this class of linear dynamics with adaptive diffusion coefficients and vector fields can be interpreted and analyzed as weighted Wasserstein gradient flows of the Kullback--Leibler (KL) divergence between the current distribution and the target Gibbs distribution. This directly leads to the exponential convergence of both the KL and $χ^2$ divergences, with rates depending on the weighted Wasserstein metric and the Gibbs potential. We then show that a derivative-free version of the dynamics can be used for sampling without evaluating the gradient of the Gibbs potential. For Gibbs distributions with nonconvex potentials, this approach can achieve much faster convergence than the classical overdamped Langevin dynamics. A comparison of the mean transition times between local minima of a nonconvex potential further highlights the sampling advantage of the derivative-free dynamics in this setting.

cs.LG↗