EigenDecomposition (ED) is at the heart of many computer vision algorithms and applications. One crucial bottleneck limiting its usage is the expensive computation cost, particularly for a mini-batch of matrices in the deep neural networks. In this paper, we propose a QR-based ED method dedicated to the application scenarios of computer vision. Our proposed method performs the ED entirely by batched matrix/vector multiplication, which processes all the matrices simultaneously and thus fully utilizes the power of GPUs. Our technique is based on the explicit QR iterations by Givens rotation with double Wilkinson shifts. With several acceleration techniques, the time complexity of QR iterations is reduced from $O{(}n^5{)}$ to $O{(}n^3{)}$. The numerical test shows that for small and medium batched matrices (\emph{e.g.,} $dim{<}32$) our method can be much faster than the Pytorch SVD function. Experimental results on visual recognition and image generation demonstrate that our methods also achieve competitive performances.
翻译:EigenDecomposition (ED) 是许多计算机视觉算法和应用程序的核心。 限制其使用的关键瓶颈之一是昂贵的计算成本, 特别是对于深神经网络中的小型矩阵而言。 在本文中, 我们提议了一种基于QR的 ED 方法, 专门用于计算机视觉应用情景的应用。 我们建议的方法完全通过分批矩阵/ Victor 乘法来进行 ED, 该方法同时处理所有矩阵, 从而充分利用 GPUs 的力量。 我们的技术基于两种 Wilkinson 转换的Gives 旋转 明显 QR 迭代 。 在几种加速技术下, QR 转换的时间复杂性从 ${ (}n}5{}} 降低到 ${ (}n{3{}} 美元。 数字测试显示, 对于中小批量矩阵(\ emph{e. g.} $ dim ⁇ 32$), 我们的方法可以比 Pytorch SVD 函数快得多。 视觉识别和图像生成的实验结果显示我们的方法也具有竞争性性。