Commit Graph

104 Commits

Author SHA1 Message Date
Keir Mierle 406ac78167 Rework Ceres documentation as new website
This reworks the Ceres Sphinx documentation such that it can
function as the main Ceres website, now hosted at
ceres-solver.org. This also changes to the theme sphinx_rtd_theme
used by Read The Docs; this theme has strong mobile support and is
well enough designed.

Change-Id: I63232d985859a6dac94ff58f08bf81eb2b9e7f99
2014-04-07 15:28:21 +00:00
Sameer Agarwal 75e2232b29 Fix spacing in building.rst
Change-Id: I4c68d732c80d7ff2bdbc812bf0b7c7fb98c43957
2014-03-28 11:21:02 -07:00
Richard Bowen b555b489b8 Changes documentation to reflect changes in output format.
Change-Id: Ic0ba234283e791edcad29aec067905dcb2130813
2014-03-27 15:51:58 -07:00
Alex Stewart 195e49351b Check validity of residual block before removal in RemoveResidualBlock.
- Breaking change: Problem::Options::enable_fast_parameter_block_removal
  is now Problem::Options::enable_fast_removal, as it now controls
  the behaviour for both parameter and residual blocks.

- Previously we did not check that the specified residual block to
  remove in RemoveResidualBlock actually represented a valid residual
  for the problem.
- This meant that Ceres would die unexpectedly if the user passed an
  uninitialised residual_block, or more likely attempted to remove a
  residual block that had already been removed automatically after
  the user removed a parameter block upon on which it was dependent.
- RemoveResidualBlock now verifies the validity of the given
  residual_block to remove.  Either by checking against a hash set of
  all residuals maintained in ProblemImpl iff enable_fast_removal
  is enabled.  Or by a full scan of the residual blocks if not.

Change-Id: I9ab178e2f68a74135f0a8e20905b16405c77a62b
2014-03-26 17:49:36 +00:00
Sameer Agarwal 4f603fb0d8 Grammer fixes from William Rucklidge.
Change-Id: Ia40df7a1d141eb2552694510453d1431bb0c8dce
2014-03-19 17:16:43 -07:00
Sameer Agarwal efab1ab989 Rename tricks.rst to faq.rst.
Reorganize into sections and add some advice on
linear solvers.

Change-Id: Ia2d8665720c64b17da67f466f2fc154efb2b6c50
2014-03-14 15:03:15 -07:00
Sameer Agarwal ee21fac049 More tips and tricks.
1. Add a tip about glog.
2. Add a tip about using Summary::FullReport to optimize performance.
3. Add a tip about using the Inverse Function Theorem.

Change-Id: I949ec6843ff796672edbad8bc801230dd0ab5345
2014-03-13 17:48:00 -07:00
Sameer Agarwal 5f3f4007b9 Extend the advice on derivatives.
Extend the tips/tricks section to include more comprehensive
advice on derivatives.

Change-Id: Iba5768055b32a65e36d70e6f4db62eca9b331253
2014-03-11 16:11:51 -07:00
Sameer Agarwal 58b1e1b53d Add a tips/tricks/FAQ section to the documentation.
This is just a very bare bones beginning to this chapter.
But it opens the door to actually adding content to this
one tip/trick at a time.

Change-Id: I2aa386ba4da66dba5308e3f4ed4d434e44e44fd9
2014-03-11 12:15:09 -07:00
Sameer Agarwal 879fc2827a Remove CERES_NO_LINE_SEARCH_MINIMIZER.
Now that the trust region minimizer depends on the line search
minimizer, conditional compilation of the line search minimizer
will lead to build breakages, so this option is now not available.

It is not expected to have as significant impact on users as the
amount of code in the line search minimization algorithm is
rather small to begin with.

Change-Id: I2aa6b6e6e3931b6428dbda654f14faf1ac6dd130
2014-02-25 11:35:54 -08:00
Sameer Agarwal 9b83e49e54 Fix a small typo in solving.rst
Change-Id: Ib0b19d329a64230629b16e71437cdb53f10e551d
2014-02-25 11:33:18 -08:00
Sameer Agarwal 9bd23f29e8 Update documentation.
1. Reflect the demise of the various FOO_TOLERANCE convergence
types.

2. Update the documentation for Solver::Options::gradient_tolerance.

Change-Id: I6bd11d260d6f8a3222b6a41a62dc4943ec8fcfbf
2014-02-24 22:30:21 -08:00
Sameer Agarwal 85561eee95 Use int32 for parameter block sizes.
CostFunction now uses int32 instead of int16
to store the size of its parameter blocks.

This is an API breaking change.

Change-Id: I032ea583bc7ea4b3009be25d23a3be143749c73e
2014-01-07 22:22:14 -08:00
Sameer Agarwal dcee120bac Consolidate SolverTerminationType enum.
1. Rename SolverTerminationType to TerminationType.
2. Consolidate the enum as
  a. CONVERGENCE - subsumes FUNCTION_TOLERANCE, PARAMETER_TOLERANCE and GRADIENT_TOLERANCE
  b. NO_CONVERGENCE
  c. FAILURE - captures all kinds of failures including DID_NOT_RUN.
  d. USER_SUCCESS
  e. USER_FAILURE
3. Solver::Summary::error is renamed to be Solver::Summary::message, to both
reduce confusion as well as capture its true meaning.

Change-Id: I27a382e66e67f5a4750d0ee914d941f6b53c326d
2013-12-17 11:21:33 -08:00
Sameer Agarwal ed92366592 Lint cleanup from William Rucklidge.
Change-Id: I745810f5496a1b93263b20ff140f8883da61995e
2013-11-28 07:02:03 -08:00
Sameer Agarwal 6c0d96424e Minor documentation fix.
Thanks to Satya Mallick.

Change-Id: I556f1c141bf16739d54450351b0f29fd4ea40014
2013-11-20 11:52:01 -08:00
Sameer Agarwal 7747bb0e6b Minor corrections to the documentation.
Thanks to Satya Mallick for reporting these.

Change-Id: Ia52e08a7e21d5247dc475cfbf10bf57265aa118f
2013-11-20 11:31:10 -08:00
Sameer Agarwal 1a041c35b7 Update to 1.8.0.
Change-Id: Id42e594f03e3575d06e18c1ef66df64f43d86839
2013-11-12 14:19:25 -08:00
Sameer Agarwal 9ba0b352a2 Lint and other cleanups from William Rucklidge
Change-Id: I7fb23c2db85f0f121204560b79f1966f3d584431
2013-11-05 13:04:56 -08:00
Sameer Agarwal c71085ed32 Update to 1.8.0rc1.
Change-Id: Iaa10fd5a20be2ef84aca0119306c44669d87cc5d
2013-10-31 14:07:18 -07:00
Sameer Agarwal f06b9face5 Add support for multiple visibility clustering algorithms.
The original visibility based preconditioning paper and
implementation only used the canonical views algorithm.

This algorithm for large dense graphs can be particularly
expensive. As its worst case complexity is cubic in size
of the graph.

Further, for many uses the SCHUR_JACOBI preconditioner
was both effective enough while being cheap. It however
suffers from a fatal flaw. If the camera parameter blocks
are split between two or more parameter blocks, e.g,
extrinsics and intrinsics. The preconditioner because
it is block diagonal will not capture the interactions
between them.

Using CLUSTER_JACOBI or CLUSTER_TRIDIAGONAL will fix
this problem but as mentioned above this can be quite
expensive depending on the problem.

This change extends the visibility based preconditioner
to allow for multiple clustering algorithms. And adds
a simple thresholded single linkage clustering algorithm
which allows you to construct versions of CLUSTER_JACOBI
and CLUSTER_TRIDIAGONAL preconditioners that are cheap
to construct and are more effective than SCHUR_JACOBI.

Currently the constants controlling the threshold above
which edges are considered in the single linkage algorithm
are not exposed. This would be done in a future change.

Change-Id: I7ddc36790943f24b19c7f08b10694ae9a822f5c9
2013-10-31 13:22:57 -07:00
Sameer Agarwal 9e9a7d6ca0 Documentation update.
Add documentation for the new methods added to Problem.
Fix a bunch of ReST bugs.

Change-Id: I8a79a84040cfa8a679cc5355baccbe6d69bc9e70
2013-10-29 06:54:44 -07:00
Alex Stewart f51f56382c Documentation update.
- Adding documentation for MSVC CRT option.
- Updating documentation to reflect that LINE_SEARCH_MINIMIZER is now
  ON by default.

