Commit Graph

31 Commits (f18d8f15f4420b12c234310c114dca6a19a36182)

Author SHA1 Message Date
Varun Agrawal 9eff71ea8e Rot2::ClosestTo with SVD 2022-04-29 18:42:18 -04:00
Varun Agrawal 784bdc64c5 minor fixes to Pose2 and Rot2 2022-02-06 00:08:31 -05:00
John Lambert 68535708af
fix typo 2021-12-07 13:31:39 -07:00
John Lambert 37af8cfbec
finish Rot2.ClosestTo() 2021-12-07 11:59:28 -07:00
Jay Elrod 7c358aae4c Add user-defined copy constructor for Rot2 2021-06-29 17:07:15 -04:00
Frank Dellaert 84afc94458
Feature/shonan averaging (#473)
Shonan Rotation Averaging.

199 commit messages below, many are obsolete as design has changed quite a bit over time, especially from the earlier period where I thought we only needed SO(4).

* prototyping weighted sampler

* Moved WeightedSampler into its own header

* Random now uses std header <random>.

* Removed boost/random usage from linear and discrete directories

* Made into class

* Now using new WeightedSampler class

* Inlined random direction generation

* eradicated last vestiges of boost/random in gtsam_unstable

* Added 3D example g2o file

* Added Frobenius norm factors

* Shonan averaging algorithm, using SOn class

* Wrapping Frobenius and Shonan

* Fixed issues with <<

* Use Builder parameters

* Refactored Shonan interface

* Fixed << issues as well as MATLAB segfault, using eval(), as discussed in issue #451

* ShonanAveragingParameters

* New factor FrobeniusWormholeFactorP computes |Rj*P - Ri*P*Rij|

* Fixed broken GetDimension for Lie groups with variable dimension.

* Removed all but Shonan averaging factor and made everything work with new SOn

* Just a single WormholeFactor, wrapped noise model

* Use std <random>

* comments/todos

* added timing script

* add script to process ShonanAveraging timing results

* Now producing a CSV file

* Parse csv file and make combined plot

* Fixed range

* change p value and set two flags on

* input file path, all the csv files proceeses at the same time

* add check convergence rate part

* csv file have name according to input  data name

* correct one mistake in initialization

* generate the convergence rate for each p value

* add yticks for the bar plot

* add noises to the measurements

* test add noise

* Basic structure for checkOptimalityAt

* change optimizer method to cholesky

* buildQ now working. Tests should be better but visually inspected.

* multiple test with cholesky

* back

* computeLambda now works

* make combined plots while make bar plot

* Calculate minimum eigenvalue - the very expensive version

* Exposed computeMinEigenValue

* make plots and bar  togenter

* method change to jacobi

* add time for check optimality, min_eigen_value, sub_bound

* updated plot min_eigen value and subounds

* Adding Spectra headers

* David's min eigenvalue code inserted and made to compile.

* Made it work

* Made "run" method work.

* add rim.g2o name

* Fixed bug in shifting eigenvalues

* roundSolution which replaces projectFrom

* removed extra arguments

* Added to wrapper

* Add SOn to template lists

* roundSolution delete the extra arguement p

* only calculate p=5 and change to the correct way computing f_R

* Fixed conflict and made Google-style name changes

* prototype descent code and unit test for initializeWithDescent

* add averaging cost/time part in processing data

* initializewithDescent success in test

* Formatting and find example rather than hardcode

* Removed accidentally checked in cmake files

* give value to xi by block

* correct gradient descent

* correct xi

* }

* Fix wrapper

* Make Hat/Vee have alternating signs

* MakeATangentVector helpder function

* Fixed cmake files

* changed sign

* add line search

* unit test for line search

* test real data with line search

* correct comment

* Fix boost::uniform_real

* add save .dat file

* correct test case

* add explanation

* delete redundant cout

* add name to .dat output file

* correct checkR

* add get poses_  in shonan

* add Vector Point type for savig data

* Remove cmake file which magically re-appeared??

* Switched to std random library.

* Prepare Klaus test

* Add klaus3.g2o data.

* fix comment

* Fix derivatives

* Fixed broken GetDimension for Lie groups with variable dimension.

* Fix SOn tests to report correct dimension

* Added tests for Klaus3 data

* Add runWithRandomKlaus test for shonan.

* Finish runWithRandomKlaus unittest.

* Correct datafile.

* Correct the format.

* Added measured and keys methods

* Shonan works on Klaus data

* Create dense versions for wrappers, for testing

* Now store D, Q, and L

* Remove another cmake file incorrectly checked in.

* Found and fixed the bug in ComputeLambda !

* Now using Q in Lambdas calculation, so Lambdas agree with Eriksson18cvpr.

* Make FrobeniusFactor not use deprecated methods

* FrobeniusWormholeFactor takes Rot3 as argument

* Wrapped some more methods.

* Wrapped more methods

* Allow creating and populating BetweenFactorPose3s in python

* New constructors for ShonanAveraging

* add function of get measurements number

* Remove option not to use noise model

* wrap Use nrMeasurements

* Made Logmap a bit more tolerant of slightly degenerate rotations (with trace < -1)

* Allow for Anchor index

* Fix anchor bug

* Change outside view to Rot3 rather than SO3

* Add Lift in SOn class

* Make comet working

* Small fixes

* Delete extra function

* Add SOn::Lift

* Removed hardcoded flag

* Moved Frobenius factor to gtsam from unstable

* Added new tests and made an old regression pass again

* Cleaned up formatting and some comments, added EXPORT directives

* Throw exception if wrongly dimensioned values are given

* static_cast and other throw

* Fixed run-time dimension

* Added gauge-constraining factor

