Add Solver::Options::IsValid.

This provides a user visible way to validate the Solver::Options
before calling Solve.

Change-Id: Ife84fd33532ab2ccb7ac95abe22735843db51fde
This commit is contained in:
Sameer Agarwal
2014-05-29 15:39:01 -07:00
parent 3b73313e2a
commit 1693645a67
8 changed files with 583 additions and 337 deletions
+6 -1
View File
@@ -1,5 +1,5 @@
// Ceres Solver - A fast non-linear least squares minimizer
// Copyright 2010, 2011, 2012 Google Inc. All rights reserved.
// Copyright 2014 Google Inc. All rights reserved.
// http://code.google.com/p/ceres-solver/
//
// Redistribution and use in source and binary forms, with or without
@@ -126,6 +126,11 @@ class CERES_EXPORT Solver {
update_state_every_iteration = false;
}
// Returns true if the options struct has a valid
// configuration. Returns false otherwise, and fills in *error
// with a message describing the problem.
bool IsValid(string* error) const;
// Minimizer options ----------------------------------------
// Ceres supports the two major families of optimization strategies -