Isaac ROS NITROS Bridge#

https://media.githubusercontent.com/media/NVIDIA-ISAAC-ROS/.github/release-4.0/resources/isaac_ros_docs/repositories_and_packages/isaac_ros_nitros_bridge/isaac_ros_nitros_bridge_overview.png/

Overview#

The Isaac ROS NITROS Bridge provides NITROS-enabled performance enhancements for Isaac ROS packages by enabling efficient data transfer and conversion between different ROS message types.

Isaac ROS provides accelerated computing ROS packages for robotics development in ROS 2 with NITROS; this is enabled with the addition of type adaptation (REP-2007) and type negotiation (REP-2009) in ROS 2 Humble.

Isaac ROS NITROS Bridge improves performance by moving data from CPU to GPU to avoid CPU memory copies. This significantly improves performance across processes and enables the data in GPU memory to be used in place by accelerated computing.

https://media.githubusercontent.com/media/NVIDIA-ISAAC-ROS/.github/release-4.0/resources/isaac_ros_docs/repositories_and_packages/isaac_ros_nitros_bridge/isaac_ros_nitros_bridge.png/

The NITROS Bridge enables efficient data transfer and conversion between different ROS message types, moving data to GPU accelerated memory to avoid CPU memory copies. The NITROS converter adapts data in GPU memory for use with accelerated computing.

This principle can be applied to ROS 2, for example between different ROS 2 distributions to take advantage of Isaac ROS capabilities from applications developed in different versions without requiring full migration.

By avoiding unnecessary CPU memory copies, the Isaac ROS NITROS bridge improves accelerated computing performance and reduces end-to-end latency across different ROS message types.

Performance#

Isaac ROS NITROS Bridge provides efficient data transfer for NITROS-enabled packages, significantly improving performance compared to standard ROS message passing. See Isaac ROS Benchmark scripts for NITROS bridge performance measurement.

Packages#

Quickstart#

Set Up Development Environment#

  1. Set up your development environment by following the instructions in getting started.

Download Quickstart Assets#

  1. Download quickstart data from NGC:

    Make sure required libraries are installed.

    sudo apt-get install -y curl jq tar
    

    Then, run these commands to download the asset from NGC:

    NGC_ORG="nvidia"
    NGC_TEAM="isaac"
    PACKAGE_NAME="isaac_ros_nitros_bridge_ros2"
    NGC_RESOURCE="isaac_ros_nitros_bridge_ros2_assets"
    NGC_FILENAME="quickstart.tar.gz"
    MAJOR_VERSION=4
    MINOR_VERSION=0
    VERSION_REQ_URL="https://catalog.ngc.nvidia.com/api/resources/versions?orgName=$NGC_ORG&teamName=$NGC_TEAM&name=$NGC_RESOURCE&isPublic=true&pageNumber=0&pageSize=100&sortOrder=CREATED_DATE_DESC"
    AVAILABLE_VERSIONS=$(curl -s \
        -H "Accept: application/json" "$VERSION_REQ_URL")
    LATEST_VERSION_ID=$(echo $AVAILABLE_VERSIONS | jq -r "
        .recipeVersions[]
        | .versionId as \$v
        | \$v | select(test(\"^\\\\d+\\\\.\\\\d+\\\\.\\\\d+$\"))
        | split(\".\") | {major: .[0]|tonumber, minor: .[1]|tonumber, patch: .[2]|tonumber}
        | select(.major == $MAJOR_VERSION and .minor <= $MINOR_VERSION)
        | \$v
        " | sort -V | tail -n 1
    )
    if [ -z "$LATEST_VERSION_ID" ]; then
        echo "No corresponding version found for Isaac ROS $MAJOR_VERSION.$MINOR_VERSION"
        echo "Found versions:"
        echo $AVAILABLE_VERSIONS | jq -r '.recipeVersions[].versionId'
    else
        mkdir -p ${ISAAC_ROS_WS}/isaac_ros_assets && \
        FILE_REQ_URL="https://api.ngc.nvidia.com/v2/resources/$NGC_ORG/$NGC_TEAM/$NGC_RESOURCE/\
    versions/$LATEST_VERSION_ID/files/$NGC_FILENAME" && \
        curl -LO --request GET "${FILE_REQ_URL}" && \
        tar -xf ${NGC_FILENAME} -C ${ISAAC_ROS_WS}/isaac_ros_assets && \
        rm ${NGC_FILENAME}
    fi
    

Build isaac_ros_nitros_bridge_ros2#

  1. Set the ptrace_scope for NITROS Bridge:

    echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope
    
  1. Activate the Isaac ROS environment:

    isaac-ros activate
    
  2. Install the prebuilt Debian package:

    sudo apt-get update
    
    sudo apt-get install -y ros-jazzy-isaac-ros-nitros-bridge-ros2
    

Run Launch File#

  1. Run the following launch files to spin up a demo of this package:

    cd /workspaces/isaac_ros-dev && \
      source install/setup.bash && \
      ros2 launch isaac_ros_nitros_bridge_ros2 isaac_ros_nitros_bridge_quickstart.launch.py rosbag_path:=${ISAAC_ROS_WS}/isaac_ros_assets/isaac_ros_nitros_bridge_ros2/quickstart.bag
    
  2. Open a second terminal and activate the Isaac ROS environment:

    isaac-ros activate
    
  3. Visualize the output topic /r2b/ros2_output_image in RViz:

    cd /workspaces/isaac_ros-dev/ && \
      source install/setup.bash && \
      rviz2
    

Try Another Example#

For an example to run Isaac Sim with NITROS Bridge, see here.

Troubleshooting#

Isaac ROS NITROS Bridge ROS 2 Build Issues#

Symptoms#

You may encounter build issues when building ROS 2 packages.

Solution#

You must source setup.bash from the ROS 2 installation before building:

source /opt/ros/jazzy/setup.bash

Updates#

Date

Changes

2024-09-26

Update for Isaac ROS 3.1

2024-05-30

Update to be compatible with JetPack 6.0

2023-10-18

Initial release