-
Notifications
You must be signed in to change notification settings - Fork 89
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
Caching computations in forward mode #192
Comments
The reason for computing the primal and tangent together is for things like e.g. the In terms of evaluation at multiple tangents, the plan is to enable pushing entire bases through at the same time. |
To be clear we actually do support the core of JuliaDiff/ChainRulesCore.jl#92 already. I think the real question of JuliaDiff/ChainRulesCore.jl#92 |
Suppose we have a function
f: ℝᵐ → ℝⁿ
that for some reason we want to differentiate in forward mode, which will require calling allfrule
sm
times. This seems wasteful, as the pushforwards often depend on intermediates of the primal function that don't change. In the current implementation offrule
s, where the output of the pushforward is computed at the same time as the output of the primal, these intermediates would need to be recomputedm
times. An example is symmetric eigendecomposition, where the eigendecomposition really only needs to be computed once but will instead be computedm
times.I'm sure there are good reasons for implementing this way. One I can think of is that it's easier to support mutating rules. Are there others?
The text was updated successfully, but these errors were encountered: