-
Notifications
You must be signed in to change notification settings - Fork 38
fix: correct type for ad annotation #1822
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
base: main
Are you sure you want to change the base?
Conversation
src/Enzyme.jl
Outdated
| mode::CMode, f::FA, args::Vararg{Annotation,Nargs} | ||
| ) where {CMode<:Mode,FA<:Annotation,Nargs} | ||
| # need to guess the correct activity here. Execute the function, we will DCE it | ||
| res = call_with_reactant(f.val, [x.val for x in args]...) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
er, not always -- if f mutates this is wrong
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the slightly more ideal case would be calling like https://github.com/EnzymeAD/Enzyme.jl/blob/bc031934aa2deefdcd3be139e4ad9a28e3692d14/src/typeutils/inference.jl#L73, except with our interpreter
3eeb45d to
072cc89
Compare
58275d7 to
be74bb5
Compare
be74bb5 to
5ab6391
Compare
* feat: batched_jacobian for Reactant [skip ci] * test: setup * feat: lower to a looped batched jacobian * test: batched jacobian now exists * feat: forward mode will work once EnzymeAD/Reactant.jl#1822 lands * test: add tests for batched jacobian * fix: explicit imports
fixes #1821