How to run the ZED camera in real time with RTAB-MAP?

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

How to run the ZED camera in real time with RTAB-MAP?

JasonWong
This post was updated on .
Sir:

    There are two questions I want to consult you.

    If I run the command "rtabmap" in the terminal of Ubuntu 16.04, the RTAB-MAP windows will be opened. With the operation of "Detection -> Select Source -> Stereo Camera -> ZED Camera -> Stereo USB Camera", we can select the input camera.

Q1:    
    I have created the Calibration of the ZED camera and load it into the RTAB-MAP, but the RTAB-MAP still warn that " CameraStereo.cpp:1379::init() Parameter "rectifyImages" is set, but no stereo model is loaded or valid."
    What should I do to solve this problem?

Q2:
    I want to know what other steps should be implemented if I want to run the ZED camera in real time with RTAB-MAP, in order to test the loop-closure of this algorithm outdoors.


    Looking forward to your replies! Best Wishes!

    Jason Wong
Reply | Threaded
Open this post in threaded view
|

Re: How to run the ZED camera in real time with RTAB-MAP?

matlabbe
Administrator
Hi,

Which rtabmap version do you use? Make sure the calibration file path is set. It can be either one of the generated calibration file or the prefix of the calibration file named "zed" here (if prefix is used, calibration should be saved in RTAB-Map/camera_info folder). Example:


Well, with metric SLAM disabled (loop closure detection only), we should be able to start the camera without calibration. This is a bug I just issued here.

cheers,
Mathieu
Reply | Threaded
Open this post in threaded view
|

Re: How to run the ZED camera in real time with RTAB-MAP?

JasonWong
This post was updated on .
I want to know whether we should fill the Stereo Camera Extrinsics (Transform between the cameras) when creating the camera calibration, even though I didn't fill in it, we still can save the calibration.





If I want to create the calibration(advanced:images should be rectified) with stereo mode, even though I fill in all the blanks, we still can not click the save button. Why is that?



Thank you again! Best Wishes!
Jason Wong
Reply | Threaded
Open this post in threaded view
|

Re: How to run the ZED camera in real time with RTAB-MAP?

matlabbe
Administrator
Hi,

I need to reverify why the save button is disabled, but you should do a full calibration with a checkboard to rectify images. Click on Calibrate button. The "Create Calibration" should be used only with datasets of stereo images in which they are already rectified.

cheers,
Mathieu
Reply | Threaded
Open this post in threaded view
|

Re: How to run the ZED camera in real time with RTAB-MAP?

matlabbe
Administrator
Hi,

In the second example you gave, make sure the minus "-" is adjacent to the number, and all numbers are separated by space.

cheers,
Mathieu
Reply | Threaded
Open this post in threaded view
|

Re: How to run the ZED camera in real time with RTAB-MAP?

JasonWong
In reply to this post by matlabbe
    The reason why I use the "Create Calibration" is that the built-in camera of my laptop, instead of the ZED USB camera, will be opened every time when I click the "Calibrate" button. Have you encountered this situation?

(The driver of the ZED camera has been installed correctly and I have used it with ORB-SLAM2 in real time.)


Best wishes!
JasonWong
Reply | Threaded
Open this post in threaded view
|

Re: How to run the ZED camera in real time with RTAB-MAP?

matlabbe
Administrator
Hi,

If you installed the ZED SDK, you can select the ZED SDK as the camera driver if rtabmap is built with ZED SDK (otherwise you cannot select ZED SDK driver), therefore no explicit calibration is required as the one of the ZED SDK is used directly. If you have a Windows computer, there are binaries available with ZED driver built-in. Not sure which version you are using, but if it is the ROS binaries version and you don't want to build rtabmap library from source, you could follow this tutorial under ZED instructions to feed rtabmap_ros with ZED images on ROS.

cheers,
Mathieu
Reply | Threaded
Open this post in threaded view
|

Re: How to run the ZED camera in real time with RTAB-MAP?

JasonWong
This post was updated on .
Hi

  I finally realize the function of running the ZED camera in real time with RTAB-MAP with your help. Thank you very much.



  At last, I have a proposal for the Stereo Hand-Held Mapping wiki.ros.org/rtabmap_ros/Tutorials/StereoHandHeldMapping.

  When we want to display the output of the ZED camera in RVIZ, the instruction of the website is
"roslaunch rtabmap_ros stereo_mapping.launch stereo_namespace:="/stereo_camera" rtabmap_args:="--delete_db_on_start" rviz:=true rtabmapviz:=false".

  But if we implement this order, the rviz can not subscribe necessary messages.



  I think we should implement the order of
"roslaunch rtabmap_ros stereo_mapping.launch stereo_namespace:="/camera" right_image_topic:=/camera/right/image_rect_color frame_id:=camera_link rtabmap_args:="--delete_db_on_start" rviz:=true rtabmapviz:=false" instead of the former, after implementing the two "tf" orders.

  Then we can see the output of RTABMAP with rviz


 


  Thank you again! Best Wishes!
  Jason Wong