Custom VJP with class / method #17132
Replies: 1 comment 3 replies
-
It's hard to piece together exactly what code you're executing when you see this error. Would it be possible for you to put together a minimal reproducible example? |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I want to implement a custom VJP for a class, which implements a nn.module (using Flax). An example:
Outside of the class, I've defined my custom VJP:
However, I get this error:
I assume this is because I cannot pass a method into the custom VJP, even with defining nondiff_arguments? Is there a way to solve this - should I be moving my custom VJP inside the class?
Any tips helpful, thanks!
Beta Was this translation helpful? Give feedback.
All reactions