Automatic Differentiation for Tensor Algebras
Sebastian Urban, Patrick van der Smagt

TL;DR
This paper introduces an algorithm that automatically derives derivatives of tensor expressions with complex index mappings, enabling efficient gradient computation for tensor algebra compilers in machine learning.
Contribution
It presents a novel algorithm capable of handling arbitrary linear index combinations in tensor derivatives, automating the insertion of sums and Kronecker deltas.
Findings
Algorithm handles all index mapping cases automatically.
Generated derivatives are suitable for tensor algebra compiler input.
Source code implementation is provided.
Abstract
Kjolstad et. al. proposed a tensor algebra compiler. It takes expressions that define a tensor element-wise, such as , and generates the corresponding compute kernel code. For machine learning, especially deep learning, it is often necessary to compute the gradient of a loss function with respect to parameters . If tensor compilers are to be applied in this field, it is necessary to derive expressions for the derivatives of element-wise defined tensors, i.e. expressions for . When the mapping between function indices and argument indices is not 1:1, special attention is required. For the function , the derivative of the loss is ; the…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Code & Models
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsParallel Computing and Optimization Techniques · Computational Physics and Python Applications · Tensor decomposition and applications
