You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think this could be tested in the autodiff test framework. The test would be set the adjoints of the inputs to something non-zero, do the reverse mode pass, and then check the adjoints have been incremented by what you'd expect if the adjoints had been zero.
If this is fixed without the more general fix to the autodiff tester, make a new issue for that.
Current Version:
v3.3.0
The text was updated successfully, but these errors were encountered:
Description
@SteveBronder found that softmax isn't quite working right. The reverse mode softmax code here sets the adjoint instead of incrementing it: https://github.com/stan-dev/math/blob/develop/stan/math/rev/fun/softmax.hpp#L39
Changing the
=
to+=
fixes the problem.I think this could be tested in the autodiff test framework. The test would be set the adjoints of the inputs to something non-zero, do the reverse mode pass, and then check the adjoints have been incremented by what you'd expect if the adjoints had been zero.
If this is fixed without the more general fix to the autodiff tester, make a new issue for that.
Current Version:
v3.3.0
The text was updated successfully, but these errors were encountered: