commit | 19ab2c1793c145f22e7017b570a036f8b3024758 | [log] [tgz] |
---|---|---|
author | Sameer Agarwal <sameeragarwal@google.com> | Wed Dec 21 16:01:36 2022 -0800 |
committer | Sameer Agarwal <sameeragarwal@google.com> | Fri Dec 23 06:45:28 2022 -0800 |
tree | 6ad762e8cd2a56514cc21c71b91ca7259d22d4b3 | |
parent | a3a062d72cc8c0f5f1f09b36d8b7c1ea3bef4d73 [diff] |
BlockRandomAccessMatrix Refactor 1. Add threading to all three subclasses of BlockRandomAccessMatrix. i.e. BlockRandomAccessDenseMatrix, BlockRandomAccessSparseMatrix and BlockRandomAccessDenseMatrix. For BlockRandomAccessDenseMatrix and BlockRandomAccessSparseMatrix this just means SetZero is parallelized. Which by itself is no big deal, but by doing so, the constructor for all three subclasses become uniform. BlockRandomAccessSparseMatrix::SymmetricRightMultiplyAndAccumulate maybe threaded in the future if needed. BlockRandomAccessDiagonalMatrix is the biggest beneficiary. SetZero Invert and RightMultiplyAndAccumulate are all threaded now. 2. Change the storage in BlockRandomAccessDiagonalMatrix from TripletSparseMatrix to CompressedRowSparseMatrix. This has no performance implications since we do not really use the capabilities of the underlying matrix indexing representation. This is a forward looking change when we decide to transfer this matrix to the GPU, a CompressedRowSparseMatrix will save on a data conversion. 3. Use std::unique_ptr as needed and eliminate the need for custom destructors. 4. Modify CompressedRowSparseMatrix::CreateBlockDiagonalMatrix to take a nullptr as the data vector. Fixes https://github.com/ceres-solver/ceres-solver/issues/936 Fixes https://github.com/ceres-solver/ceres-solver/issues/935 Change-Id: Ia6487f2d924fbe669835bdcc38abf2b451bda4ee
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.