What is the primary trade-off when using Mini-Batch K-Means over standard K-Means?
Last updated
Mini-Batch K-Means updates centroids from small random batches, giving large speed and memory gains (O(b·k·d) per iteration vs O(n·k·d)) and supporting streaming via
partial_fit.The cost is slightly worse quality: noisier centroids, somewhat higher inertia, more seed dependence, and possibly poor centers for small or rare clusters.
Use it when n is too large for full k-means or the data doesn't fit in memory. A larger
batch_sizeimproves quality but reduces the speedup.