commit | 83098e12e8b2252797a6570ba340c181eeddbd07 | [log] [tgz] |
---|---|---|
author | Sameer Agarwal <sameeragarwal@google.com> | Fri Mar 02 17:19:42 2018 -0800 |
committer | Sameer Agarwal <sameeragarwal@google.com> | Tue Mar 06 19:12:14 2018 +0000 |
tree | 4952ba9060a66505b1d2c7ce98a225d8d7c864f8 | |
parent | df2d882540872a399bb1841798b57d6afdc96e7a [diff] |
Two changes to how we manage user's state. 1. When Solver::Options::update_state_every_iteration = true, the StateUpdatingCallback only updates the state on a successful iteration. This works fine but will not work if the user provides an EvaluationCallback, because every call to Evaluator::Evaluate will change the state visible to the user. This means that on unsuccessful iterations when the user's IterationCallback is called the state visible to the user would be the last evaluation which did not lead to an improved cost. This CL forces the StateUpdatingCallback to unconditionally update the user visible state. 2. When the minimizer terminates, we update the user visible state only if the solution is usable, otherwise the user's state will remain the same. To maintain this invariant we will now cache the user's state and make sure we use it to reset it upon return if the solver is not successful. Change-Id: Ic1f8fa6cb10d2753130ea752c70ff3d6b2f1462f
Ceres Solver is an open source C++ library for modeling and solving large, complicated optimization problems. It is a feature rich, mature and performant library which has been used in production at Google since 2010. Ceres Solver can solve two kinds of problems.
Please see ceres-solver.org for more information.
Ceres development happens on Gerrit, including both repository hosting and code reviews. The GitHub Repository is a continuously updated mirror which is primarily meant for issue tracking. Please see our Contributing to Ceres Guide for more details.
The upstream Gerrit repository is
https://ceres-solver.googlesource.com/ceres-solver