Hardness of Low Rank Approximation of Entrywise Transformed Matrix Products

Inspired by fast algorithms in natural language processing, we study low rank approximation in the entrywise transformed setting where we want to find a good rank $k$ approximation to $f(U \cdot V)$, where $U, V^\top \in \mathbb{R}^{n \times r}$ are given, $r = O(\log(n))$, and $f(x)$ is a general scalar function. Previous work in sublinear low rank approximation has shown that if both (1) $U = V^\top$ and (2) $f(x)$ is a PSD kernel function, then there is an $O(nk^{\omega-1})$ time constant relative error approximation algorithm, where $\omega \approx 2.376$ is the exponent of matrix multiplication. We give the first conditional time hardness results for this problem, demonstrating that both conditions (1) and (2) are in fact necessary for getting better than $n^{2-o(1)}$ time for a relative error low rank approximation for a wide class of functions. We give novel reductions from the Strong Exponential Time Hypothesis (SETH) that rely on lower bounding the leverage scores of flat sparse vectors and hold even when the rank of the transformed matrix $f(UV)$ and the target rank are $n^{o(1)}$, and when $U = V^\top$. Furthermore, even when $f(x) = x^p$ is a simple polynomial, we give runtime lower bounds in the case when $U \neq V^\top$ of the form $\Omega(\min(n^{2-o(1)}, \Omega(2^p)))$. Lastly, we demonstrate that our lower bounds are tight by giving an $O(n \cdot \text{poly}(k, 2^p, 1/\epsilon))$ time relative error approximation algorithm and a fast $O(n \cdot \text{poly}(k, p, 1/\epsilon))$ additive error approximation using fast tensor-based sketching. Additionally, since our low rank algorithms rely on matrix-vector product subroutines, our lower bounds extend to show that computing $f(UV)W$, for even a small matrix $W$, requires $\Omega(n^{2-o(1)})$ time.

Paper

References (31)

Scroll for more · 19 remaining

Similar papers

Peer review

Reviewer 26kb7/10 · confidence 4/52023-06-28

Summary

This paper studies the problem of computing a low-rank approximation (LRA) for $f(UV)$, where $U\in \mathbb{R}^{n\times r}$, $V\in \mathbb{R}^{r\times n}$, and $f:\mathbb{R}\rightarrow \mathbb{R}$ applies to each entry of $UV$. This problem has very important applications in deep learning, in particular for Transformers and natural language processing. The main results of this paper consist of two parts: For lower bounds, they show that we cannot get subquadratic relative error LRA generally when either 1) $U\ne V^\top$ even for PSD kernel functions or 2) for $f$ that are approximately polynomials of $|x|$ even for a constant degree. For upper bounds, they show that for $f(x) = x^p$, there is an $O(n\cdot poly(r^p, k, 1/\epsilon))$-time algorithm for relative error LRA and $O(n \cdot poly(p, k, 1/\epsilon))$-time for additive error LRA. Furthermore, their techniques can be generalized to obtain lower bounds for the implicit matrix-vector multiplications of the form $f(UV)z$.

Strengths

This paper significantly advances our understanding of LRA with very solid results. Prior to this work, most of the research focuses on the symmetric setting where $U=V^\top$. This paper considers the more general, asymmetric setting. For relative error LRA and $f(x)=x^p$, their lower bound almost matches their upper bound in terms of the dependence on $p$. On the other hand, they also make progress in the symmetric setting. Their lower bound in the symmetric setting applies to a larger family of the function $f$ compared to previous results. Technically, they provide clean and novel reductions from the orthogonal vector problem (OV) to LRA via the fast computation of leverage scores. The reductions in this paper will be useful in proving new lower bounds for other numerical linear algebra problems. Additionally, this paper provides a clear review of many related works about LRA.

Weaknesses

The algorithms proposed in this paper is quite straightforward given prior results [Woodruff, 2014] and [Ahle et al., 2020]. Also, the lower bound for LRA with an even $p$ is weak. And the lower bounds do not depend on $r$ and $k$, the dimensions of the input matrices and output matrices, respectively. Moreover, there are some typos in the proofs that affects reading this paper.

