Skip to content

High CPU use when running multiple instances of ArgusMonoNode #42

@SyedShayaan

Description

@SyedShayaan

ISSUE:
I am running a 7 gmsl camera's using the argus mono camera node and I am getting high CPU usage .

SYSTEM:

  • Jetson AGX Orin Industrial
  • CPU(s): 8 core
  • RAM 30 gig

CAMERA:
LI-IMX568-GMSL2-105H

Furthermore, if I add isaac ros h264 encoder to the pipeline, my cpu utilization goes to 100% for all 8 cores, and in jtop I can see the NVENC toggle on and off.

JTOP before running 7 camera nodes:
image

JTOP after running 7 camera nodes:
image

Launch File:

import launch
from launch_ros.actions import ComposableNodeContainer
from launch_ros.descriptions import ComposableNode

def generate_launch_description():    
    # Define parameters for each camera module
    camera_modules = [
        {'camera_id': 6, 'module_id': 0, 'mode': 0, 'fsync_type': 1, 'camera_type': 0, 'camera_link_frame_name': 'camera_0', 'optical_frame_name': 'left_cam_0', 'camera_info_url': ''},
        {'camera_id': 2, 'module_id': 2, 'mode': 0, 'fsync_type': 1, 'camera_type': 0, 'camera_link_frame_name': 'camera_2', 'optical_frame_name': 'left_cam_2', 'camera_info_url': ''},
        {'camera_id': 3, 'module_id': 2, 'mode': 0, 'fsync_type': 1, 'camera_type': 0, 'camera_link_frame_name': 'camera_2', 'optical_frame_name': 'left_cam_2', 'camera_info_url': ''},
        {'camera_id': 0, 'module_id': 4, 'mode': 0, 'fsync_type': 1, 'camera_type': 0, 'camera_link_frame_name': 'camera_4', 'optical_frame_name': 'left_cam_4', 'camera_info_url': ''},
        {'camera_id': 1, 'module_id': 4, 'mode': 0, 'fsync_type': 1, 'camera_type': 0, 'camera_link_frame_name': 'camera_4', 'optical_frame_name': 'left_cam_4', 'camera_info_url': ''},
        {'camera_id': 4, 'module_id': 5, 'mode': 0, 'fsync_type': 1, 'camera_type': 0, 'camera_link_frame_name': 'camera_5', 'optical_frame_name': 'left_cam_5', 'camera_info_url': ''},
        {'camera_id': 5, 'module_id': 5, 'mode': 0, 'fsync_type': 1, 'camera_type': 0, 'camera_link_frame_name': 'camera_5', 'optical_frame_name': 'left_cam_5', 'camera_info_url': ''}
    ]

    # Define nodes for each camera module
    camera_nodes = []

    for idx, module in enumerate(camera_modules):
        camera_node = ComposableNode(
            name=f'argus_mono_{idx}',
            package='isaac_ros_argus_camera',
            plugin='nvidia::isaac_ros::argus::ArgusMonoNode',
            parameters=[module],
            remappings=[
                (f'left/image_raw', f'cam{module["camera_id"]}/image'),
                (f'left/camerainfo', f'cam{module["camera_id"]}/camerainfo')
            ]
        )
        camera_nodes.append(camera_node)

    # Create a container to hold all the nodes
    container = ComposableNodeContainer(
        name='argus_pipeline_container',
        namespace='',
        package='rclcpp_components',
        executable='component_container',
        composable_node_descriptions=camera_nodes,
        output='screen',
        arguments=['--ros-args', '--log-level', 'info']
    )

    return launch.LaunchDescription([container])

Metadata

Metadata

Assignees

No one assigned

    Labels

    verify to closeWaiting on confirm issue is resolved

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions