raulmur / ORB_SLAM2

Real-Time SLAM for Monocular, Stereo and RGB-D Cameras, with Loop Detection and Relocalization Capabilities
Other
9.37k stars 4.69k forks source link

SegFault on ORB_SLAM2::Frame::ComputeStereoFromRGBD #324

Open antoan opened 7 years ago

antoan commented 7 years ago

Ubuntu 14.04 x64 Ros-Indigo OpenCV 2.4 Processor: Intel(R) Core(TM) i7-2600K CPU @ 3.40GHz x64

A segfault is raised immediately after launching an RGBD ROS node with the folowing:

_rosrun ORB_SLAM2 RGBD /home/tony/dev/ORB_SLAM2/Vocabulary/ORBvoc.txt /home/tony/dev/ORB_SLAM2/Examples/RGB-D/TUM1.yaml /camera/depth_registered/image_raw:=/camera/depth/image_raw /camera/rgb/image_raw:=/camera/color/imageraw

The ORB-SLAM gui pops up momentarily during which it is possible to see a number of features tracked after which the application crashes.

The output looks like the following:

ORB-SLAM2 Copyright (C) 2014-2016 Raul Mur-Artal, University of Zaragoza. 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: RGB-D

Loading ORB Vocabulary. This could take a while... Vocabulary loaded!

Camera Parameters:

ORB Extractor Parameters:

Depth Threshold (Close/Far Points): 3.09294 New map created with 166 points

Program received signal SIGSEGV, Segmentation fault.


Attaching a gdb trace of a Debug build.

ORBSLAM2_SegFault_Trace_Debug.txt

WorldEditors commented 7 years ago

I find this code has serious problem in memory management. With "new" in multiple places but no "delete" when finished, I guess maybe it has something to do with your problem?