-
Notifications
You must be signed in to change notification settings - Fork 78
Open
Description
As discussed on Slack, it is sometimes annoying to use reverse mode because you need autodiff_thunk
whenever
- the function output is a number and the cotangent is different from
1.0
- the function output is anything but a number
A solution suggested by @wsmoses would be syntactic sugar for vjp
(and maybe jvp
but that is less necessary cause autodiff
gets the job done every time). There are a few design questions around this:
- Should we put
dreturn
together with the return activity?- Good: 1 argument instead of 2
- Bad: in the case of
Duplicated
returns, we would have to specifydreturn = Duplicated(whatever, actual_thing_we_care_about)
.
- Can we generalize this to batch mode
vjp
? How do we pass several cotangents if the return value isActive
?
Metadata
Metadata
Assignees
Labels
No labels