QR and LQ Decomposition Matrix Backpropagation Algorithms for Square, Wide, and Deep -- Real or Complex -- Matrices and Their Software Implementation
This work provides incremental improvements in numerical stability and efficiency for backpropagation in deep learning applications involving matrix decompositions.
The authors tackled the problem of backpropagation through QR and LQ decompositions for various matrix shapes, deriving novel algorithms for pivoted QR and LQ decompositions to enable differentiable operations in machine learning tasks like least squares problems, with software implementations provided for PyTorch, TensorFlow, and MXNet.
This article presents matrix backpropagation algorithms for the QR decomposition of matrices $A_{m, n}$, that are either square (m = n), wide (m < n), or deep (m > n), with rank $k = min(m, n)$. Furthermore, we derive novel matrix backpropagation results for the pivoted (full-rank) QR decomposition and for the LQ decomposition of deep input matrices. Differentiable QR decomposition offers a numerically stable, computationally efficient method to solve least squares problems frequently encountered in machine learning and computer vision. Other use cases such as graph learning and network compression are listed in the article. Software implementation across popular deep learning frameworks (PyTorch, TensorFlow, MXNet) incorporate the methods for general use within the deep learning community. Furthermore, this article aids the practitioner in understanding the matrix backpropagation methodology as part of larger computational graphs.