Get Started Guide

  • 2021.3
  • 10/21/2021
  • Public Content

Launch Wandering Application with Intel® RealSense™ Camera

The application consists of two ROS nodes, developed by Intel. In order to function properly, those two nodes depend on other ROS nodes/packages: RealSense ROS wrapper, Nav2 ROS package, RTAB_MAP and its ROS Wrapper, and robot drivers.
Wandering ROS nodes are:
  • Wandering: gets updates from nav2 via costmap and issues navigation goals back to nav2 node
  • Object Detection: gets color and depth images from RealSense camera ROS wrapper, performs object detection and publishes coordinates of detected objects
The following diagram shows the internal architecture of the Wandering application and its ROS node dependencies.

Run the Sample Application

  1. Connect the Intel® RealSense™ camera (for example, D435i) to the host.
  2. Go to the
    AMR_containers
    folder:
    cd <edge_insights_for_amr_path>/Edge_Insights_for_Autonomous_Mobile_Robots_<version>/AMR_containers
  3. Run the command below to start the Docker container:
    ./run_interactive_docker.sh amr-ubuntu2004-full-flavour-sdk:<TAG> eiforamr
  4. Within the Docker container, run the commands:
    source /opt/ros/foxy/setup.bash source /home/eiforamr/ros2_ws/install/setup.bash source /opt/intel/openvino_2021.2.200/bin/setupvars.sh source /home/eiforamr/workspace/Wandering/src/prebuilt_wandering/setup.bash
  5. Run the Wandering application:
    ros2 launch wandering_app standalone_wander.launch.py
    Expected output:
    [INFO ] [launch]: All log files can be found below /root/.ros/log/2021-05-17-12-11-29-103678-glaic3n125-4218 [INFO] [launch]: Default logging verbosity is set to INFO /opt/ros2_ws/install/rtabmap_ros/share/rtabmap_ros/launch/realsense_d400.launch.py:29: UserWarning: The parameter 'node_executable' is deprecated, use 'executable' instead Node( /opt/ros2_ws/install/rtabmap_ros/share/rtabmap_ros/launch/realsense_d400.launch.py:34: UserWarning: The parameter 'node_executable' is deprecated, use 'executable' instead Node( [INFO] [realsense2_camera_node-2]: process started with pid [4222] [INFO] [static_transform_publisher-1]: process started with pid [4220] [INFO] [object_detection_ssd-3]: process started with pid [4224] [INFO] [rgbd_odometry-4]: process started with pid [4226] [INFO] [rtabmap-5]: process started with pid [4228] [INFO] [main-6]: process started with pid [4230] [...] [object_detection_ssd-3] detection_out EXECUTED layerType: DetectionOutput realTime: 94 cpu: 94 execType: unknown_FP32 [object_detection_ssd-3] out_detection_out NOT_RUN layerType: Output realTime: 0 cpu: 0 execType: unknown_FP32 [object_detection_ssd-3] Total time: 9119 microseconds [object_detection_ssd-3] [object_detection_ssd-3] Full device name: Intel® Core™ i7-9750H CPU @ 2.60GHz [object_detection_ssd-3]
  6. Open a new foxy container instance in the new shell:
    # Above cmd will give you container_id docker ps # In new-shell use the container_id to attach to the running container: docker exec -it <container_id> /bin/bash
  7. Within the Docker container, run:
    source /opt/ros/foxy/setup.bash
  8. Start rviz2:
    rviz2
  9. The occupancy grid map is displayed in rviz2, generated by RTAB_MAP while running the Wandering application.
    Be sure to add in rviz2 the
    Map
    (from Map) and
    Image
    (from color/image_raw) using the
    Add
    button and
    By Topic
    tab.

Troubleshooting

If the following error is encountered:
$ ./run_interactive_docker.sh amr-ubuntu2004-full-flasvour-sdk:<TAG> eiforamr bash: ./run_interactive_docker.sh Permission denied
Give executable permission to the script:
$ chmod 755 run_interactive_docker.sh

Known Limitation

The RTAB_MAP SLAM issues warnings when odometry gets lost due to fast camera movement. This a known limitation because RTAB_MAP is not best suitable for indoor navigation.
[wandering-6] [INFO] [1631637948.399030161] [wandering_mapper]: Waiting for the map [rgbd_odometry-4] [INFO] [1631637948.991880715] [rgbd_odometry]: Odom: quality=0, std dev=0.000000m|0.000000rad, update time=0.034602s [rtabmap-5] [INFO] [1631637949.243822073] [rtabmap]: rtabmap (5): Rate=1.00s, Limit=0.000s, RTAB-Map=0.0532s, Maps update=0.0001s pub=0.0000s (local map=1, WM=1) [rtabmap-5] [INFO] [1631637949.245836009] [rtabmap]: rtabmap: Updating parameters [rtabmap-5] [INFO] [1631637949.245899034] [rtabmap]: RTAB-Map rate detection = 1.000000 Hz [wandering-6] [INFO] [1631637949.399204956] [wandering_mapper]: Waiting for the map [rgbd_odometry-4] [INFO] [1631637949.403913170] [rgbd_odometry]: Odom: quality=0, std dev=0.000000m|0.000000rad, update time=0.027971s [wandering-6] Warning: TF_OLD_DATA ignoring data from the past for frame odom at time 1621339703.244709 according to authority Authority undetectable [wandering-6] Possible reasons are listed at http://wiki.ros.org/tf/Errors%20explained [wandering-6] at line 332 in /tmp/binarydeb/ros-foxy-tf2-0.13.10/src/buffer_core.cpp [rgbd_odometry-4] [ WARN] (2021-09-14 16:45:45.701) OdometryF2M.cpp:525::computeTransform() Registration failed: "Not enough inliers 0/20 (matches=5) between -1 and 27" [rgbd_odometry-4] [ WARN] (2021-09-14 16:45:45.775) OdometryF2M.cpp:525::computeTransform() Registration failed: "Not enough inliers 0/20 (matches=11) between -1 and 28" [rgbd_odometry-4] [ WARN] (2021-09-14 16:45:45.965) OdometryF2M.cpp:525::computeTransform() Registration failed: "Not enough inliers 0/20 (matches=6) between -1 and 29" [rgbd_odometry-4] [ WARN] (2021-09-14 16:45:46.005) OdometryF2M.cpp:525::computeTransform() Registration failed: "Not enough inliers 0/20 (matches=5) between -1 and 30" [rgbd_odometry-4] [ WARN] (2021-09-14 16:45:46.068) OdometryF2M.cpp:525::computeTransform() Registration failed: "Not enough inliers 0/20 (matches=9) between -1 and 31" [rgbd_odometry-4] [ WARN] (2021-09-14 16:45:46.131) OdometryF2M.cpp:525::computeTransform() Registration failed: "Not enough inliers 0/20 (matches=5) between -1 and 32" [rgbd_odometry-4] [ WARN] (2021-09-14 16:45:46.370) OdometryF2M.cpp:525::computeTransform() Registration failed: "Not enough inliers 0/20 (matches=6) between -1 and 33" [rgbd_odometry-4] [ WARN] (2021-09-14 16:45:46.416) OdometryF2M.cpp:525::computeTransform() Registration failed: "Not enough inliers 0/20 (matches=5) between -1 and 34" [rgbd_odometry-4] [ WARN] (2021-09-14 16:45:46.537) OdometryF2M.cpp:525::computeTransform() Registration failed: "Not enough inliers 0/20 (matches=8) between -1 and 35" [rgbd_odometry-4] [ WARN] (2021-09-14 16:45:46.624) OdometryF2M.cpp:525::computeTransform() Registration failed: "Not enough inliers 0/20 (matches=6) between -1 and 36" [rgbd_odometry-4] [ WARN] (2021-09-14 16:45:47.039) OdometryF2M.cpp:525::computeTransform() Registration failed: "Not enough inliers 0/20 (matches=5) between -1 and 37" [rgbd_odometry-4] [ WARN] (2021-09-14 16:45:47.231) OdometryF2M.cpp:525::computeTransform() Registration failed: "Not enough inliers 0/20 (matches=11) between -1 and 38" [rgbd_odometry-4] [ WARN] (2021-09-14 16:45:48.991) OdometryF2M.cpp:525::computeTransform() Registration failed: "Not enough inliers 0/20 (matches=10) between -1 and 39" [rgbd_odometry-4] [ WARN] (2021-09-14 16:45:49.403) OdometryF2M.cpp:525::computeTransform() Registration failed: "Not enough inliers 0/20 (matches=10) between -1 and 40" [rgbd_odometry-4] Warning: TF_OLD_DATA ignoring data from the past for frame odom at time 1621339703.244709 according to authority Authority undetectable [rgbd_odometry-4] Possible reasons are listed at http://wiki.ros.org/tf/Errors%20explained [rgbd_odometry-4] at line 332 in /tmp/binarydeb/ros-foxy-tf2-0.13.10/src/buffer_core.cpp

Summary and Next Steps

In this tutorial, you learned how to launch the Wandering application with Intel® RealSense™ camera.

Product and Performance Information

1

Performance varies by use, configuration and other factors. Learn more at www.Intel.com/PerformanceIndex.