-
-
Notifications
You must be signed in to change notification settings - Fork 185
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP] Testing compatibility of user-defined gradients approach #2667
Conversation
…4.1 (tags/RELEASE_600/final)
…4.1 (tags/RELEASE_600/final)
Looks like there's some compatibility issues with the older g++, closing to investigate |
…4.1 (tags/RELEASE_600/final)
…4.1 (tags/RELEASE_600/final)
…4.1 (tags/RELEASE_600/final)
…4.1 (tags/RELEASE_600/final)
…4.1 (tags/RELEASE_600/final)
Cool beans! Is there some design doc around? Would this approach also allow for efficient Jacobian adjoint product things, which is more efficient in case we only want the gradient in reverse mode? Having analytic gradients is a great thing, don't get me wrong! If you want to performance sensitive test, then you can attempt to make this work with a non-stiff ODE problem and use the RK45 integrator. Supplying the gradient for the user defined ODE RHS should speed up things a lot if this approach is fast. |
Thanks! Yep, the latest iteration added an implementation where the gradient function can be specified as an adjoint-jacobian product, either for just reverse-mode or for both reverse- and forward-mode. A design-doc is still in the works, just want to make sure that all works downstream first! |
Closing for now to clear PR backlog, will re-open once ready for review |
This PR is being used to test the downstream compatibility of an approach to user-defined gradients. Given that the approach is based on a lot of specialised tuple manipulation and general template trickery, I'd like to make sure that it's not fragile to any of the various compilation/testing layers in the pipeline.
I have replaced the gradient specifications for a unary function (
exp
), binary function (hypot
), and a matrix/varmat function (diag_pre_multiply
) to see whether compilation and values/gradients are stable throughout the pipeline