LSRN: A Parallel Iterative Solver for Strongly Over- or Under-Determined Systems

Xiangrui Meng, Michael A. Saunders, Michael W. Mahoney

Abstract

We present LSRN, a parallel randomized solver designed to handle large-scale least squares problems that are either strongly over-determined or under-determined. By utilizing random normal projections to create a "sketch" of the data, LSRN constructs a preconditioner that ensures fast and predictable convergence, regardless of the original matrix's condition number or rank. LSRN is particularly effective in distributed-memory environments, where it leverages communication-avoiding iterative methods to achieve high scalability.

1. Introduction

Solving linear least squares problems ($\\min \\|Ax - b\\|_2$) is a fundamental task in scientific computing and data analysis. However, as datasets reach extreme scales, traditional methods encounter significant limitations:

  1. Direct Solvers: Robust methods like SVD or QR factorization (e.g., LAPACK’s DGELSD) are difficult to parallelize efficiently across clusters and can be prohibitively slow for massive matrices.
  2. Iterative Solvers: Methods such as LSQR are faster for sparse matrices, but their performance is highly sensitive to the matrix's condition number. Poorly conditioned systems may require thousands of iterations to converge.
  3. Rank Deficiency: Many existing solvers struggle or fail when the matrix $A$ lacks full rank.

LSRN (Least Squares with Random Normal projection) addresses these challenges by providing a solver that is parallel-friendly, robust to rank deficiency, and characterized by a predictable runtime independent of the input data's numerical properties.

2. Methodology

LSRN combines randomized dimensionality reduction with classical iterative methods through a three-step process:

2.1 Random Sketching

The large input matrix $A$ is multiplied by a much smaller random Gaussian matrix $G$. This "sketches" the essential structure of $A$ into a smaller matrix $\\tilde{A}$. This phase is "embarrassingly parallel," allowing it to be distributed across many processors with negligible communication overhead.

2.2 Preconditioner Generation

The solver computes the SVD of the small sketch $\\tilde{A}$. Because the sketch is compact, this step is computationally inexpensive. The resulting singular values and vectors are used to construct a preconditioner matrix $N$, which transforms the original problem into a well-conditioned system.

2.3 Iterative Solution

LSRN solves the preconditioned system using either LSQR or the Chebyshev semi-iterative (CS) method. The authors specifically highlight the Chebyshev method for cluster environments. Unlike LSQR, the Chebyshev method does not require vector inner products, eliminating the need for frequent, expensive synchronization between nodes in a distributed system.

3. Key Insights

3.1 Spectrum Independence

A defining feature of LSRN is that the condition number of the preconditioned system depends only on the oversampling factor (the ratio of the sketch size to the matrix rank), not on the properties of the original matrix $A$. This makes the number of iterations required for convergence fully predictable before the solver begins.

3.2 Communication Efficiency

In distributed environments like Amazon EC2, communication often becomes the primary bottleneck. By employing the Chebyshev method, LSRN minimizes inter-node "talk," leading to superior scaling compared to standard iterative methods that rely on frequent global synchronizations.

4. Experimental Results

The authors evaluated LSRN using synthetic matrices and real-world datasets, including the University of Florida Sparse Matrix Collection and the massive tnimg (TinyImages) dataset, which contains submatrices up to $1024 \\times 4 \\times 10^7$.

  • Comparison with Standard Libraries: On large dense problems, LSRN outperformed LAPACK’s DGELSD. On sparse problems, LSRN significantly outperformed MATLAB’s backslash (SuiteSparseQR); for a $10^6 \\times 10^3$ sparse problem, LSRN required only 23 seconds compared to MATLAB's 55 seconds.
  • Scalability: LSRN demonstrated near-linear speedup on Amazon EC2 clusters. When increasing both the problem size and the number of cores by 10x, the total runtime increased by only approximately 50%.
  • Robustness: LSRN successfully solved highly rank-deficient problems, such as the landmark matrix, where other randomized solvers often fail.

5. Conclusion and Future Work

LSRN provides a robust, scalable framework for solving extreme-scale least squares problems. While the Gaussian projection used in the sketching phase is $O(mn^2)$ for dense matrices, its implementation simplicity and robustness for sparse data make it a powerful tool for modern high-performance computing. Future work will focus on further optimizing sparse matrix-vector multiplication routines to achieve even greater speedups.

Summary updated

BibTeX
@article{meng2014lsrn,
  author = {Xiangrui Meng and Michael A. Saunders and Michael W. Mahoney},
  title = {{LSRN: A Parallel Iterative Solver for Strongly Over- or Under-Determined Systems}},
  journal = {SIAM J. Sci. Comput.},
  year = {2014},
  doi = {10.1137/120866580},
}
Figure