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

std::out_of_range of FixedLagSmoother methods #1935

Open
HeXu1 opened this issue Dec 16, 2024 · 2 comments
Open

std::out_of_range of FixedLagSmoother methods #1935

HeXu1 opened this issue Dec 16, 2024 · 2 comments

Comments

@HeXu1
Copy link

HeXu1 commented Dec 16, 2024

Hi,
I have test BatchFixedLagSmoother and IncrementalFixedLagSmoother method to fuse imu and lidar data with gtsam::CombinedImuFactor and addExpressionFactor factors.

I have built the latest gtsam from source they all have bug when they start fixedlagsmooth,
the BatchFixedLagSmoother method output is:
terminate called after throwing an instance of 'std::out_of_range'
what(): map::at

and the IncrementalFixedLagSmoother method output is:
terminate called after throwing an instance of 'std::out_of_range'
what(): invalid key

hope for your reply, thanks.

@HeXu1
Copy link
Author

HeXu1 commented Dec 16, 2024

and I don't know how to output debug information like #1092
[DEBUG] (2022-02-03 16:13:45.949) OptimizerGTSAM.cpp:101::optimize() Optimizing graph...
[DEBUG] (2022-02-03 16:13:45.949) OptimizerGTSAM.cpp:146::optimize() hasGPSPrior=false
[DEBUG] (2022-02-03 16:13:45.949) OptimizerGTSAM.cpp:164::optimize() fill poses to gtsam...

@RomanStadlhuber
Copy link

RomanStadlhuber commented Dec 17, 2024

I just want to chip in and say that I am experiencing the same issue.

Here is a minimal example to reprocude this problem.
While there are existing issues like #1092 where this problem seemingly occurs at random, I have consitently observed this problem to occur whenever I am adding timestamps that exceed the smoother lag.

While my example above was created by piecing together parts of the preintegration and FixedLagSmoother examples respectively, it might be worth mentioning that the FixedLagSmoother example constructs a minimal problem where factors are only added up to the lag time, leaving open the question if there is any further logic that needs to be called after the smoothers window is "full"?

Maybe the author of that example, @svwilliams knows more about that.

Kind regards.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants