Skip to main content
QUICK REVIEW

[Paper Review] Fast Exact Leverage Score Sampling from Khatri-Rao Products with Applications to Tensor Decomposition

Vivek Bharadwaj, Osman Asif Malik|arXiv (Cornell University)|Jan 29, 2023
Tensor decomposition and applicationsMathematics3 citations
TL;DR

This paper proposes a novel data structure for fast, exact leverage score sampling from Khatri-Rao products of large matrices, enabling efficient randomized sketching in tensor decomposition. By achieving logarithmic sampling time in matrix size and quadratic time in rank, it reduces least-squares solve complexity in CANDECOMP/PARAFAC (CP) decomposition, outperforming state-of-the-art methods on billion-scale sparse tensors with higher accuracy and up to 2.5x speedup.

ABSTRACT

We present a data structure to randomly sample rows from the Khatri-Rao product of several matrices according to the exact distribution of its leverage scores. Our proposed sampler draws each row in time logarithmic in the height of the Khatri-Rao product and quadratic in its column count, with persistent space overhead at most the size of the input matrices. As a result, it tractably draws samples even when the matrices forming the Khatri-Rao product have tens of millions of rows each. When used to sketch the linear least squares problems arising in CANDECOMP / PARAFAC tensor decomposition, our method achieves lower asymptotic complexity per solve than recent state-of-the-art methods. Experiments on billion-scale sparse tensors validate our claims, with our algorithm achieving higher accuracy than competing methods as the decomposition rank grows.

Motivation & Objective

  • To enable efficient, exact leverage score sampling from Khatri-Rao products of large matrices, which are central to tensor decomposition and least-squares problems.
  • To reduce the computational complexity of randomized sketching in CANDECOMP/PARAFAC (CP) tensor decomposition, especially for high-dimensional, sparse tensors.
  • To design a data structure that supports fast sampling and incremental updates, even when input matrices have tens of millions of rows.
  • To achieve lower asymptotic complexity per least-squares solve than recent state-of-the-art methods while maintaining high accuracy.
  • To demonstrate practical superiority on real-world, billion-scale sparse tensors where traditional methods become intractable.

Proposed method

  • The method constructs a data structure that precomputes leverage score distributions over the Khatri-Rao product without explicitly materializing the full product.
  • Sampling is performed in time O(NR³ + J∑ₖ R² log(max(Iₖ, R))) per J samples, with O(R³) scratch space, enabling logarithmic dependence on matrix height.
  • The data structure supports efficient incremental updates: O(R log(Iⱼ/R)) time for single-entry changes and O(IⱼR²) for full matrix updates.
  • The approach leverages properties of Kronecker products and leverage score computation via QR decomposition to avoid explicit formation of the Khatri-Rao product.
  • For sparse inputs, the construction time and storage are O(R ∑ₙz(Uⱼ)) and O(∑ₙz(Uⱼ)), respectively, preserving efficiency.
  • The sampler supports sampling from any subset of the input matrices, which is critical for alternating least-squares in CP decomposition.
Figure 4 : Average fits (8 trials) achieved by randomized ( $J=2^{16}$ ) and exact ALS for sparse tensor CP decomposition. Error bars indicate 3 standard deviations. See Appendix A.11 for details.
Figure 4 : Average fits (8 trials) achieved by randomized ( $J=2^{16}$ ) and exact ALS for sparse tensor CP decomposition. Error bars indicate 3 standard deviations. See Appendix A.11 for details.

Experimental results

Research questions

  • RQ1Can we achieve exact leverage score sampling from Khatri-Rao products without materializing the full product, even when the product has trillions of rows?
  • RQ2Can we design a data structure that enables sampling in time logarithmic in the number of rows and quadratic in the rank, with low persistent storage overhead?
  • RQ3Does exact leverage score sampling via this method lead to lower asymptotic complexity and higher accuracy in CP tensor decomposition compared to approximate sampling methods?
  • RQ4How does the performance of the proposed sampler scale on billion-scale sparse tensors with high decomposition ranks?
  • RQ5Under what conditions does the higher cost of exact sampling become offset by faster least-squares solves in practice?

Key findings

  • STS-CP achieved up to 2.5x speedup over CP-ARLS-LEV on large sparse tensors like Amazon and Reddit, while reaching 95% of the fit of non-randomized ALS.
  • On the Enron tensor, STS-CP achieved 95% accuracy at ranks above 50 where CP-ARLS-LEV failed entirely, even with 54× more samples.
  • STS-CP required only ~65,000 samples per solve on Enron to reach 95% accuracy at rank >50, demonstrating superior sample efficiency.
  • The algorithm achieved lower asymptotic complexity per iteration than state-of-the-art methods, with complexity O(NR³ log I + IR²)/(εδ) per solve.
  • For tensors with over one billion nonzeros, STS-CP provided 1.4x to 2.0x speedup across all tested ranks, especially benefiting from high-rank decomposition.
  • STS-CP’s performance advantage is most pronounced on large, sparse tensors where the cost of exact sampling is offset by faster least-squares solves.
Figure 7 : Comparison of true leverage score distribution with histogram of 50,000 samples drawn from $U_{1}\odot U_{2}\odot U_{3}$ .
Figure 7 : Comparison of true leverage score distribution with histogram of 50,000 samples drawn from $U_{1}\odot U_{2}\odot U_{3}$ .

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.