How to manually update the params in a `Flux.Chain` neural network?

Optimizers like ADAM use a IdDict internally, so you shouldn’t create new parameters in each update. Just create them once and reuse them when updating.

1 Like