update for arrays

This commit is contained in:
Mike J Innes 2019-04-05 17:17:50 +01:00
parent bde51aa5a6
commit 4c18f84ad3
1 changed files with 5 additions and 0 deletions

View File

@ -1,6 +1,11 @@
using Juno
import Zygote: Params, gradient
function update!(x::AbstractArray, )
x .+=
return x
end
function update!(opt, x, )
update!(x, -apply!(opt, x, ))
end