Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gnc #617

Merged
merged 45 commits into from
Jan 4, 2021
Merged

Gnc #617

merged 45 commits into from
Jan 4, 2021

Conversation

lucacarlone
Copy link
Contributor

@lucacarlone lucacarlone commented Nov 28, 2020

Added Graduated Non-Convexity (GNC) as a nonlinear optimizer in GTSAM. This is an implementation of the GNC paper (https://arxiv.org/pdf/1909.08605.pdf), but it uses iterative solvers in the inner loop instead of non-minimal global solvers.

Outstanding tasks:

  • reintroduce “using BaseOptimizer = BaseOptimizerParameters::OptimizerType;” to let the user choose the iterative solver for the inner loop.
  • move GncOptimizer and its params to a proper class/file when ready.
  • populate the TLS option (now the code only implements GM = Geman McClure).
  • double-check that the 0.5 in front of the factors in gtsam does not require a modification to the weight update rule.

@lucacarlone lucacarlone added the wip This is still a work in progress label Nov 28, 2020
Copy link
Member

@dellaert dellaert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I left some comments. What is the main templating issue you wanted me to look at ?

tests/testGncOptimizer.cpp Outdated Show resolved Hide resolved
tests/testGncOptimizer.cpp Show resolved Hide resolved
tests/testGncOptimizer.cpp Outdated Show resolved Hide resolved
tests/testGncOptimizer.cpp Outdated Show resolved Hide resolved
@lucacarlone
Copy link
Contributor Author

@jingnanshi @dellaert @pantonante : I fixed the outstanding issue with optimizerType. I also added a couple of unit tests (and comments) to make sure the inlier threshold is set correctly. @jingnanshi : the only thing I'm not convinced about is the stopping condition for TLS - please check my comment. Besides that, this PR is ready for review!

lcarlone and others added 2 commits December 23, 2020 22:08
- handled degenerate case in mu initialization
- set TLS as default
- added more unit tests
Copy link
Member

@dellaert dellaert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome! First round, will look again after comments resolved :-)

gtsam/nonlinear/GaussNewtonOptimizer.h Outdated Show resolved Hide resolved
gtsam/nonlinear/LevenbergMarquardtParams.h Outdated Show resolved Hide resolved
tests/testGncOptimizer.cpp Show resolved Hide resolved
tests/testGncOptimizer.cpp Outdated Show resolved Hide resolved
gtsam/nonlinear/GncOptimizer.h Outdated Show resolved Hide resolved
gtsam/nonlinear/GncOptimizer.h Outdated Show resolved Hide resolved
gtsam/nonlinear/GncOptimizer.h Outdated Show resolved Hide resolved
gtsam/nonlinear/GncOptimizer.h Outdated Show resolved Hide resolved
gtsam/nonlinear/GncOptimizer.h Outdated Show resolved Hide resolved
gtsam/nonlinear/GncOptimizer.h Outdated Show resolved Hide resolved
Copy link
Member

@dellaert dellaert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very cool!
Just a few more code nits, feel free to merge after addressed ;-)

Now we need to apply it to Shonan and compare with robust rotation averaging, right @jingwuOUO :-) ?

gtsam/nonlinear/GncOptimizer.h Show resolved Hide resolved
gtsam/nonlinear/GncOptimizer.h Outdated Show resolved Hide resolved
gtsam/nonlinear/GncOptimizer.h Show resolved Hide resolved
gtsam/nonlinear/GncOptimizer.h Outdated Show resolved Hide resolved
gtsam/nonlinear/GncOptimizer.h Outdated Show resolved Hide resolved
gtsam/nonlinear/GncParams.h Show resolved Hide resolved
@lucacarlone
Copy link
Contributor Author

all set! I'll merge after @pantonante and @jingnanshi approve!

Copy link
Contributor

@jingnanshi jingnanshi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
wip This is still a work in progress
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants