More Efficient Sampling for Tensor Decomposition With Worst-Case Guarantees

Osman Asif Malik

Introduction

Tensors—multi-dimensional arrays—are foundational structures in modern machine learning, powering everything from neural network compression to complex multimodal data fusion. However, working with them introduces a severe computational bottleneck known as the curse of dimensionality. An $N$-way tensor with dimension $I$ contains $I^N$ entries, meaning the data size grows exponentially with each added dimension.

The standard "workhorse" algorithm for decomposing these massive tensors is Alternating Least Squares (ALS). While highly effective, standard ALS is notoriously slow for large tensors because it requires processing every single entry during every iteration. To mitigate this, previous "sampling-based" ALS methods attempt to process only a small subset of the data. Unfortunately, the computational cost of these prior methods still contains terms like $R^N$ (where $R$ is the tensor rank). As the number of dimensions ($N$) grows, or when the rank $R$ exceeds the mode dimension $I$, these methods quickly become computationally intractable.

This paper introduces a breakthrough approach to tensor decomposition (specifically for CP and Tensor Ring formats) using randomized sampling that finally breaks this "exponential curse."

Breaking the Curse: CP-ALS-ES and TR-ALS-ES

The authors propose two novel algorithms: CP-ALS-ES and TR-ALS-ES (where "ES" stands for Efficient Sampling). The core innovation of these methods lies in how they estimate leverage scores—a statistical measure of how "important" a particular row of data is for computing the final decomposition.

Recursive Sketching

Instead of using a standard "flat" random projection to sample data, the authors introduce a recursive sketching structure. By combining CountSketch and TensorSketch techniques, the algorithm processes the tensor modes in pairs.

Recursive sketching structure

This hierarchical approach keeps the "sketching" dimension independent of the total number of modes $N$. Furthermore, the authors adapt techniques from matrix literature to tensors, allowing them to sample rows from a distribution that closely mirrors the ideal, exact leverage score distribution. Crucially, they designed a scheme to compute these sampling probabilities without ever forming the full, exponentially large probability distribution, treating the computation itself as a small tensor ring contraction.

Key Insights: Polynomial vs. Exponential Scaling

The most significant theoretical contribution of this work is shifting the algorithm's dependence on the number of modes $N$ from the exponent to a coefficient.

Complexity comparison for CP decomposition

As shown in the complexity comparisons, previous state-of-the-art methods like CP-ARLS-LEV scale exponentially ($R^N$). In contrast, the proposed CP-ALS-ES scales polynomially. This mathematical guarantee makes high-order tensor decomposition (e.g., 10+ modes) feasible in scenarios where it was previously impossible.

Unlike many heuristic randomized methods, this approach also provides rigorous worst-case relative error guarantees, meaning we can mathematically bound how far the sampled solution will deviate from the optimal one with high probability.

Empirical Results

The paper evaluates the algorithms across several rigorous benchmarks:

  1. High-Order Speedups (Synthetic Tensors): On a synthetic 10-way tensor designed to test large-$N$ scaling, the proposed CP-ALS-ES achieved an accurate solution in just 4.8 seconds. The previous state-of-the-art (CP-ARLS-LEV) took 350 seconds—a massive 73x speedup.
  2. Distribution Quality (Visual Data): Using a high-resolution image reshaped into a 6-way tensor, the authors demonstrated that the KL-divergence between their proposed sampling distribution and the exact leverage scores was often 2-3 orders of magnitude lower than previous methods. It successfully tracks the "true" importance of data points even in high-rank scenarios.
  3. Real-World Accuracy (COIL-100): On a benchmark dataset of 7,200 color images used for feature extraction and k-NN classification, the randomized methods achieved near-identical accuracy (approx. 98%) to the much slower deterministic ALS, but in a fraction of the time.

Limitations and Future Work

While highly efficient, the authors note a few limitations to their approach:

  • Monotonicity: Like most randomized ALS variants, these algorithms do not guarantee that the objective function will strictly decrease at every single step, though it generally trends downward over time.
  • Dense vs. Sparse Tensors: The current implementation and theoretical analysis focus heavily on dense tensors. Extending these recursive sketching techniques to sparse tensors (where the vast majority of entries are zero) remains a promising direction for future research.
  • Numerical Stability: The sampling formulas involve complex sums of products. In very ill-conditioned cases, this can occasionally lead to "catastrophic cancellation" or numerical instability, suggesting a need for more robust probability computation methods in edge cases.

Summary updated

BibTeX
@inproceedings{malik2022more,
  author = {Osman Asif Malik},
  title = {{More Efficient Sampling for Tensor Decomposition With Worst-Case Guarantees}},
  booktitle = {International Conference on Machine Learning},
  year = {2022},
}
Figure