If anyone could help with the debug, I would really appreciate.
One thing that I know is if I comment line157 ~ 167.
The function gpuOrb.join() at line159 will ALWAYS be executed two times before the program terminate with the same error.
gpuOrb.join(descriptors_at_level);
If I change line 153 from
gpuOrb.launch_async(blurred_image, keypts_at_level.data(), keypts_at_level.size());
to
gpuOrb.launch_async(blurred_image, keypts.data(), keypts.size());
The above error disappeared. However, it could not track the feature (which is expected).
My opinion is that it is probably something about keypts and keypts_at_level that behave differently from ORB_SLAM2 code (I used the exact same code (?)). If any of you would like me to try any idea to debug, please let me know.
Your code looks correct to me. Some ideas for debugging:
Check if all keypoint coordinates (x,y) are valid, e.g. within matrix area (blurred_image) before calling gpuOrb.launch_async
Check if descriptors_at_level is large enough to receive data for all keypoints (compare both number of elements = sizes) before calling gpuOrb.join
There must be some copy&paste typo somewhere - difficult to find without adding some extra debugging code :-) If it is a memory error there must be some incorrect size for descriptors or incorrect pixel coordinate as input somewhere...
Hi all
I have been trying to make openVSLAM cuda enable following the work of yunchih and I have seen some discussion here #261.
I tried to put together the work of ORB_SLAM2 CUDA at my repro. It seems like the major change is only in orb_extractor.cc file.
However, when I ran the program, I got this error.
which I believe arise from this line.
If anyone could help with the debug, I would really appreciate.
One thing that I know is if I comment line157 ~ 167.
The function gpuOrb.join() at line159 will ALWAYS be executed two times before the program terminate with the same error.
gpuOrb.join(descriptors_at_level);
If I change line 153 from
gpuOrb.launch_async(blurred_image, keypts_at_level.data(), keypts_at_level.size());
togpuOrb.launch_async(blurred_image, keypts.data(), keypts.size());
The above error disappeared. However, it could not track the feature (which is expected).My opinion is that it is probably something about keypts and keypts_at_level that behave differently from ORB_SLAM2 code (I used the exact same code (?)). If any of you would like me to try any idea to debug, please let me know.
TIA