Tutorial to Switch Mesh during Runtime#

Overview#

This tutorial walks you through the steps to switch the mesh for a different object for FoundationPose during runtime.

Tutorial Walkthrough#

  1. Complete the Isaac ROS FoundationPose Quickstart Guide.

  2. Keep FoundationPose running, and open a new terminal and activate the Isaac ROS environment:

    isaac-ros activate
    
  3. Run the following command to switch the mesh during runtime:

    ros2 param set /foundationpose mesh_file_path "<path_to_new_object_mesh>"
    
  4. (Optional) If you have multiple parameters associated with the mesh, you can create a YAML file with the parameters and run the following command to switch the mesh during runtime:

    ros2 param load /foundationpose "<path_to_new_mesh_parameters>"
    

    The following parameters associated with the mesh are supported to be switched during runtime:

    • mesh_file_path

    • symmetry_axes

    • symmetry_planes

    • fixed_translations

    • fixed_axis_angles

    • rot_normalizer

    • score_crop_ratio

Note

Runtime mesh switching is supported for both the pose estimation node and the tracking node. Setting the mesh_file_path parameter on the /foundationpose node updates the pose estimation mesh and automatically propagates the new mesh to the tracking node.