Nearly Linear Row Sampling Algorithm for Quantile Regression

Yi Li, Ruosong Wang, Lin Yang, Hanrui Zhang

Introduction

This paper introduces the first row sampling algorithm for quantile regression with a sample complexity that is nearly linear in the data's dimensionality ($d$). By leveraging Lewis weights, the authors slash the required number of samples from a prohibitive $O(d^3)$ to a highly practical $\tilde{O}(d)$. This theoretical breakthrough enables significantly faster solvers and provides new tools for directed graph sparsification.

The Challenge of Scale in Quantile Regression

In the era of "Big Data," data scientists frequently encounter overconstrained linear regression problems where the number of observations ($n$) far exceeds the number of features ($d$). Quantile regression is a particularly powerful tool in this space; it allows practitioners to model specific conditional quantiles (like the median or the 95th percentile) rather than just the mean. This makes it robust to outliers and highly useful for risk assessment.

However, solving quantile regression on massive datasets is computationally expensive. A common strategy to mitigate this is row sampling: picking a small, representative subset of the data (a "sketch") and solving the problem on that subset. The core challenge is ensuring the subset is small enough to be computationally efficient but representative enough to maintain accuracy.

Prior to this work, the best algorithms required sampling $O(d^3)$ rows. For a dataset with 1,000 features, that translates to sampling a billion rows—often more than the original dataset itself! This paper aims to close that gap, bringing the sample complexity down to nearly linear in $d$.

Methodology: Lewis Weights to the Rescue

The authors' primary technical contribution is demonstrating that Lewis weights—a sophisticated importance sampling scheme previously used for $\ell_p$ norms—can be successfully adapted for the quantile loss function.

  1. Lewis Weight Sampling: Lewis weights act as a generalization of leverage scores. They assign a "weight" to each row based on its importance to the overall structure of the matrix. The authors prove that sampling rows proportional to their $\ell_1$ Lewis weights approximately preserves the quantile loss for all possible solution vectors simultaneously.
  2. The Solver: Once the data is sub-sampled, the authors employ a "sketch-and-solve" paradigm using the Katyusha algorithm, an accelerated stochastic gradient descent (SGD) method, rather than relying on a generic solver.
  3. Generalization: The framework is further extended to a broader class of loss functions that can be approximated by $\ell_p$ norms, showcasing the versatility of the Lewis weight approach.

Key Insights

  • The $\ell_1$ Connection: The critical realization in this work is that the quantile loss function—despite being asymmetric—can be bounded by the $\ell_1$ norm. This allows the researchers to port over powerful theoretical guarantees from $\ell_1$ subspace embeddings directly to the quantile regression problem.
  • Breaking the $d^3$ Barrier: By proving that Lewis weights work for quantile loss, the authors move from a "coarse" sampling (leverage scores) to a "fine-grained" sampling that captures the geometry of the data much more efficiently.
  • Black-Box Sparsification: The authors show that their sampling result can be used as a "black box" to sparsify balanced directed graphs, providing a simpler, more general alternative to specialized combinatorial algorithms.

Empirical Results and Performance

The algorithm (dubbed LEW) was evaluated against existing state-of-the-art methods (SPC1, SPC2, SPC3) and uniform sampling using both synthetic and real-world datasets.

Theoretical Speedup: The algorithm successfully reduces the sample complexity from $O(d^3/\epsilon^2)$ to $\tilde{O}(d/\epsilon^2\tau^2)$. Furthermore, it provides the fastest known input-sparsity time algorithm for quantile regression, running in $\tilde{O}(nnz(A) + d^{2.5}/(\epsilon^2\tau^2))$ time.

Synthetic Data: The authors designed highly imbalanced synthetic datasets (using canonical basis vectors) to test the robustness of the sampling scheme. As sample sizes increased, LEW was the only method that remained consistently stable and accurate.

Performance on synthetic data comparing LEW to SPC methods.

Real-World Data: The algorithm was also tested on the U.S. 2000 Census Data, a dataset consisting of over 5 million records and 11 features used to predict salary based on demographic factors. On this dataset, the LEW algorithm was significantly faster than the previous state-of-the-art (SPC2/SPC3) while maintaining comparable or superior accuracy.

Performance on U.S. Census data showing LEW achieving lower error rates.

Limitations and Future Work

While a significant leap forward, the paper notes a few limitations and areas for future exploration:

  • Dependence on $\tau$: The sample complexity includes a $1/\tau^2$ term. If modeling an extreme quantile (e.g., the 0.001th or 99.999th percentile), the required sample size grows significantly.
  • Lower Bounds: While the $d$ dependence is nearly optimal, proving formal lower bounds for quantile row sampling remains an open question.
  • Broader Loss Functions: Although the authors touched on M-estimators and Orlicz norms, developing a unified theory for exactly which types of non-convex or asymmetric loss functions can be handled by Lewis weights is still a work in progress.

Summary updated

BibTeX
@inproceedings{li2020nearly,
  author = {Yi Li and Ruosong Wang and Lin Yang and Hanrui Zhang},
  title = {{Nearly Linear Row Sampling Algorithm for Quantile Regression}},
  booktitle = {International Conference on Machine Learning},
  year = {2020},
  url = {https://openreview.net/forum?id=rCpSJENfM0L},
}
Figure