Change-Id: I75b1b5957c3ab46f38631736ad1c65315bc92847
2013-10-22 14:37:42 +01:00
Sameer Agarwal 74b5d61c13 Update documentation to refer to 1.7.0
Change-Id: I95f131f36ec1e86f9132e9bfc4341a524c603579
2013-10-22 06:10:20 -07:00
Sameer Agarwal 4ad80b7d96 Documentation update.
Update the documentation for Solver::Summary in
solver.h

Also minor typo fixes in solving.rst.

Change-Id: Id9363940ef843b7ce92013fdbb866168e0c5705f
2013-10-21 12:34:57 +00:00
Sameer Agarwal 7f336af614 Fix a minor documentation formatting bug
Change-Id: I2294e51d51e41a51c24630eeb49243e945faadfe
2013-10-17 23:38:57 -07:00
Alex Stewart 78cc2c4719 Cleaning up exported CeresConfig.cmake.
- Adding FindPackage scripts for all of Ceres dependencies.
- Moving depend.cmake contents to CeresConfig.cmake and cleaning up
  search for Ceres & required dependencies, no longer push Ceres
  options into client.
- Fixing uninstall to remove ceres include root directory.
- Fixing main CMakeLists to install miniglog header if enabled.
- Making miniglog library shared/static with Ceres library.

Change-Id: If926bebd11720230c5136597ccba672394ed9777
2013-10-17 19:13:08 +00:00
Sameer Agarwal 3654a79b8e Update documentation.
1. Update the documentation to be Sphinx friendly.

2. Remove dead fields in Solver::Summary.
   a. Solver::Summary::num_eliminate_blocks_given.
   b. Solver::Summary::num_eliminate_blocks_used.

Change-Id: I43e0070c88abe3bf285d91e6c7524f3d887deb33
2013-10-11 12:53:59 -07:00
Sameer Agarwal 7da85fb0e2 Documentation update
1. Make the documentation build with Sphinx 1.2
2. Update the documentation for IterationSummary to
   be Sphinx friendly.

Change-Id: I93c374987bc0597e854fbcb5a4a25dd2058607f5
2013-10-11 11:41:42 -07:00
Alex Stewart f5f21b5897 Adding check for broken version of Clang with Xcode 4.5.x.
- Also updating EXECUTE_PROCESS() calls to compiler to handle case
  when a compilation wrapper (e.g. ccache) is used.

Change-Id: I32837233a06ed1843125fb04852f82a9b8503769
2013-10-10 19:54:54 +01:00
Sameer Agarwal c7ebfb8e5e Documentation update
Change-Id: I10c6c8375f27c7fa4cd1c381b4f39d784fa946e1
2013-10-09 22:13:01 -07:00
Sameer Agarwal 8ba41e8b45 Lint cleanup from William Rucklidge
Change-Id: Ib2ea43203ac06551162ab306d7dece504e4f07aa
2013-10-09 11:35:40 -07:00
Alex Stewart fc8ede2d5e Making LAPACK a CMake option and updating build docs.
Change-Id: Iffd11866aa04a26b70cc788f992276e96c06eb6d
2013-10-08 23:48:58 +01:00
Alex Stewart 0b07d3e9f9 Making all config options in CMake & SuiteSparse cleanup.
- Also marking all library and include directories found via
  find_library/path advanced (not directly visible in CMake GUI unless
  toggled to show advanced options).
- Updating documentation to reflect SuiteSparse requirements on Ubuntu
  and ability to control build options in CMake GUI.
- Splitting out all SuiteSparse related find_XX directives into a
  FindSuiteSparse script.

Change-Id: I0d69e02392ec547a7c365ba3e06f2ebc61cacf16
2013-10-07 19:50:24 +01:00
Sameer Agarwal 10ac7d8048 Lint cleanup and a bug fix.
Thanks to William Rucklidge.

Change-Id: I963656be661020abacbff792cfc3025623503db8
2013-10-03 14:37:07 -07:00
Sameer Agarwal 3a2158d728 NumericDiffCostFunction supports dynamic number of residuals.
1. Update AutoDiffCostFunction template parameters to be consistent
with NumericDiffCostFunction.

2. Update the documentation for NumericDiffCostFunction and
AutoDiffCostFunction.

Change-Id: I113038abb5bedebb0f6f326f2a4ac31480d785fc
2013-10-03 20:09:59 +00:00
Sameer Agarwal 4d2df0cf34 Add IterationSummary::gradient_norm.
Iteration summary now reports the 2-norm of the gradient also.

