Documentation & Logging cleanups.
1. Document the use of dogleg and a general discussion of
trust region methods.
2. Added a TBD section on compiler/linker flags.
3. Summary::FullReport now prints out sparse_linear_algebra_library
and trust_region_strategy_type.
Change-Id: I01f680070d510715900f345364855689005d54bb
diff --git a/internal/ceres/solver.cc b/internal/ceres/solver.cc
index 901e543..c61383c 100644
--- a/internal/ceres/solver.cc
+++ b/internal/ceres/solver.cc
@@ -89,7 +89,9 @@
linear_solver_type_given(SPARSE_NORMAL_CHOLESKY),
linear_solver_type_used(SPARSE_NORMAL_CHOLESKY),
preconditioner_type(IDENTITY),
- ordering_type(NATURAL) {
+ ordering_type(NATURAL),
+ trust_region_strategy_type(LEVENBERG_MARQUARDT),
+ sparse_linear_algebra_library(SUITE_SPARSE) {
}
string Solver::Summary::BriefReport() const {
@@ -179,10 +181,17 @@
internal::StringAppendF(&report, "Threads: % 25d% 25d\n",
num_threads_given, num_threads_used);
- internal::StringAppendF(&report, "Linear solver threads:% 23d% 25d\n",
+ internal::StringAppendF(&report, "Linear solver threads % 23d% 25d\n",
num_linear_solver_threads_given,
num_linear_solver_threads_used);
+ internal::StringAppendF(&report, "\nSparse Linear Algebra Library %15s\n",
+ SparseLinearAlgebraLibraryTypeToString(
+ sparse_linear_algebra_library));
+
+ internal::StringAppendF(&report, "Trust Region Strategy %19s\n",
+ TrustRegionStrategyTypeToString(
+ trust_region_strategy_type));
if (termination_type == DID_NOT_RUN) {
CHECK(!error.empty())
diff --git a/internal/ceres/solver_impl.cc b/internal/ceres/solver_impl.cc
index 41b6d75..877a5af 100644
--- a/internal/ceres/solver_impl.cc
+++ b/internal/ceres/solver_impl.cc
@@ -203,6 +203,9 @@
summary->num_residuals = problem_impl->NumResiduals();
summary->num_threads_used = options.num_threads;
+ summary->sparse_linear_algebra_library =
+ options.sparse_linear_algebra_library;
+ summary->trust_region_strategy_type = options.trust_region_strategy_type;
// Evaluate the initial cost and residual vector (if needed). The
// initial cost needs to be computed on the original unpreprocessed