We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent aae08c4 commit a555a2cCopy full SHA for a555a2c
1 file changed
src/grad.jl
@@ -29,6 +29,7 @@ function grad(fdm, f, x::AbstractArray{T}) where T
29
end
30
31
grad(fdm, f, x::Real) = fdm(f, x)
32
+grad(fdm, f, x::Tuple) = grad(fdm, (xs...)->f(xs), x...)
33
34
function grad(fdm, f, xs...)
35
return ntuple(length(xs)) do k
0 commit comments