Questions

1. Line 157: define $B_i$. 2. Do the lower bounds for OV (Assumption 1) and Max-IP (Assumption 4) hold for randomized algorithms? They may be based on (randomized) SETH. 3. Line 262: $s\leq r^p$.$s$ has already been used to represent the number of vectors in OV. I guess the $s$ here is different? 4. Line 265: the derivation of the below equation via the Pythagorean theorem is unclear to me. And how does it imply that when we are in case 2, there is a column of $U’V’$ that is $\alpha+1/poly(n)$ far from the column span of $U’’$? 5. Line 287: how do you construct the vectors $v$ and $e$? 6. Line 306: where does the $n^{o(1)}dr^ps$ come from? Shouldn’t it be $n^{o(1)}ds$?

Rating

7: Accept: Technically solid paper, with high impact on at least one sub-area, or moderate-to-high impact on more than one areas, with good-to-excellent evaluation, resources, reproducibility, and no unaddressed ethical considerations.

Confidence

4: You are confident in your assessment, but not absolutely certain. It is unlikely, but not impossible, that you did not understand some parts of the submission or that you are unfamiliar with some pieces of related work.

Soundness

3 good

Presentation

3 good

Contribution

3 good

Limitations

n/a

Reviewer ExZq6/10 · confidence 2/52023-07-06

Summary

The authors discuss a setting where one observes a scalar transformation of an r-rank matrix, f(UV) and wants to find the best k-rank approximation of it. It is known that under various assumptions, if f(UU^t) is PSD then the problem is solvable in nearly linear time. It is also known that for various kernels f (eg Gaussian kernel), one needs quadratic time. The authors discuss the cases where f are simple monomials, f(x)=x^p. They show a min(2^p,n^2) time lower bound based on SETH. They also show a matching upper bound, among other results.

Strengths

The paper seems novel and interesting. The connection with SETH is non-trivial and intruiguing.

Weaknesses

I am failing to see the importance of choosing the x^p activation function (besides the log(1+|x|) example). Could the authors elaborate more on it?

Questions

See above.

Rating

6: Weak Accept: Technically solid, moderate-to-high impact paper, with no major concerns with respect to evaluation, resources, reproducibility, ethical considerations.

Confidence

2: You are willing to defend your assessment, but it is quite likely that you did not understand the central parts of the submission or that you are unfamiliar with some pieces of related work. Math/other details were not carefully checked.

Soundness

2 fair

Presentation

2 fair

Contribution

3 good

Limitations

See above.

Reviewer GCRp6/10 · confidence 3/52023-07-07

Summary

This paper studies the problem of low rank approximation of the form f(U.V) where the matrices U,V $\in \mathbb{R}^{n \times r}$ and $r=O(\log n)$ and $f(.)$ is applied entrywise. The main contributions of the paper are the following: 1) The paper presents a $\Omega(n^{2-o(1)})$ time lower bound for getting relative error rank $k$ approximation to $f(U.V)$ for $k=n^{o(1)}$ and $f(x)$ admits a Taylor series expansion of the form $f(x)=x^p+O(|x|^{p+1})$ when $p$ is odd and $p=O(\log n)$. This lower bound holds for any $U, V$. Another $\min(n^{2-o(1)},2^{\Omega(p)})$ time lower bound, which only holds when $U \neq V^T$, is presented for the case when $f(x)=x^p$ for any general integer $p \geq 1$. The first lower bound proof for odd $p$ follows by a reduction of the Orthogonal Vectors Problem to the Low-Rank Approximation (LRA) problem of $f(U.V)$. The proof then proceeds by lower bounding the leverage score of rows corresponding to non-zero entries of a flat sparse vector in the column span of the low-rank approximation of $f(U.V)$. The second lower bound proof for a general $p$ follows by a reduction of the Approximate Maximum Inner Product problem respectively to the LRA problem. 2) The paper presents a $O(n . poly(2^p,k,\frac{1}{\epsilon}))$ time algorithm for getting a $1+\epsilon$ relative error low-rank approximation to $f(U.V)$ mathcing the lower bound. The algorithm uses random Gaussian sketching of the Khatri-Rao products of U and V followed by a low-rank approximation of the smaller sketches. The paper also presents a $O(n, poly(k,p, \frac{1}{\epsilon}))$ time algorithm for getting a low-ran approximation with additive $\epsilon . L$ guarantee where $L$ depends on the $p$-norms of $U,V$. Thi algorithm proceeds by doing a tensor sketch of the Kahtri-Rao products of $U$ and $V$. 3) Finally, the paper presents a lower bound of $\Omega(n^{2-o(1)})$ on matrix vector products of the form $f(UV)z$ for a vector $z \in \mathbb{R}^n$ using the fact that the algorithms use a matrix vector product subroutine.

Strengths

1) Previous subquadratic time algorithms for relative error low-rank approximation for $f(U.V)$ assume that $U=V^T$ and $f(x)$ is a PSD kernel function. The quadratic lower bounds for relative error low-rank approximation of $f(U.V)$ for polynomial $f(.)$ show that both these assumptions are necessary for a subquadratic algorithm. This is an interesting result of broader interest to the sketching community. The lower bound proof techniques via reductions from OVP and MIP problems and bounding the leverage score of flat sparse vectors are also novel. 2) The paper is generally easy to follow for the most part.

Weaknesses

1) Apart from the lower bounds of Theorem 3.1 and 3.3, the other results seem to be straightforward extensions of these results or, for the case of the upper bounds, applications of existing algorithms and results in the literature. 2) Though the results are interesting, the intuition behind some of the theoretical results presented in the paper are unclear. a) Specifically, it might be useful to explain more in detail why is there a separation in the lower bound between the $U=V^T$ and $U \neq V^T$ cases for general $p$. b) It might be good to explain why the lower bound for general $p$ extend to more general functions with Taylor series of the form $f(x)=x^p+O()$ like in the case for odd $p$. Where is the bottleneck for general $p$? 2) Though this is primarily a theoretical paper, in the context of Neurips, some experimental evaluation of the algorithms for LRA might be useful for understanding how well the algorithms perform well in practice. There are also some typos and confusing notations in the paper: 1) In the line 260, $Z$ has dimension $n \times s$. The $s$ here is the rank of $U''$ and is different from the dimension of the vectors $a_i$ and $b_i$. 2) In the statement of Theorem 4.1, on the RHS, it seems the $U,V$ in argument $\min_{U,V}$ should be changed to different notation as this is different from the input to the problem.

Questions

Other than the points raised above, there doesn't seem to be any discussion on the lower bound for additive error so it is unclear how good the upper bound presented in Theorem 4.2 is. It might be useful to add a short discussion there.

Rating

6: Weak Accept: Technically solid, moderate-to-high impact paper, with no major concerns with respect to evaluation, resources, reproducibility, ethical considerations.

Confidence

3: You are fairly confident in your assessment. It is possible that you did not understand some parts of the submission or that you are unfamiliar with some pieces of related work. Math/other details were not carefully checked.

Soundness

3 good

Presentation

3 good

Contribution

2 fair

Limitations

I don't think there are any other limitations other than the ones mentioned above.

Authorsrebuttal2023-08-16

More Intuition

