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

How do you properly instantiate VioManager? #489

Open
astro-friedel opened this issue Feb 24, 2025 · 0 comments
Open

How do you properly instantiate VioManager? #489

astro-friedel opened this issue Feb 24, 2025 · 0 comments

Comments

@astro-friedel
Copy link

I work with a fork of this repo at https://github.com/ILLIXR/open_vins. In our code we initialize an instance of VioManagerOptions which includes camera_intrinsics and camera_extrinsics set with proper values. The code then follows as:

  • We then feed this instance to the VioManager constructor, where it is copied (line 58 of ov_msckf/src/core/VioManager.cpp).
  • In the next line print_and_load_estimator is called with no parameters (the YamlParser defaulting to nullptr).
  • In line 117 of ov_msckf/src/core/VioManagerOptions.h print_and_load is called on the uninitialized init_options, which then calls print_and_load_state (line 58 of ov_init/src/init/InertialInitializerOptions.h).
  • In this function, starting at line 323 of ov_init/src/init/InertialInitializerOptions.h, init_options is populated.
  • But in this instance, there is not much done because the YamlParser is nullptr.
  • At line 323 of ov_init/src/init/InertialInitializerOptions.h an error is thrown because num_cameras (default initialized to 1, and there is nowhere in the code to change it) does not match the size of camera_intrinsics and camera_extrinsics (both of which have length 0 due to the nullptr.

So is it possible to initialize VioManager? From me reading, the YamlParser will always be nullptr, and the code will fail because num_cameras is never changed.

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

1 participant