将 Enzyme 生成的函数集成到 CoDiPack 中
Integrating Enzyme-generated functions into CoDiPack
AI总结:
本文针对运算符重载算法微分中自定义导数函数手动实现繁琐的问题,在 CoDiPack 中新增辅助机制,使其可在记录阶段自动集成 Enzyme 生成的导数函数,并通过合成基准验证了有效性。
摘要:
在运算符重载算法微分中,为代码库的某些部分创建自定义导数函数可能是有益的。对于导数函数的手动实现,推导、实现、测试和维护这些函数可能相当繁琐。该过程可以通过 Tapenade 等源变换算法微分工具或 Enzyme 等基于编译器的算法微分工具实现自动化。这消除了手动实现所需的大部分工作,但通常在时间和内存方面具有相同的效率。我们在 CoDiPack 中提出了一种新的辅助工具,它允许在 CoDiPack 的记录过程中自动添加 Enzyme 生成的导数函数。该方法的有效性在一个合成基准上得到了证明,并显示出良好的结果。
英文摘要:
In operator overloading algorithmic differentiation, it can be beneficial to create custom derivative functions for some parts of the code base. For manual implementations of the derivative functions, it can be quite cumbersome to derive, implement, test, and maintain these. The process can be automated with source transformation algorithmic differentiation tools like Tapenade or compiler-based algorithmic differentiation tools like Enzyme. This eliminates most of the work required from a manual implementation but usually has the same efficiency with respect to timing and memory. We present a new helper in CoDiPack that allows Enzyme-generated derivative functions to be automatically added during the recording process of CoDiPack. The validity of the approach is demonstrated on a synthetic benchmark, which shows promising results.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。