We again thank the reviewer and will add more intuition for our lower bound proofs, which interestingly provide a separation between the $U = V$ and $U \neq V$ case. As mentioned in our submission, when $U \neq V$, we can reduce to the APX-Max-IP problem, where we want to find a small set of pairs of vectors that have a large inner product. Here the inner product is at least max/100 and there are at most $n^{o(1)}$ such pairs; see Assumption 4 in the submission. Consider this small set of large inner product pairs, which represents a small number of entries in $UV$ that are large in magnitude (i.e. when you apply a threshold at max/100, the resulting matrix is sparse). Since $f(x) = x^p$ amplifies the magnitude differences, it follows that $f(UV)$ is much closer relatively to an approximately sparse, and therefore low rank, matrix (i.e. by thresholding and removing the terms that have magnitude less than $(max/100)^p$). Therefore an approximate low rank approximation (LRA) algorithm can recover this sparse low rank matrix well enough so that the span of the approximate matrix can be used, via leverage score computations, to solve the APX-Max-IP problem. Our lower bounds do not generalize to the case when $U = V$ because the sparsity structure is broken as the diagonal of the matrix $UV$ is now larger than the maximum inner product of two different vectors, and this destroys the low rank structure. In some sense, the diagonal of our matrix is forced to include the dot product of $u_i$ with itself and this shifts the entire matrix by a large multiple of the identity, crucially removing the sparse + low-rank structure that we exploited in our lower bound argument before. Indeed, as mentioned in the paper, the positive semidefinite (PSD) structure when $U = V$ allows us to derive a fast LRA algorithm and our lower bound no longer holds in this setting. Furthermore, for our lower bounds for $f(x) = |x|^p$, note that we use a different structural property that holds even when $U = V$. For intuition as to why $p$ being odd is necessary for having a stronger lower bound in this setting, note that we now perform reduction to OVP. In this setting, note that our clever reduction forces the absolute value operation to essentially alter entries of $(UV)^p$ but only at entries of the original $UV$ with zero dot product. Therefore, we can write $f(UV)$ as a sum of a low rank matrix (from tensor product) and a sparse matrix, whose sparse entries now represent the OVP pairs. Then, either the sparse matrix forces LRA to have high error or if it does not have high error, then we can recover the sparse matrix by taking the difference of the LRA and the low rank tensor product. Note that this does not hold when p is even since the absolute value does not induce the additional sparse matrix; however, this structure still holds when $U = V$ since the diagonal terms are absorbed by the low rank matrix. If our understanding is correct, the reviewer does not seem to be concerned with the main contribution of our paper, which is our novel lower bounds for low rank approximation of element-wise transformed matrices. As the discussion phase will end soon, we ask if there is anything else we can help to clarify the contributions in our submission.

Reviewer GCRp2023-08-16

I thank the authors for addressing my concerns. The intuition for the having an odd p for a stronger lower bound is clearer now. I'm upgrading the score based on the responses. Please include the relevant points in the paper.

Reviewer 9ux26/10 · confidence 1/52023-07-25

Summary

For two matrices U,V one is often interested in computing f(UV) for some entrywise function f. Several papers in the past decade considered the problem of approximating f(UV) by a product AB with small inner-dimension (low-rank approximation). While a number of past papers presented clever positive results, this paper is about demonstrating various negative results. I am very far from the field of complexity and cannot evaluate soundedness of the claims. However, I should say that the negative results are probably best presented in a different venue (SODA etc), since this conference is mostly interested in doing things rather than in enumerating all things that cannot be done.

Strengths

Key problem of contemp interest.

Weaknesses

Complexity results are likely irrelevant to most attendees.

Questions

n/a

Rating

6: Weak Accept: Technically solid, moderate-to-high impact paper, with no major concerns with respect to evaluation, resources, reproducibility, ethical considerations.

Confidence

1: Your assessment is an educated guess. The submission is not in your area or the submission was difficult to understand. Math/other details were not carefully checked.

Soundness

3 good

Presentation

3 good

Contribution

2 fair

Limitations

n/a

Reviewer ExZq2023-08-14

I thank the authors for their response. Regarding the Taylor series argument, do you mean "f admits a Taylor expansion" for the whole real line or literally in a neighborhood "around 0"? This is important to clarify. I keep my score (6), with low confidence.

Authorsrebuttal2023-08-15

Re: Comment

When we say "$f$ admits a Taylor expansion", we are adopting the classic convention that $f$ can be represented by an infinite Taylor expansion (centered at 0) for the whole real line. However, in our proofs, we only use the approximation guarantees in a neighborhood around 0. However, for ease of reading, we generally assume the stronger condition.

Reviewer 26kb2023-08-14

I thank the authors for their response and clarification. I keep my score.

Reviewer 9ux22023-08-21

Thank you authors for your response. Considering the association of your result with transformers, I have updated my score to 6.

Program Chairsdecision2023-09-21

Decision

Accept (poster)

© 2026 NYSGPT2525 LLC