Open Mirmix opened 6 years ago
I have the same issue. I'm on Ubuntu 16.04 with ROS's opencv 3. In fact I have this issue with both the master branch and @NH89's ROS-kinetic
branch from #7.
I did some digging. It seems the segfault occurs when interpolated_values_o
is deconstructed.
I also checked the execution of that function / loop with some printfs. It seems that code is executed maybe around 100times before the crash. Also, at the beginning, the code is executed in parallel in 2 threads (I have checked thread id), which doesn't make any sense to me. Maybe some funny business with OMP?
Hi all, I haven't had the time to touch this for a while. It did run on the set up that I had at the time. Since then OpenCV 3 has moved on from version 3.1 to 3.4. It is likely that there have been some changes in that time. It may also be that I did not discover every factor for crash free running.
From your descriptions I suspect that there is an issue with finding the correct libraries. If possible, makes sure that you have only one version of OpenCV and ROS. Then run all their tests to verify that all relevant components work. When you have ruled out any problem in your ROS and OpenCV installations, then build rgbdtam with debug flags, and run it with gdb (or your favourite debugger) and step through the code, until you find exactly which call is causing the crash. (I find the debug features in Kdevelop useful for this, other IDE's may have equivalent features.)
You would then need to check the class of function called against the API of the version of OpenCV that you have installed. This is how I discovered exactly what needed changing originally. Those changes were due to the restructuring of OpenCV in the major version change 2->3.
One alternate possibility is that you may need some environment variable set correctly in order for the correct components to be found. This may depend on what ROS catkin or other build files you have sourced.
I hope this helps. Best, Nick
I have met the same problem... Since it has been a long time, has anybody solved this problem?
Bump^ Has anyone solved this issue?
While running the code i am getting segmentation fault [core dumped] error. I tried to find the error using gdb .
It seems like that my error is at SemiDenseMapping.cpp:1756.
I suspect memory leak as error origin. So for solving the issue I also add this line to free the memory after using it.
But it also did not resolve the problem. After gdb I get the same error but the line was where I was releasing the memory. After surfing on the internet I also found similar problem . I applied their solution which was replacing the line with this :
But it did not also resolve the problem. Error or also may be caused by some kind of race condition. Or maybe heap is corrupted by releasing same memory space more than once.