Inferensys

Glossary

Nyström Method

The Nyström method is a technique for approximating large kernel matrices and their eigendecompositions by using a subset of columns, enabling scalable kernel methods and low-rank approximations.
Stylish WeWork-like workspace with hot desks and document wall, professional searching through enterprise knowledge base on a mounted ultrawide display, warm industrial pendants overhead.
LOW-RANK FACTORIZATION

What is the Nyström Method?

The Nyström method is a scalable technique for approximating large kernel matrices and their eigendecompositions, enabling efficient low-rank approximations for kernel-based machine learning.

The Nyström method is a matrix approximation technique that constructs a low-rank surrogate for a large, dense kernel matrix by sampling a subset of its columns (or rows). This method is foundational for scaling kernel methods, such as kernel PCA and Gaussian processes, to large datasets where forming the full O(n²) matrix is computationally prohibitive. The core idea is to use the sampled columns to approximate the entire matrix's range, effectively performing an approximate eigendecomposition.

The approximation's quality depends on the leverage scores or sampling strategy used to select columns. The method is closely related to CUR decomposition and randomized linear algebra techniques. In model compression, it can be viewed as a form of low-rank factorization applied to the implicit feature map of a kernel, reducing the computational and memory footprint for inference. It provides a principled trade-off between accuracy and scalability for large-scale non-linear models.

LOW-RANK APPROXIMATION

Key Features of the Nyström Method

The Nyström method is a sampling-based technique for constructing a low-rank approximation of a large kernel matrix, enabling scalable kernel methods and efficient eigendecomposition.

01

Column Subset Selection

The core mechanism of the Nyström method is the selection of a landmark subset of m columns (or rows) from the original n x n kernel matrix K. This subset, often chosen via uniform random sampling, k-means clustering, or leverage score sampling, forms the basis for the approximation. The selected columns are assembled into matrix C (size n x m), and the intersection of these columns and corresponding rows forms matrix W (size m x m). The full approximation is then constructed as K ≈ C * W^† * C^T, where W^† is the pseudoinverse of W.

02

Low-Rank Matrix Approximation

The method explicitly produces a rank-k approximation of the kernel matrix, where k ≤ m. The approximation is derived from the eigendecomposition of the small m x m matrix W. By extending these eigenvectors to the full dataset via the Nyström extension formula, the method approximates the top eigenvalues and eigenvectors of the full n x n matrix K without ever computing it entirely. This is critical for applications like kernel PCA, where the dominant eigenstructure defines the projection.

03

Computational and Memory Efficiency

The primary advantage is a drastic reduction in computational complexity and memory footprint.

  • Complexity: Building the full kernel matrix is O(n^2) in memory and O(n^2 * d) in computation (where d is feature dimension). The Nyström method reduces this to O(n * m) memory and computation, where m << n.
  • Eigendecomposition: Performing eigenanalysis on the full K is O(n^3). With Nyström, it is performed on W, costing O(m^3), and the extension is O(n * m * k). This enables kernel methods on datasets with millions of points.
04

The Nyström Extension Formula

This is the mathematical engine that generalizes eigenvectors from the sample to the full dataset. If v is an eigenvector of W with eigenvalue λ, the corresponding approximated eigenvector u for the full matrix K is given by: u = (1/√λ) * C * v This formula allows the out-of-sample extension of kernel-based embeddings, enabling the embedding of new, unseen data points into the low-dimensional space defined by the landmark samples without retraining.

05

Approximation Error Bounds

The quality of the approximation is governed by the spectral norm error ||K - K_approx|| or the Frobenius norm error. Theoretical bounds show this error is related to how well the selected columns span the column space of K. Key factors include:

  • Number of landmarks (m): Error typically decreases as m increases.
  • Sampling strategy: Adaptive methods (e.g., based on leverage scores) often provide tighter bounds than uniform random sampling.
  • Matrix spectrum: Matrices with rapidly decaying eigenvalues (i.e., low effective rank) are approximated more accurately with fewer samples.
06

Connection to Inducing Points

In Gaussian Processes (GPs), the Nyström method is conceptually identical to the subset of regressors approximation and is closely related to sparse Gaussian Processes using inducing points. The selected landmark columns correspond to the inducing inputs or pseudo-inputs. The approximation K ≈ C * W^† * C^T is used to construct a low-rank approximation of the kernel covariance matrix, reducing the O(n^3) training complexity of exact GPs to O(n * m^2). This makes large-scale GP regression and classification feasible.

LOW-RANK MATRIX APPROXIMATION

Nyström Method vs. Other Approximation Techniques

A comparison of the Nyström method against other prominent techniques for approximating large kernel, covariance, or general matrices, focusing on their mechanisms, computational properties, and typical use cases in machine learning.

Feature / MetricNyström MethodRandomized SVDTruncated SVD (Classical)Random Projection

Core Approximation Mechanism

Subset of columns (landmark points)

Randomized linear algebra & subspace iteration

Exact partial eigendecomposition

Johnson-Lindenstrauss Lemma & random matrices

Primary Input Requirement

Kernel or Gram matrix (implicitly via data)

General matrix (dense or sparse)

General matrix (dense)

Data matrix or pairwise distances

Explicit Matrix Required?

Optimality Guarantee (for fixed rank)

None (data-dependent)

High probability near-optimal

Optimal (Eckart–Young Theorem)

Probabilistic distance preservation

Dominant Computational Cost

O(n m^2 + m^3) for n samples, m landmarks

O(n^2 k) for rank k, with constants

O(n^2 k) full SVD, O(nnz * k) sparse

O(n d k) for d dimensions, k projections

Parallelization & Distributed Friendliness

High (column sampling is embarrassingly parallel)

Moderate (iterative matrix multiplications)

Low (inherently sequential Lanczos/QR)

High (embarrassingly parallel projections)

Interpretability of Basis

Medium (basis vectors are actual data columns)

Low (basis is random linear combination)

High (basis is optimal orthogonal directions)

Low (basis is purely random)

Common Application Context

Kernel methods (SVM, GP), spectral clustering

Large-scale PCA, low-rank matrix completion

Dense PCA, Latent Semantic Analysis

Fast distance preservation, sketching

Streaming / Online Data Support

Possible via reservoir sampling of landmarks

Challenging, requires block updates

Not supported

Native support via incremental projection

Theoretical Error Bounds

Based on column leverage scores

Strong probabilistic Frobenius norm bounds

Exact residual Frobenius/Spectral norm

Probabilistic ℓ2 distance preservation

NYSTRÖM METHOD

Frequently Asked Questions

The Nyström method is a cornerstone technique for scalable kernel methods and low-rank matrix approximation. This FAQ addresses its core mechanics, applications, and relationship to other factorization methods.

The Nyström method is a sampling-based technique for approximating a large, dense kernel matrix or any positive semi-definite matrix by using a subset of its columns. It works by selecting a small set of landmark points (or columns), computing the corresponding submatrix, and using this to construct a low-rank approximation of the full matrix. The core idea is that the relationships captured in the selected columns are representative of the entire dataset's structure. Mathematically, given a kernel matrix K of size n x n, one selects m landmark columns (m << n) to form submatrices C (n x m) and W (m x m). The Nyström approximation is then given by K ≈ C W† C^T, where W† is the pseudo-inverse of W. This avoids the O(n²) memory and O(n³) computational cost of working with the full matrix.

Prasad Kumkar

About the author

Prasad Kumkar

CEO & MD, Inference Systems

Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.

His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.