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

Segmentation fault (Framebuffer with requested attributes not available.) #870

Open
hlin863 opened this issue Mar 22, 2024 · 4 comments
Open

Comments

@hlin863
Copy link

hlin863 commented Mar 22, 2024

When running the instruction on running the monotum program with configurations from the file "TUM${fr_code}.yaml", to produce visual estimations of the camera's pose and reconstruct the environment using a single camera:

./Install/bin/mono_tum TUM${fr_code}.yaml ${your_tum_dataset_folder} ${result_file_name}

I encountered a segmentation fault error as following:
ORB-SLAM2 Copyright (C) 2014-2016 Raul Mur-Artal, University of Zaragoza.
(modifications carried out at UCL, 2022)
This program comes with ABSOLUTELY NO WARRANTY;
This is free software, and you are welcome to redistribute it
under certain conditions. See LICENSE.txt.

Input sensor was set to: Monocular

Loading ORB Vocabulary. This could take a while...
Using the binary cache file
Vocabulary loaded in 0.08s

Camera Parameters:

  • fx: 517.306
  • fy: 516.469
  • cx: 318.643
  • cy: 255.314
  • k1: 0.262383
  • k2: -0.953104
  • k3: 1.16331
  • p1: -0.005358
  • p2: 0.002628
  • fps: 30
  • color order: RGB (ignored if grayscale)

ORB Extractor Parameters:

  • Number of Features: 1000
  • Scale Levels: 8
  • Scale Factor: 1.2
  • Initial Fast Threshold: 20
  • Minimum Fast Threshold: 7

Start processing sequence ...
Images in the sequence: 798

InitializerLogger
Initializer::~Initializer
Initializer::~Initializer
Initializer::~Initializer
Framebuffer with requested attributes not available. Using available framebuffer. You may see visual artifacts.New Map created with 84 points
Wrong initialization, reseting...
System Reseting
Segmentation fault

Which steps should I take to fix the segmentation error?

Thank you!

@mjunsen123
Copy link

try to run it with sudo

@hlin863
Copy link
Author

hlin863 commented Apr 10, 2024

./Install/bin/mono_tum TUM${fr_code}.yaml ${your_tum_dataset_folder} ${result_file_name}

When running sudo, the command is not found with the message "sudo: ./Install/bin/mono_tum: command not found" for the instruction "sudo ./Install/bin/mono_tum TUM123.yaml /path/to/your/tum/dataset/folder results.txt"

@hlin863
Copy link
Author

hlin863 commented Apr 11, 2024

try to run it with sudo

The same segmentation error occurs after running with "sudo".

@basedball
Copy link

basedball commented Apr 24, 2024

I believe the segfault is being caused by the map being reset in CreateMapMonocular() by:

  if (medianDepth < 0 || pKFcur->TrackedMapPoints(1) < 50) {
    Verbose::PrintMess("Wrong initialization, reseting...", Verbose::VERBOSITY_QUIET);
    RequestResetActiveMap();
    return;
  }

I've found that the system resets are very unstable, and I don't know entirely what caused this one to segfault.

The main issue in your case is that when SLAM functions properly, you should never be entering that if statement. Try to figure out which of the two conditions is true, and see if you can fix that.

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

3 participants