-
Notifications
You must be signed in to change notification settings - Fork 224
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RFC: more generic convergence assessment #530
Changes from 2 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -63,11 +63,13 @@ function default_convergence_assessment(state::AbstractOptimizerState, d, option | |
f_increased = true | ||
end | ||
|
||
if g_residual(gradient(d)) ≤ options.g_tol | ||
g_converged = true | ||
end | ||
|
||
g_converged = gradient_convergence_assessment(state,d,options) | ||
|
||
converged = x_converged || f_converged || g_converged | ||
|
||
return x_converged, f_converged, g_converged, converged, f_increased | ||
end | ||
|
||
gradient_convergence_assessment(state::AbstractOptimizerState, d, options) = g_residual(gradient(d)) ≤ options.g_tol | ||
gradient_convergence_assessment(state::ZerothOrderState, d, options) = false | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is this used anywhere? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes, in Jonathan's solver outside of Julia :) He wants to make some ZerothOrderSolver's outside of Optim but hook into everything else in Optim |
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this used anywhere?