TL;DR
This paper introduces a novel preconditioning technique for Kernel Ridge Regression (KRR) that significantly speeds up computation on large datasets. By leveraging random feature maps not for approximation but as a preconditioner, they achieve state-of-the-art accuracy with much faster training times, even on datasets with up to a million data points.
What Problem Does This Paper Address?
Kernel Ridge Regression (KRR) is a powerful non-parametric regression method. However, its core computation involves solving a dense and ill-conditioned linear system. For large datasets, the size of this system (number of data points x number of data points) makes direct solution methods computationally infeasible. While iterative methods can be used, the ill-conditioning of the kernel matrix requires a prohibitively large number of iterations. Existing approximate methods using random features can speed up training but often compromise model accuracy. This paper aims to bridge this gap by providing a method that accelerates KRR without sacrificing accuracy.
Methods
The authors propose using random feature maps as a preconditioner for the kernel matrix in KRR. Instead of directly solving an approximated system (as in the "random features method"), they use the random features to construct a matrix $Z$ whose transpose-transpose ($ZZ^T$) is used to precondition the system $(K + \lambda I_n)c = y$. This preconditioned system is then solved efficiently using the Preconditioned Conjugate Gradients (PCG) algorithm.
Key algorithmic contributions include:
- Random Feature Preconditioning: The core idea is to use $ZZ^T + \lambda I_n$ as a preconditioner, where $Z$ is formed from random feature map evaluations of the data points.
- Efficient Preconditioner Inversion: They employ the Woodbury formula and Cholesky decomposition to efficiently compute the inverse of the preconditioner, which is crucial for PCG iterations.
- Multi-Level Sketching: For further improvement, they introduce a multi-level sketching approach, composing initial random feature maps with Subsampled Randomized Hadamard Transforms (SRHT) to reduce the dimensionality of the intermediate representations.
- Theoretical Analysis: They provide theoretical guarantees for the polynomial kernel, showing that the number of random features needed for effective preconditioning is related to the statistical dimension of the problem, which is often much smaller than the number of data points.
Datasets
The paper evaluates their method on several standard classification and regression datasets:
- GISETTE
- ADULT
- IJCNN1
- MNIST (including MNIST-200K, MNIST-300K, and MNIST-1M)
- EPSILON
- COVTYPE
- YEARMSD
- Extended MNIST-8M dataset
Key Insights and Ideas
- Preconditioning vs. Approximation: The most significant insight is that random feature maps are more effective as preconditioners than as direct approximations of the kernel. This allows for high accuracy without the need for an excessive number of random features.
- Statistical Dimension Matters: The theoretical analysis highlights the importance of the "statistical dimension" (or effective degrees-of-freedom) of the problem. The number of random features required for an effective preconditioner scales with this dimension, not directly with the total number of data points.
- Multi-Level Sketching for Efficiency: Composing sketching techniques (like SRHT) after the initial random feature map can further reduce the dimensionality and improve the efficiency of the preconditioner.
- Practical Scalability: The method is shown to be highly effective and scalable to datasets with up to one million training examples, achieving competitive results in terms of both accuracy and training time.
Key Results
- Accuracy: The proposed method consistently achieves error rates comparable to or better than the exact KRR solution, outperforming the "random features method" which often requires a very large number of features to approach similar accuracy.
- Speed: For datasets up to one million examples, the algorithm can train high-quality models in a few hours, significantly faster than direct methods and often faster than approximation methods that require a large number of features to match accuracy. For example, on MNIST, their method achieved optimal training times under 2 minutes for the Gaussian kernel.
- Robustness: The preconditioned conjugate gradient method is shown to be more robust than the non-preconditioned version, which sometimes fails to converge.
- Theoretical Guarantees: For the polynomial kernel, they prove that with a number of random features proportional to the statistical dimension, the preconditioner yields a bounded condition number, leading to fast convergence of PCG.
Limitations and Future Work
- Memory Requirement: The primary limitation acknowledged is the $O(n^2)$ memory requirement for storing the kernel matrix.
- Future Work:
- Out-of-core algorithms: Using SSD or magnetic drives to store the kernel matrix.
- Ensemble methods: Designing models as ensembles of smaller models based on non-uniform sampling.
- Block solvers: Using the proposed solver as a block solver within block coordinate descent algorithms.
- Theoretical analysis for other kernels/feature maps: Extending the theoretical guarantees to a wider range of kernels and feature map constructions.
- Adaptive setting of sketch size: Developing methods to automatically determine the optimal number of random features.
- Preconditioning with $\lambda_p \neq \lambda$: Investigating the empirical observation that using a different regularization parameter for the preconditioner ($\lambda_p$) than for the original problem ($\lambda$) can improve performance.
Summary updated