Clad version 0.5
Introduction
This document contains the release notes for the automatic differentiation plugin for clang Clad, release 0.5. Clad is built on top of Clang and LLVM compiler infrastructure. Here we describe the status of Clad in some detail, including major improvements from the previous release and new feature work.
Note that if you are reading this file from a git checkout, this document applies to the next release, not the current one.
What's New in Clad 0.5?
Some of the major new features and improvements to Clad are listed here. Generic improvements to Clad as a whole or to its underlying infrastructure are described first.
External Dependencies
- clang-5.0
Forward & Reverse Mode
- Extend the way to specify a dependent variables. Consider function,
double f(double x, double y, double z) {...}
,clad::differentiate(f, "z")
is equivalent toclad::differentiate(f, 2)
.clad::gradient(f, "x, y")
differentiates with respect tox
andy
but notz
. The gradient results are stored in a_result
parameter in the same order asx
andy
were specified. Namely, the result ofx
is stored in_result[0]
and the result ofy
in_result[1]
. If we invert the arguments specified in the string toclad::gradient(f, "y, x")
the results will be stored inversely. - Enable recursive differentiation.
- Support single- and multi-dimensional arrays -- works for arrays with constant size like
double A[] = {1, 2, 3};
,double A[3];
ordouble A[1][2][3][4];
Reverse Mode
- Support variable reassignments. For example,
double f(double x, double y) {
double a = x * x;
double b = y * y;
double c = a + b;
return c;
}
Misc
- Add coverity static analyzer to the pull request builds.
- Fix found by coverity issues.
- Improved README.
Fixed Bugs
Special Kudos
This release wouldn't have happened without the efforts of our contributors,
listed in the form of Firstname Lastname (#contributions):
FirstName LastName (#commits):
- Aleksandr Efremov(7)
- Vassil Vassilev (6)
- Oksana Shadura (2)