ITS Path Planner ROS 2 Navigation Plugin#

Intelligent Sampling and Two-Way Search (ITS) global path planner is an Intel® patented algorithm.

ITS is a new search approach based on two-way path planning and intelligent sampling, which reduces the compute time by about 20x-30x on a 1000 nodes map comparing with the A* search algorithm. The inputs are the 2D occupancy grid map, the robot position, and the goal position.

The ITS Plugin for the ROS 2 Navigation 2 application plugin is a global path planner module that is based on Intelligent sampling and Two-way Search (ITS).

It does not support continuous replanning.

Prerequisites: Use a simple behavior tree with a compute path to pose and a follow path.

ITS planner inputs:

  • global 2D costmap (nav2_costmap_2d::Costmap2D)

  • start and goal pose (geometry_msgs::msg::PoseStamped)

ITS planner outputs: 2D waypoints of the path

Path planning steps summary:

  1. The ITS planner converts the 2D costmap to either a Probabilistic Road Map (PRM) or a Deterministic Road Map (DRM).

  2. The generated roadmap is saved as a txt file which can be reused for multiple inquiries.

  3. The ITS planner conducts a two-way search to find a path from the source to the destination. Either the smoothing filter or a catmull spline interpolation can be used to create a smooth and continuous path. The generated smooth path is in the form of a ROS 2 navigation message type (nav_msgs::msg).

For customization options, see ITS Path Planner Plugin Customization.

Run the ROS 2 Navigation Sample Application Using ITS Path Planner#

  1. Check if your installation has the eiforamr-full-flavour-sdk Docker* image.

    docker images |grep eiforamr-full-flavour-sdk
    #if you have it installed, the result is:
    eiforamr-full-flavour-sdk
    

    Note

    If the image is not installed, continuing with these steps triggers a build that takes longer than an hour (sometimes, a lot longer depending on the system resources and internet connection).

  2. If the image is not installed, Intel® recommends installing the Robot Complete Kit with the Get Started Guide for Robots.

  3. Check that EI for AMR environment is set:

    echo $AMR_TUTORIALS
    # should output the path to EI for AMR tutorials
    /home/user/edge_insights_for_amr/Edge_Insights_for_Autonomous_Mobile_Robots_2023.1/AMR_containers/01_docker_sdk_env/docker_compose/05_tutorials
    

    If nothing is output, refer to Get Started Guide for Robots Step 5 for information on how to configure the environment.

  4. Start the ROS 2 navigation sample application using the TurtleBot* 3 Gazebo* simulation in either default mode or Ackermann mode:

    # Default mode:
    docker compose -f $AMR_TUTORIALS/its_path_planner.tutorial.yml up
    
    # Ackermann mode:
    docker compose -f $AMR_TUTORIALS/its_ackermann_path_planner.tutorial.yml up
    

    Note

    The above command opens Gazebo* and rviz2 applications. Gazebo* takes a longer time to open (up to a minute) depending on the host’s capabilities. Both applications contain the simulated waffle map, and a simulated robot. Initially, the applications are opened in the background, but you can bring them into the foreground, side-by-side, for a better visual.

    1. Set the robot 2D Pose Estimate in rviz2:

      1. Set the initial robot pose by pressing 2D Pose Estimate in rviz2.

      2. At the robot estimated location, down-click inside the 2D map. For reference, use the robot pose as it appears in Gazebo*.

      3. Set the orientation by dragging forward from the down-click. This also enables ROS 2 navigation.

      ../_images/2d_pose_estimate.png
    2. In rviz2, press Navigation2 Goal, and choose a destination for the robot. This calls the behavioral tree navigator to go to that goal through an action server.

      ../_images/set_navigation_goal.png ../_images/path_created.png

      Expected result: The robot moves along the path generated to its new destination.

    3. Set new destinations for the robot, one at a time.

      ../_images/goal_achived_gazebo_rviz.png
    4. To close this, do the following:

      • Type Ctrl-c in the terminal where you did the up command.

      • Run this command to remove stopped containers:

      # Default mode:
      docker compose -f $AMR_TUTORIALS/its_path_planner.tutorial.yml down
      
      # Ackermann mode:
      docker compose -f $AMR_TUTORIALS/its_ackermann_path_planner.tutorial.yml down
      

Troubleshooting#

For general robot issues, go to Troubleshooting for Robot Tutorials.