{"title":"用高阶函数的自定义导数组成自动微分法","authors":"Sam Estep","doi":"arxiv-2408.07683","DOIUrl":null,"url":null,"abstract":"Recent theoretical work on automatic differentiation (autodiff) has focused\non characteristics such as correctness and efficiency while assuming that all\nderivatives are automatically generated by autodiff using program\ntransformation, with the exception of a fixed set of derivatives for primitive\noperations. However, in practice this assumption is insufficient: the\nprogrammer often needs to provide custom derivatives for composite functions to\nachieve efficiency and numerical stability. In this work, we start from the\nuntyped lambda calculus with a reverse-mode autodiff operator, extend it with\nan operator to attach manual derivatives, and demonstrate its utility via\nseveral examples.","PeriodicalId":501197,"journal":{"name":"arXiv - CS - Programming Languages","volume":null,"pages":null},"PeriodicalIF":0.0000,"publicationDate":"2024-08-14","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":"{\"title\":\"Composing Automatic Differentiation with Custom Derivatives of Higher-Order Functions\",\"authors\":\"Sam Estep\",\"doi\":\"arxiv-2408.07683\",\"DOIUrl\":null,\"url\":null,\"abstract\":\"Recent theoretical work on automatic differentiation (autodiff) has focused\\non characteristics such as correctness and efficiency while assuming that all\\nderivatives are automatically generated by autodiff using program\\ntransformation, with the exception of a fixed set of derivatives for primitive\\noperations. However, in practice this assumption is insufficient: the\\nprogrammer often needs to provide custom derivatives for composite functions to\\nachieve efficiency and numerical stability. In this work, we start from the\\nuntyped lambda calculus with a reverse-mode autodiff operator, extend it with\\nan operator to attach manual derivatives, and demonstrate its utility via\\nseveral examples.\",\"PeriodicalId\":501197,\"journal\":{\"name\":\"arXiv - CS - Programming Languages\",\"volume\":null,\"pages\":null},\"PeriodicalIF\":0.0000,\"publicationDate\":\"2024-08-14\",\"publicationTypes\":\"Journal Article\",\"fieldsOfStudy\":null,\"isOpenAccess\":false,\"openAccessPdf\":\"\",\"citationCount\":\"0\",\"resultStr\":null,\"platform\":\"Semanticscholar\",\"paperid\":null,\"PeriodicalName\":\"arXiv - CS - Programming Languages\",\"FirstCategoryId\":\"1085\",\"ListUrlMain\":\"https://doi.org/arxiv-2408.07683\",\"RegionNum\":0,\"RegionCategory\":null,\"ArticlePicture\":[],\"TitleCN\":null,\"AbstractTextCN\":null,\"PMCID\":null,\"EPubDate\":\"\",\"PubModel\":\"\",\"JCR\":\"\",\"JCRName\":\"\",\"Score\":null,\"Total\":0}","platform":"Semanticscholar","paperid":null,"PeriodicalName":"arXiv - CS - Programming Languages","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/arxiv-2408.07683","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
Composing Automatic Differentiation with Custom Derivatives of Higher-Order Functions
Recent theoretical work on automatic differentiation (autodiff) has focused
on characteristics such as correctness and efficiency while assuming that all
derivatives are automatically generated by autodiff using program
transformation, with the exception of a fixed set of derivatives for primitive
operations. However, in practice this assumption is insufficient: the
programmer often needs to provide custom derivatives for composite functions to
achieve efficiency and numerical stability. In this work, we start from the
untyped lambda calculus with a reverse-mode autodiff operator, extend it with
an operator to attach manual derivatives, and demonstrate its utility via
several examples.