Abstract
Tapenade is an Automatic Differentiation (AD) tool which, given a Fortran or C code that computes a function, creates a new code that computes its tangent or adjoint derivatives. Tapenade puts particular emphasis on adjoint differentiation, which computes gradients at a remarkably low cost. This article describes the principles of Tapenade, a subset of the general principles of AD. We motivate and illustrate with examples the AD model of Tapenade, that is, the structure of differentiated codes and the strategies used to make them more efficient. Along with this informal description, we formally specify this model by means of data-flow equations and rules of Operational Semantics, making this the reference specification of the tangent and adjoint modes of Tapenade. One benefit we expect from this formal specification is the capacity to formally study the AD model itself, especially for the adjoint mode and its sophisticated strategies. This article also describes the architectural choices of the implementation of Tapenade. We describe the current performance of Tapenade on a set of codes that include industrial-size applications. We present the extensions of the tool that are planned in a foreseeable future, deriving from our ongoing research on AD.
- Aho, A., Sethi, R., and Ullman, J. 1986. Compilers: Principles, Techniques and Tools. Addison-Wesley. Google ScholarDigital Library
- Bischof, C. H., BüCker, H. M., Hovland, P. D., Naumann, U., and Utke, J., Eds. 2008. Advances in Automatic Differentiation. Lecture Notes in Computational Science and Engineering Series, vol. 64. Springer, Berlin. Google ScholarDigital Library
- Bücker, H. M., Corliss, G. F., Hovland, P. D., Naumann, U., and Norris, B., Eds. 2005. Automatic Differentiation: Applications, Theory, and Implementations. Lecture Notes in Computational Science and Engineering Series, vol. 50, Springer, New York, NY.Google Scholar
- Carle, A. and Fagan, M. 2000. ADIFOR 3.0 overview. Tech. rep. CAAM-TR-00-02, Rice University.Google Scholar
- Corliss, G., Faure, C., Griewank, A., Hascoët, L., and Naumann, U., Eds. 2002. Automatic Differentiation: from Simulation to Optimization. Springer, New York, NY. Google ScholarDigital Library
- Dervieux, A., Hascoët, L., Vazquez, M., and Koobus, B. 2005. Optimization loops for shape and error control. In B. Uthup, S.-P. Koruthu, R.-K. Sharma, and P. Priyadarshi, Eds., Recent Trends in Aerospace Design and Optimization, Tata-McGraw Hill, New Delhi, 363--373.Google Scholar
- Fagan, M., Hascoët, L., and Utke, J. 2006. Data representation alternatives in semantically augmented numerical models. In Proceedings of the 6th IEEE International Workshop on Source Code Analysis and Manipulation, (SCAM). Google ScholarDigital Library
- Forth, S. 2006. An efficient overloaded implementation of forward mode automatic differentiation in MATLAB. ACM Trans. Math. Softw. 32, 2, 195--222. Google ScholarDigital Library
- Forth, S., Hovland, P., Phipps, E., Utke, J., and Walther, A., Eds. 2012. Recent Advances in Algorithmic Differentiation. Lecture Notes in Computational Science and Engineering Series, vol. 87, Springer, Berlin. Google ScholarDigital Library
- Giering, R. 1997. Tangent linear and adjoint model compiler, users manual. Tech. rep. http://www.autodiff. com/tamc.Google Scholar
- Griewank, A. 1992. Achieving logarithmic growth of temporal and spatial complexity in reverse automatic differentiation. Optim. Meth. Softw. 1, 35--54.Google ScholarCross Ref
- Griewank, A. and Walther, A. 2008. Evaluating Derivatives: Principles and Techniques of Algorithmic Differentiation. 2nd Ed. Number 105 in Other Titles in Applied Mathematics. SIAM, Philadelphia, PA. Google ScholarCross Ref
- Hascoët, L., Fidanova, S., and Held, C. 2002. Adjoining independent computations. In G. Corliss, C. Faure, A. Griewank, L. Hascoët, and U. Naumann Eds., Automatic Differentiation: from Simulation to Optimization, Springer, New York, NY, 299--304. Google ScholarDigital Library
- Hascoët, L., Naumann, U., and Pascual, V. 2005. “To Be Recorded” analysis in reverse-mode Automatic Differentiation. Future Gen. Comput. Syst. 21, 8, 1401--1417. Google ScholarDigital Library
- Hascoët, L. and Pascual, V. 2004. TAPENADE 2.1 User's guide. Rapport technique 300, INRIA.Google Scholar
- Kahn, G. 1987. Natural Semantics. In Proceedings of STACS. 22--39. Google ScholarDigital Library
- Lauvernet, C., Baret, F., Hascoët, L., Buis, S., and Ledimet, F.-X. 2008. Multitemporal-patch ensemble inversion of coupled surface-atmosphere radiative transfer models for land surface characterization. Remote Sens. Environ. 112, 3, 851--861.Google ScholarCross Ref
- Lauvernet, C., Hascoët, L., Le Dimet, F.-X., and Baret, F. 2012. Using Automatic Differentiation to study the sensitivity of a crop model. In S. Forth, P. Hovland, C. H. Bischof, H. M. Bücker, P. D. Hovland, U., Naumann, and J. Utke, Eds. 2008. Advances in Automatic Differentiation. Lecture Notes in Computational Science and Engineering Series, vol. 64, Springer.Google Scholar
- Phipps, E., Utke, J., and Walther, A., Eds. Recent Advances in Algorithmic Differentiation. Lecture Notes in Computational Science and Engineering Series, vol. 87, Springer, Berlin, 59--69.Google Scholar
- Madec, G., Delecluse, P., Imbard, M., and Levy, C. 1998. OPA8.1 Ocean general circulation model reference manual. Tech. rep., Pole de Modelisation, IPSL.Google Scholar
- Naumann, U. 2012. The Art of Differentiating Computer Programs: An Introduction to Algorithmic Differentiation. Number 24 in Software, Environments, and Tools, SIAM, Philadelphia, PA. Google ScholarDigital Library
- Naumann, U. and Riehme, J. 2005. Computing adjoints with the NAGWare Fortran 95 compiler. In H. M. Bücker, G. F. Corliss, P. D. Hovland, U. Naumann, and B. Norris Eds., Automatic Differentiation: Applications, Theory, and Implementations. Lecture Notes in Computational Science and Engineering Series, vol. 50, Springer, New York, NY. 159--169.Google Scholar
- Naumann, U., Utke, J., Lyons, A., and Fagan, M. 2004. Control flow reversal for adjoint code generation. In Proceedings of the 4th IEEE International Workshop on Source Code Analysis and Manipulation (SCAM). IEEE Computer Society, Los Alamitos, CA, 55--64. Google ScholarDigital Library
- Plotkin, G. 2004. A structural approach to Operational Semantics. J. Logic Alg. Program. 60--61, 17--139.Google Scholar
- Rostaing, N., Dalmas, S., and Galligo, A. 1993. Automatic differentiation in Odyssee. Tellus A 45, 5, 558--568.Google ScholarCross Ref
- Shin, J., Malusare, P., and Hovland, P. 2008. Design and implementation of a context-sensitive, flow-sensitive activity analysis algorithm for automatic differentiation. In C. H. Bischof, H. M. Bücker, P. D. Hovland, U. Naumann, and J. Utke Eds., Advances in Automatic Differentiation, Lecture Notes in Computational Science and Engineering Series, vol. 64, Springer, Berlin, 115--125.Google Scholar
- Utke, J. and Naumann, U. 2004. Separating language dependent and independent tasks for the semantic transformation of numerical programs. In Proceedings of Software Engineering and Applications (SEA). 552--558.Google Scholar
- Utke, J., Naumann, U., Fagan, M., Tallent, N., Strout, M., Heimbach, P., Hill, C., and Wunsch, C. 2008. OpenAD/F: A modular, open-source tool for Automatic Differentiation of Fortran codes. ACM Trans. Math. Softw. 34, 4, 1--36. Google ScholarDigital Library
- Walther, A. and Griewank, A. 2012. Getting started with ADOL-C. In U. Naumann and O. Schenk Eds., Combinatorial Scientific Computing. Chapman-Hall CRC Computational Science, Chapter 7, 181--202.Google Scholar
Index Terms
- The Tapenade automatic differentiation tool: Principles, model, and specification
Recommendations
OpenAD/F: A Modular Open-Source Tool for Automatic Differentiation of Fortran Codes
The Open/ADF tool allows the evaluation of derivatives of functions defined by a Fortran program. The derivative evaluation is performed by a Fortran code resulting from the analysis and transformation of the original program that defines the function ...
Algorithmic Differentiation of Code with Multiple Context-Specific Activities
Algorithmic differentiation (AD) by source-transformation is an established method for computing derivatives of computational algorithms. Static dataflow analysis is commonly used by AD tools to determine the set of active variables, that is, variables ...
Automatic differentiation of explicit Runge-Kutta methods for optimal control
This paper considers the numerical solution of optimal control problems based on ODEs. We assume that an explicit Runge-Kutta method is applied to integrate the state equation in the context of a recursive discretization approach. To compute the ...
Comments