* LM parameters now passed in, added Gauge fixing

* 2D test scaffold

* Comments

* Pre-allocated generators

* Document API

* Add optional weight

* New prior weeights infrastructure

* Made d a template parameter

* Recursive Hat and RetractJacobian test

* Added Spectra 0.9.0 to 3rdparty

* Enabling 2D averaging

* Templatized Wormhole factor

* ignore xcode folder

* Fixed vec and VectorizedGenerators templates for fixed N!=3 or 4

* Simplifying constructors
Moved file loading to tests (for now)
All unit tests pass for d==3!

* Templated some methods internally

* Very generic parseToVector

* refactored load2d

* Very much improved FrobeniusWormholeFactor (Shonan) Jacobians

* SO(2) averaging works !

* Templated parse methods

* Switched to new Dataset paradigm

* Moved Shonan to gtsam

* Checked noise model is correctly gotten from file

* Fixed covariance bug

* Making Shonan wrapper work

* Renamed FrobeniusWormholeFactor to ShonanFactor and moved into its own compilation unit in gtsam/sfm

* Fixed wrong include

* Simplified interface (removed irrelevant random inits) and fixed eigenvector test

* Removed stray boost::none

* Added citation as suggested by Jose

* Made descent test deterministic

* Fixed some comments, commented out flaky test

Co-authored-by: Jing Wu <jingwu@gatech.edu>
Co-authored-by: jingwuOUO <wujing2951@gmail.com>
Co-authored-by: swang <swang736@gatech.edu>
Co-authored-by: ss <ss>
Co-authored-by: Fan Jiang <prof.fan@foxmail.com>
2020-08-17 07:43:10 -04:00
Varun Agrawal ff1f37c26f replaced fabs with c++11 std::abs 2019-09-18 18:30:26 -04:00
Duy-Nguyen Ta 1cdc228d6a remove trailing spaces 2019-02-11 10:58:34 -05:00
= ab1f6562c8 Fixes compile errors when using BOOST version 1.61.0 2016-08-06 00:59:07 -04:00
Alex Hagiopol e2a0110f3b Deprecated bool zero(). All unit tests pass. 2016-04-15 20:21:34 -04:00
dellaert f22c922600 The great Lie group heist: LieGroup CRTP class that defines both Manifold and Lie Group methods for a class, using AdjointMap as its main weapon. For the retract/localCoordinates, a ChartAtOrigin struct needs to be defined that can be switched at compile time (example Pose2). Rot3, Pose3 soon to follow. 2014-12-24 01:37:30 +01:00
dellaert c6ae119414 Tightened what is needed for Lie, i.e., fewer versions of retract/localCoordinates 2014-12-22 23:42:52 +01:00
dellaert 99a50a2f87 Split up concepts into Group/Manifold/Lie/VectorSpace. Also fixed some implementations and put in exceptions elsewhere, rather than CONCEPT_NOT_IMPLEMENTED macro. 2014-12-22 02:50:52 +01:00
nsrinivasan7 deff8b1e25 fixed the (*) to -> and code some more code beautification. 2014-12-03 11:27:18 -05:00
nsrinivasan7 bee32cc472 Rot2 done, make check works 2014-11-30 18:01:15 -05:00
nsrinivasan7 73564f1170 removed unecessary code 2014-11-30 17:07:26 -05:00
nsrinivasan7 c250f1d732 removed unecessary code 2014-11-30 17:06:03 -05:00
nsrinivasan7 ca9c66073f Rot2 rotate() and unrotate() changes to OptionalJacobians 2014-11-30 16:09:46 -05:00
nsrinivasan7 010631a2eb removed unecessary block oprations 2014-11-30 15:45:37 -05:00
nsrinivasan7 8457ef4182 make check works in this commit 2014-11-30 15:42:50 -05:00
nsrinivasan7 9137123f5f added OptionalJacobian to relativeBearing 2014-11-30 11:59:32 -05:00
nsrinivasan7 0ac6c8b80b Fixed the return value of Rot3 2014-11-30 08:32:35 -05:00
Richard Roberts aa093a35da Updated all comma initializer usages to use .finished() 2014-11-22 16:35:27 -08:00
Richard Roberts 880d9a8e3c Switched to new Eigen built-in special comma initializer 2013-12-16 21:33:12 +00:00
Jing Dong 763083d2db Fix Matrix_(...) to Mat() <<... in gtsam/base & gtsam/geometry 2013-11-13 04:50:42 +00:00
Chris Beall 4297d24c96 changed tabs to spaces for consistent indentation in all of GTSAM 2012-10-02 14:40:07 +00:00
Frank Dellaert 861071cc3b printing 2011-10-22 19:49:46 +00:00
Frank Dellaert 56d1d6ae34 Fixed some Doxygen problems with global replace 2011-10-14 03:23:14 +00:00
Richard Roberts 1a94808f57 Tightened thresholds in Rot3, Pose3, Rot2, Pose2, that were "correcting" numbers to zero and one with too loose tolerance. This made it necessary to specify large steps for numerical derivatives (1e-2 instead of the default 1e-5). Fixed this, and updated unit tests to use the default step size. 2011-04-08 18:41:50 +00:00
Richard Roberts 78b0fa054c Properly handling zero range in Pose2::bearing, Pose2::range, and Rot2::relativeBearing. Also debugging check for normalized matrix in Pose2::between 2011-02-04 03:32:27 +00:00
Richard Roberts 2c90e3d836 Moved the subdirectories that compile into libgtsam.la into a 'gtsam' subdirectory. Hopefully a good fix for the problem we had trying to make a gtsam distribution, that the source directory may not be called 'gtsam'. 2010-10-25 20:10:33 +00:00