mirror of
https://github.com/ceres-solver/ceres-solver.git
synced 2026-08-29 16:40:38 +08:00
Add GradientProblemSolver::Options::parameter_tolerance.
Support for parameter tolerance was added to the line search minimizer was added a while ago, and calling Solve on a non-linear least squares problem supported it but for some reason the GradientProblemSolver::Options struct was missing this option even though the documentation suggested that it was present! Thanks to Noah Snavely for reporting this bug. Change-Id: I57cf4ab396bc822c19fa298529e113b89664a349
This commit is contained in:
@@ -74,6 +74,7 @@ class CERES_EXPORT GradientProblemSolver {
|
||||
max_solver_time_in_seconds = 1e9;
|
||||
function_tolerance = 1e-6;
|
||||
gradient_tolerance = 1e-10;
|
||||
parameter_tolerance = 1e-8;
|
||||
logging_type = PER_MINIMIZER_ITERATION;
|
||||
minimizer_progress_to_stdout = false;
|
||||
}
|
||||
@@ -236,6 +237,12 @@ class CERES_EXPORT GradientProblemSolver {
|
||||
// This value should typically be 1e-4 * function_tolerance.
|
||||
double gradient_tolerance;
|
||||
|
||||
// Minimizer terminates when
|
||||
//
|
||||
// |step|_2 <= parameter_tolerance * ( |x|_2 + parameter_tolerance)
|
||||
//
|
||||
double parameter_tolerance;
|
||||
|
||||
// Logging options ---------------------------------------------------------
|
||||
|
||||
LoggingType logging_type;
|
||||
|
||||
@@ -72,6 +72,7 @@ Solver::Options GradientProblemSolverOptionsToSolverOptions(
|
||||
COPY_OPTION(max_line_search_step_expansion);
|
||||
COPY_OPTION(max_num_iterations);
|
||||
COPY_OPTION(max_solver_time_in_seconds);
|
||||
COPY_OPTION(parameter_tolerance);
|
||||
COPY_OPTION(function_tolerance);
|
||||
COPY_OPTION(gradient_tolerance);
|
||||
COPY_OPTION(logging_type);
|
||||
|
||||
Reference in New Issue
Block a user