-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix high latency, CPU, memory usage (#61)
* Moved expanded gripper into a service, and other changes to reduce lag * Filtered the pointcloud before deprojecting the point * Reduced nav cam FPS, add nav cam logs * Add a CycloneDDS config * Remove unnecessary realsense streams * Revert to running separate nodes per video stream * Move processing images out of callbacks, downsize pointclouds * create and revoke object URLs for images * Reduce num threads * Removed CycloneDDS config * Reenable realsense aligned depth to color * Removed unnecessary expanded gripper view code * only launch move_to_pregrasp node if Stretch has dex wrist 3 * updated image lock for beta gripper camera * updated color conversion for beta teleop gripper camera; removed unused import * Avoid base collision for horizontal grasp near floor * Abort click-to-pregrasp on collision * Undo effort-threshold based collision detection * Switch to /stretch/joint_states * Prevent markdown precommit from changing PR template * Filter pointcloud before downsampling, to prevent overflow with too small leaf sizes * Add a TODO to remove effort thresholding from web app --------- Co-authored-by: Vinitha Ranganeni <[email protected]>
- Loading branch information
1 parent
bda5a67
commit 0dce880
Showing
19 changed files
with
717 additions
and
321 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,44 +1,40 @@ | ||
from launch_ros.actions import Node | ||
|
||
from launch import LaunchDescription | ||
from launch.actions import DeclareLaunchArgument | ||
from launch.substitutions import LaunchConfiguration | ||
|
||
|
||
def generate_launch_description(): | ||
return LaunchDescription( | ||
[ | ||
Node( | ||
package="usb_cam", | ||
executable="usb_cam_node_exe", | ||
name="navigation_camera", | ||
output="screen", | ||
parameters=[ | ||
{"video_device": "/dev/hello-navigation-camera"}, | ||
{"image_width": 800}, | ||
{"image_height": 600}, | ||
{"framerate": 15.0}, | ||
{"pixel_format": "mjpeg2rgb"}, | ||
{"brightness": 10}, | ||
{"contrast": 30}, | ||
{"hue": 0}, | ||
{"saturation": 80}, | ||
{"sharpness": 3}, | ||
{"gamma": 80}, | ||
{"exposure_auto": True}, | ||
# {'exposure': 150}, | ||
{"white_balance_temperature_auto": True}, | ||
# {'white_balance': 4250}, | ||
{"gain": 10}, | ||
{"camera_frame_id": "navigation_camera"}, | ||
{"camera_name": "navigation_camera"}, | ||
{"io_method": "mmap"}, | ||
], | ||
remappings=[ | ||
("/image_raw", "/navigation_camera/image_raw"), | ||
# usb_cam does not publish compressed images: | ||
# https://github.com/ros-drivers/usb_cam/blob/52dd75fb78ae608a2c40eea60f6e8eac673b91e8/src/ros2/usb_cam_node.cpp#L50 | ||
# ("/image_raw/compressed", "/navigation_camera/image_raw/compressed") | ||
], | ||
), | ||
# You can add more nodes or configurations here if needed. | ||
] | ||
print_debug_arg = DeclareLaunchArgument( | ||
"print_debug", default_value="False", description="Print debug info" | ||
) | ||
camera_params = [ | ||
{ | ||
"camera_port": "/dev/hello-nav-head-camera", | ||
"publish_topic": "/navigation_camera/image_raw", | ||
"print_debug": LaunchConfiguration("print_debug"), | ||
# Properties | ||
"format": "MJPG", | ||
"size": [800, 600], | ||
"fps": 15, | ||
"brightness": 10, | ||
"contrast": 30, | ||
"saturation": 80, | ||
"hue": 0, | ||
"gamma": 80, | ||
"gain": 10, | ||
"white_balence_temp": 4600, | ||
"sharpness": 3, | ||
"backlight": 1, | ||
} | ||
] | ||
usb_cam = Node( | ||
package="stretch_core", | ||
executable="usb_cam", | ||
emulate_tty=True, | ||
output="screen", | ||
parameters=camera_params, | ||
name="navigation_camera", | ||
) | ||
return LaunchDescription([print_debug_arg, usb_cam]) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.