Change-Id: I1ed7f1456ee4f546c9b42423d7a4ec3079ec078f
2013-09-13 12:54:03 -07:00
Keir Mierle 682cd3c278 Update version history with shared libs changes
Change-Id: Iafd55087bc5eef4c15c3b544222147aa99df7690
2013-09-03 14:28:32 -07:00
Keir Mierle 340d7c1415 Update version history with miniglog fix
Change-Id: Ic69f4994259e05fa88548b957146a1aac73b7af7
2013-09-03 13:50:03 -07:00
Sameer Agarwal 0338f9a8e6 ITERATIVE_SCHUR works with no f-blocks.
When the Schur complement is of size zero,
i.e. none of the parameter blocks interact
with each other, the ITERATIVE_SCHUR linear
solver crashes due to some checks that are
triggered in the SCHUR_JACOBI preconditioner.

This patch adds logic to detect this condition
and to deal with it and adds tests that verify
the fix.

Thanks to Soohyun Bae for reporting this bug.

Change-Id: If29ddf32463cbb1960414fff0e29bbf0d2ee7989
2013-09-02 22:41:59 -07:00
Sameer Agarwal c24a4ec6fb Cmake refactoring
1. Use CMake FindLAPACK and FindBLAS Modules.
2. Remove SEARCH_HEADERS and SEARCH_LIBS and replace them with
CMAKE variables. This leads to simplification of the FIND_LIBRARY
and FIND_PATH calls.
3. Make miniglog a fallback when glog is not present and the
user indicates MINIGLOG=OFF.
4. Add time.h to miniglog.
5. Remove shared library building.

Change-Id: I8a97156d3d7cf645fbbfe8e571761bc16c89f43f
2013-08-25 23:56:48 -07:00
Sameer Agarwal 3e6ef29be6 Update version history to reflect API changes
Change-Id: I5ce744d72b991abba17b5cf9c6a1e1f158693151
2013-08-20 09:57:03 -07:00
Sameer Agarwal 8f33332c59 Documentation update for 1.7.0rc2
Change-Id: I6b0c19bed57b51a0f6591c60a4ae0d849c62451b
2013-08-18 23:32:50 -07:00
Sameer Agarwal d61b68aaac Lint cleanups from William Rucklidge
Change-Id: Ia4756ef97e65837d55838ee0b30806a234565bfd
2013-08-16 17:02:56 -07:00
Sameer Agarwal 367b65e17a Multiple dense linear algebra backends.
1. When a LAPACK implementation is present, then
DENSE_QR, DENSE_NORMAL_CHOLESKY and DENSE_SCHUR
can use it for doing dense linear algebra operations.

2. The user can switch dense linear algebra libraries
by setting Solver::Options::dense_linear_algebra_library_type.

3. Solver::Options::sparse_linear_algebra_library is now
Solver::Options::sparse_linear_algebra_library_type to be consistent
with all the other enums in Solver::Options.

4. Updated documentation as well as Solver::Summary::FullReport
to reflect these changes.

Change-Id: I5ab930bc15e90906b648bc399b551e6bd5d6498f
2013-08-13 14:57:03 -07:00
Sameer Agarwal c5bcfc01af Lint fixes from Jim Roseborough.
Change-Id: If93e1972041b36410225a509e3c8c7c818f92124
2013-07-19 15:50:27 -07:00
Sameer Agarwal 16924168ce Update version from 1.6.0 -> 1.7.0rc1.
Change-Id: I420a8907142bffad0e3aa6c7196541ca2309c099
2013-07-18 13:35:01 -07:00
Sameer Agarwal 42be9cafe6 Update documentation for Covariance
Change-Id: Ia4a7347ef8267b7107698d85fcbfc986111958dc
2013-07-18 08:02:08 -07:00
Alex Stewart 9aa0e3cf72 Adding Wolfe line search algorithm and full BFGS search direction options.
Change-Id: I9d3fb117805bdfa5bc33613368f45ae8f10e0d79
2013-07-17 08:14:20 +00:00
Sameer Agarwal 0a07fbf873 Use ATLAS as the example BLAS in building.rst
OpenBLAS has subtle issues releated to threading. It
conflicts with the use of threads in the other parts of
the application.

Careful users can still use it by disabling threads via
an environment variable, but by default we want to use
a BLAS/LAPACK that does not suffer from these problems.

Change-Id: I8c1c0ed0b526453564c5f9ea69b646fac32fe027
2013-07-10 17:02:18 -07:00