-
Notifications
You must be signed in to change notification settings - Fork 63
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
support varargs in @non_differentiable #212
Comments
Currently when I do: jl> using ChainRules
jl> function h(a, x::Vararg{Any}; kwargs...)
return a
end
jl> @non_differentiable h(::Vararg{Any})
jl> rrule(h, 1, 2)[2](1)
(Zero(), DoesNotExist(), DoesNotExist()) Doesn't it mean that it does support |
I can't reproduce your results, for me it errors:
What version of ChainRules and julia were you using? Have you defined other methods of |
Sorry, you'll have to uncomment this block of code: https://github.com/JuliaDiff/ChainRulesCore.jl/blob/master/src/rule_definition_tools.jl#L290-L292
No, that's probably not the case. |
Have you made any other changes? I get:
And that is regardless of how many arguments I pass. Which I think makes sense, because it just treats the Vararg as if it was a normal argument (since it is not supported at present). |
Sorry, I think I made a few changes to the code at that point of time. |
follow up to #207
it would be useful to support varargs.
The text was updated successfully, but these errors were encountered: