.FluxTraininginit!

function defined in module FluxTraining


			init!(callback, learner)

Initialize a callback. Default is to do nothing.

Extending

To extend for a callback, implement init!(cb::MyCallback, learner). init! can set up internal state of a callback that depends on learner and can also initialize shared callback state in learner.cbstate. Just like on event handlers, the state access permissions must be correctly defined using stateaccess to do so.

init! must also be idempotent, i.e. running it twice on the same Learner should have the same effect as runnning it once.