arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2207.00847cs.PLcs.DCcs.LGcs.SC
收藏

组合伴随与微分

Combinatory Adjoints and Differentiation

DIKU, U. Copenhagen(哥本哈根大学DIKU);U. Edinburgh(爱丁堡大学)

Martin Elsman, Fritz Henglein, Robin Kaarsgaard, Mikkel Kragh Mathiesen, Robert Schenck

摘要:

我们开发了一种基于泛函分析中的分类结构的自动和符号微分的合成方法,其中导数是抽象向量上的线性函数,而不是仅限于标量,向量,矩阵或张量表示为多维数组。我们表明,符号和自动微分可以使用微分生成的线性函数表示Fréchet衍生物的基础上的规则,原始的,恒定的,线性和双线性函数,以及它们的顺序和并行组成。线性函数以组合域特定语言表示。最后,我们提供了一个演算符号计算伴随的衍生物,而不使用矩阵,这是太低效,使用高维空间。导数的最终符号表示保留了输入程序的数据-并行操作。组合微分和计算形式伴随的组合在行为上等价于反向模式的自动微分。特别是,它为矩阵效率太低而无法表示线性函数的优化提供了机会。

英文摘要:

We develop a compositional approach for automatic and symbolic differentiation based on categorical constructions in functional analysis where derivatives are linear functions on abstract vectors rather than being limited to scalars, vectors, matrices or tensors represented as multi-dimensional arrays. We show that both symbolic and automatic differentiation can be performed using a differential calculus for generating linear functions representing Fréchet derivatives based on rules for primitive, constant, linear and bilinear functions as well as their sequential and parallel composition. Linear functions are represented in a combinatory domain-specific language. Finally, we provide a calculus for symbolically computing the adjoint of a derivative without using matrices, which are too inefficient to use on high-dimensional spaces. The resulting symbolic representation of a derivative retains the data-parallel operations from the input program. The combination of combinatory differentiation and computing formal adjoints turns out to be behaviorally equivalent to reverse-mode automatic differentiation. In particular, it provides opportunities for optimizations where matrices are too inefficient to represent linear functions.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