Skip to content

Commit

Permalink
Isaac ROS 2.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
hemalshahNV committed Oct 19, 2023
1 parent d20a17a commit 71cc987
Show file tree
Hide file tree
Showing 170 changed files with 5,165 additions and 19,888 deletions.
322 changes: 40 additions & 282 deletions README.md

Large diffs are not rendered by default.

34 changes: 0 additions & 34 deletions docs/tutorial-ess-realsense.md

This file was deleted.

47 changes: 0 additions & 47 deletions docs/tutorial-isaac-sim.md

This file was deleted.

45 changes: 0 additions & 45 deletions docs/tutorial-nitros-graph.md

This file was deleted.

37 changes: 0 additions & 37 deletions docs/visualize-image.md

This file was deleted.

15 changes: 12 additions & 3 deletions isaac_ros_ess/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#
# SPDX-License-Identifier: Apache-2.0

cmake_minimum_required(VERSION 3.23.2)
cmake_minimum_required(VERSION 3.22.1)
project(isaac_ros_ess LANGUAGES C CXX)

if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
Expand All @@ -28,13 +28,15 @@ ament_auto_find_build_dependencies()
# isaac_ros_ess_node
ament_auto_add_library(isaac_ros_ess_node SHARED src/ess_disparity_node.cpp)
target_link_libraries(isaac_ros_ess_node)
rclcpp_components_register_nodes(isaac_ros_ess_node "nvidia::isaac_ros::dnn_stereo_disparity::ESSDisparityNode")
set(node_plugins "${node_plugins}nvidia::isaac_ros::dnn_stereo_disparity::ESSDisparityNode;$<TARGET_FILE:isaac_ros_ess_node>\n")
rclcpp_components_register_nodes(isaac_ros_ess_node "nvidia::isaac_ros::dnn_stereo_depth::ESSDisparityNode")
set(node_plugins "${node_plugins}nvidia::isaac_ros::dnn_stereo_depth::ESSDisparityNode;$<TARGET_FILE:isaac_ros_ess_node>\n")

### Install ESS extension built from source

add_subdirectory(gxf/ess)
install(TARGETS gxf_cvcore_ess DESTINATION share/${PROJECT_NAME}/gxf/lib/ess)
add_subdirectory(gxf/thresholder)
install(TARGETS gxf_thresholder DESTINATION share/${PROJECT_NAME}/gxf/lib/thresholder)

### End extensions

Expand All @@ -45,8 +47,15 @@ if(BUILD_TESTING)
find_package(ament_lint_auto REQUIRED)
ament_lint_auto_find_test_dependencies()


# The FindPythonInterp and FindPythonLibs modules are removed
if(POLICY CMP0148)
cmake_policy(SET CMP0148 OLD)
endif()

find_package(launch_testing_ament_cmake REQUIRED)
add_launch_test(test/isaac_ros_ess_test.py TIMEOUT "300")
add_launch_test(test/isaac_ros_ess_test_1_16HD_model.py TIMEOUT "300")
endif()

ament_auto_package(INSTALL_TO_SHARE launch config)
77 changes: 70 additions & 7 deletions isaac_ros_ess/config/ess_inference.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -129,14 +129,23 @@ components:
receiver: data_receiver_right
min_size: 1
- name: adapter
type: nvidia::cvcore::tensor_ops::ImageAdapter
type: nvidia::isaac::tensor_ops::ImageAdapter
parameters:
message_type: VideoBuffer
- name: data_transmitter
type: nvidia::gxf::DoubleBufferTransmitter
parameters:
capacity: 12
policy: 0
- name: confidence_output
type: nvidia::gxf::DoubleBufferTransmitter
parameters:
capacity: 12
policy: 0
- type: nvidia::gxf::DownstreamReceptiveSchedulingTerm
parameters:
transmitter: confidence_output
min_size: 1
- type: nvidia::gxf::DownstreamReceptiveSchedulingTerm
parameters:
transmitter: data_transmitter
Expand All @@ -147,27 +156,73 @@ components:
storage_type: 1
block_size: 18432000
num_blocks: 40
- type: nvidia::cvcore::ESS
- type: nvidia::isaac::ESSInference
parameters:
output_name: disparity
output_name: frame
pool: pool
left_image_receiver: data_receiver_left
right_image_receiver: data_receiver_right
output_transmitter: data_transmitter
confidence_transmitter: confidence_output
output_adapter: adapter
image_type: RGB_U8
pixel_mean: [-128, -128, -128]
normalization: [0.00392156862, 0.00392156862, 0.00392156862]
standard_deviation: [0.5, 0.5, 0.5]
max_batch_size: 1
input_layer_width: 960
input_layer_height: 576
model_input_type: RGB_U8
onnx_file_path: onnx_file_path_placeholder
engine_file_path: engine_file_path_placeholder
input_layers_name: [input_left, input_right]
output_layers_name: [output_left]
output_layers_name: [output_left, output_conf]
preprocess_type: RESIZE
---
name: disparity_thresholder
components:
- name: image_input
type: nvidia::gxf::DoubleBufferReceiver
parameters:
capacity: 12
policy: 0
- type: nvidia::gxf::MessageAvailableSchedulingTerm
parameters:
receiver: image_input
min_size: 1
- name: confidence_input
type: nvidia::gxf::DoubleBufferReceiver
parameters:
capacity: 12
policy: 0
- type: nvidia::gxf::MessageAvailableSchedulingTerm
parameters:
receiver: confidence_input
min_size: 1
- name: masked_output
type: nvidia::gxf::DoubleBufferTransmitter
parameters:
capacity: 12
policy: 0
- type: nvidia::gxf::DownstreamReceptiveSchedulingTerm
parameters:
transmitter: masked_output
min_size: 1
- name: allocator
type: nvidia::gxf::BlockMemoryPool
parameters:
storage_type: 1
block_size: 9216000
num_blocks: 40
- name: image_thresholder
type: nvidia::isaac::VideoBufferThresholder
parameters:
image_input: image_input
video_buffer_name: frame
mask_input: confidence_input
masked_output: masked_output
allocator: allocator
threshold: 0.9
fill_value_float: -1.0
---
name: disparity_compositor
components:
- name: disparity_in
Expand Down Expand Up @@ -212,7 +267,7 @@ components:
storage_type: 1
block_size: 18432000
num_blocks: 40
- type: nvidia::isaac_ros::DisparityCompositor
- type: nvidia::isaac::DisparityCompositor
parameters:
left_camera_model_receiver: left_cam_receiver
right_camera_model_receiver: right_cam_receiver
Expand Down Expand Up @@ -258,6 +313,14 @@ components:
- type: nvidia::gxf::Connection
parameters:
source: ess/data_transmitter
target: disparity_thresholder/image_input
- type: nvidia::gxf::Connection
parameters:
source: ess/confidence_output
target: disparity_thresholder/confidence_input
- type: nvidia::gxf::Connection
parameters:
source: disparity_thresholder/masked_output
target: disparity_compositor/disparity_in
- type: nvidia::gxf::Connection
parameters:
Expand Down
Loading

0 comments on commit 71cc987

Please sign in to comment.