Introduction
Spectral clustering (SC) is a powerful unsupervised learning technique capable of identifying clusters with non-linear boundaries and complex geometries, often outperforming traditional methods like K-means. However, its practical application is severely limited by computational complexity. Standard SC requires constructing an $N \times N$ similarity matrix, leading to $O(N^2)$ memory and time costs, followed by an eigendecomposition step that can reach $O(N^3)$. For modern datasets with millions of samples, these requirements are prohibitive. This paper introduces SC_RB, a framework that achieves linear scalability by leveraging Random Binning features and high-performance iterative eigensolvers.
Methodology
The proposed SC_RB method addresses the bottlenecks of similarity graph construction and eigendecomposition through two primary innovations.
Random Binning (RB) Features
Instead of explicitly calculating pairwise similarities, SC_RB projects data into a high-dimensional, sparse feature space. The process involves overlaying the data with multiple random grids (bins). Points falling into the same bin are considered similar. By using $R$ such random grids, a sparse feature matrix $Z$ is constructed where each row contains exactly $R$ non-zero entries.
The key insight is that the inner product of this sparse matrix ($ZZ^T$) implicitly approximates the Gaussian kernel similarity matrix $W$. This approach reduces the construction cost from quadratic to linear relative to the number of data points $N$.
Efficient Eigendecomposition with PRIMME
To handle the resulting massive sparse matrices, the authors utilize PRIMME (PReconditioned Iterative MultiMethod Eigensolver). PRIMME is a state-of-the-art library designed to find eigenvectors of large-scale sparse matrices efficiently. By employing a "matrix-free" approach, the algorithm computes cluster embeddings using only matrix-vector multiplications, avoiding the explicit formation of the $N \times N$ Laplacian matrix and maintaining a low memory footprint.
Experimental Evaluation
The authors evaluated SC_RB across eight benchmark datasets, ranging from small-scale (MNIST, 70k samples) to massive-scale (SUSY, 4 million samples).
As shown in the MNIST evaluation, SC_RB (red line) achieves accuracy comparable to exact spectral clustering while significantly reducing runtime. On the poker dataset (over 1 million points), the entire clustering process was completed in approximately 538 seconds. Scalability tests on the SUSY dataset confirmed that runtime grows linearly with both the number of samples $N$ and the number of features $R$.
Discussion and Conclusion
SC_RB demonstrates that sparsity is a critical factor in scaling spectral clustering. Theoretical analysis shows that RB features converge to the exact solution faster than alternative methods like Random Fourier Features because RB captures local similarity blocks more effectively.
While the method is highly efficient, it faces challenges when eigenvalues are closely clustered, as seen in the covtype-mult dataset, which can slow down iterative solvers. Despite these limitations, SC_RB provides a robust, linearly scalable solution for spectral clustering on industrial-scale datasets, enabling the discovery of complex patterns in millions of data points on a single machine.
Summary updated