diff --git a/src/optimise/train.jl b/src/optimise/train.jl index a3af8d66..c7899b08 100644 --- a/src/optimise/train.jl +++ b/src/optimise/train.jl @@ -37,9 +37,9 @@ function train!(loss, data, opt; cb = () -> ()) cb = try runall(cb) catch e - if e isa StopException || rethrow() + if e isa StopException || rethrow(e) @info "Stop Condition Met" - break + :stop opt = runall(opt) @progress for d in data l = loss(d...)