Commit Graph

81 Commits (84afc944582e1ee518908169f815ce05ea4768cc)

Author SHA1 Message Date
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
alescontrela f4525b51e4 Change PriorFactor includes from gtsam/slam to gtsam/nonlinear 2020-04-10 22:26:22 -04:00
Frank Dellaert cd318b2295 Python example and necessary wrapper gymnastics 2020-03-18 17:36:42 -04:00
Jeremy Aguilon fe3741e466 Fix broken file 2019-03-07 14:25:05 -05:00
Jeremy Aguilon f4bf0d5b0b Update unstable.h file to match upstream 2019-03-07 14:23:11 -05:00
Jeremy 93fd884aa7 Implement and add example 2019-02-27 04:37:02 -05:00
Jeremy dbc0799765 Init uncomment of fixed lag smoother 2019-02-27 01:57:39 -05:00
Duy-Nguyen Ta 973b2337a2 make unstable build again 2017-08-15 11:16:13 -04:00
Duy-Nguyen Ta d18e638b08 cython wrap unstable 2017-03-18 15:52:08 -04:00
dellaert 233cabb3fb Made Velocity a Vector3 2015-07-17 17:36:29 -07:00
Frank Dellaert 3bad6fea67 moved RangeFactor to SAM 2015-07-12 12:12:59 -07:00
Frank Dellaert 7ff3e11efd removed redundancy in naming 2015-07-09 11:29:32 -07:00
dellaert 13dcc977f2 Moved Point2Vector wrapper from gtsam_unstable.h to gtsam.h 2015-05-03 17:31:08 -07:00
Paul Drews 8a88f101db Fix deprecation warnings 2015-02-24 21:58:17 -05:00
Mike Bosse e4936df80a matlab wrappers compile, but need testing 2014-11-07 22:41:21 +01:00
dellaert b5327673fb Get rid of LieVector 2014-11-03 11:02:15 +01:00
Vadim Indelman 6b890cec0e added updateNoiseModels functionality 2014-09-10 00:24:32 +03:00
Chris Beall 2634b2e890 Finish concurrent-calibration 2014-08-12 16:00:20 -04:00
Chris Beall 50c8313233 Rename TransformProjectionFactor to ProjectionFactorPPP 2014-08-12 15:55:28 -04:00
Chris Beall 2c3f6e563d Renamed TransformCalProjectionFactor to ProjectionFactorPPPC to follow new naming convention 2014-08-12 15:29:05 -04:00
Vadim Indelman 89410fe1ee added updateNoiseModels_givenCovs to BetweenFactorEM. 2014-08-01 21:11:19 +03:00
cbeall3 f261a6ddbc Merge remote-tracking branch 'origin/develop' into feature/concurrent-calibration 2014-07-02 15:49:47 -04:00
cbeall3 5b2f4a2c3a Move Transform factors to unstable 2014-07-01 16:03:35 -04:00
Vadim Indelman 991906181b Updating EM factor (to accout for uncertainty in states) 2014-06-30 20:43:25 +03:00
cbeall3 3bacdbbec5 Move Smart Projection Factor wrapper to stable 2014-06-20 13:41:51 -04:00
cbeall3 a34dff1397 Merge remote-tracking branch 'origin/feature/new_imu_factors' into develop 2014-06-20 13:32:34 -04:00
djensen3 b83a996731 Fixed SmartProjectionPoseFactor matlab wrapping 2014-05-13 17:04:16 -04:00
dellaert 0a2385711b MATLAB wrapping of TSAMFactors 2014-05-05 10:14:56 -04:00
djensen3 5402f9fa20 Removed smartProjectionPoseFactor from matlab wrapper; it was causing matlab crashes 2014-05-02 11:12:10 -04:00
djensen3 8dbd7c175c added SmartProjectionFactor to matlab wrapper 2014-05-01 15:55:37 -04:00
djensen3 ce13807d10 added script to run and save tests in a simplified way 2014-05-01 12:56:24 -04:00
Luca 32e1a8f994 tried some changes for wrapping 2014-05-01 10:48:54 -04:00
djensen3 2cb448fa24 adding SmartProjectionPoseFactor to wrapper 2014-04-30 16:17:32 -04:00
Luca e232b6085b wrapping smart factors 2014-04-15 11:06:38 -04:00
Luca f63db8859b addind wrapper for smart factors 2014-04-15 10:56:17 -04:00
vindelman3 381899640e Moved TransformBtwRobotsUnaryFactor to gtsam_unstable from svn version. 2014-02-04 14:13:25 -05:00
Chris Beall 5dc138aa09 wrap important bits of SmartRangeFactor 2013-09-13 21:00:48 +00:00
Vadim Indelman b3d500f58c Added optional flag_bump_up_near_zero_probs. 2013-08-29 22:43:09 +00:00
Vadim Indelman df36ee643a Added option to start with an M step. 2013-08-28 16:56:57 +00:00
Vadim Indelman 3b7670c5aa added TransformBtwRobotsUnaryFactorEM. 2013-08-23 15:24:46 +00:00
Richard Roberts 16b4f0fe8b Moved ImuFactor and CombinedImuFactor into main gtsam, and moved InertialNavFactor family into gtsam_unstable. 2013-08-13 21:04:31 +00:00
Richard Roberts 5d0f8399ed Fixed gtsam_unstable matlab wrapper 2013-08-12 22:26:37 +00:00
Richard Roberts 1eae17561d Taking ImuFactor noise model automatically from preintegrated measurement covariance 2013-08-09 18:50:14 +00:00
Vadim Indelman 27cabb62f1 added unwhitenedError to BetweenFactorEM. 2013-08-08 20:13:39 +00:00
Vadim Indelman 579e0931dc Fixed different issues with EM. 2013-08-08 15:12:21 +00:00
Vadim Indelman d33f435eab Added BetweenFactorEM with 2 indicator variables. 2013-08-07 15:25:00 +00:00
Richard Roberts 34dc67c1af Brought some relevant changes from aspn-imu-factor branch (is correct this time) 2013-08-02 16:04:17 +00:00
Alex Cunningham 424ef0728f Changed a filename to avoid having multiple object files of the same name in the library 2013-08-01 16:54:44 +00:00
Richard Roberts 321a286f02 Revert "Brought some relevant changes from aspn-imu-factor branch"
This reverts commit b08a11ffb27d14487115f20745f1cea17fcc55ee.
2013-07-31 15:26:48 +00:00
Richard Roberts 7345b40feb Brought some relevant changes from aspn-imu-factor branch 2013-07-31 15:25:03 +00:00