commit | 310a252fb63b259c8a5730c1dfe4d387997a53e1 | [log] [tgz] |
---|---|---|
author | Sameer Agarwal <sameeragarwal@google.com> | Fri Aug 04 18:30:52 2023 -0700 |
committer | Sameer Agarwal <sameeragarwal@google.com> | Fri Aug 04 18:35:25 2023 -0700 |
tree | 1d11c843d71195b53a0e6d64802ca5e06cf58b43 | |
parent | 357482db701a85f101784a99159d063c5c3fa192 [diff] |
Deal with infinite initial cost correctly. Previously it could be the case that a residual block could return a residual whose squared norm overflows and generates an infinity which we did not detect. This would then lead to the trust region minimizer incorrectly terminating indicating convergence while generating a cost delta of NaN. This change adds a check for that and also does two minor cosmetic changes. 1. Reduce the level of nesting in program_evaluator.h by adding an early return. 2. The error message when IterationZero fails now says that the Initial residual and Jacobian failed, to indicate that the optimizer had no chance to do any work. Fixes https://github.com/ceres-solver/ceres-solver/issues/988 Thanks to @Ashray-g for reporting this. Change-Id: I52ae7627a66f637135209dbb2e42935b52c8bc77
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.