Skip to content
This repository has been archived by the owner on Sep 3, 2024. It is now read-only.

add buffer size to remove delay if run on jetson #5

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/detect.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,22 +80,22 @@ def __init__(self):

if self.compressed_input:
self.image_sub = rospy.Subscriber(
input_image_topic, CompressedImage, self.callback, queue_size=1
input_image_topic, CompressedImage, self.callback, queue_size=1, buff_size=2**24
)
else:
self.image_sub = rospy.Subscriber(
input_image_topic, Image, self.callback, queue_size=1
input_image_topic, Image, self.callback, queue_size=1, buff_size=2**24
)

# Initialize prediction publisher
self.pred_pub = rospy.Publisher(
rospy.get_param("~output_topic"), BoundingBoxes, queue_size=10
rospy.get_param("~output_topic"), BoundingBoxes, queue_size=1
)
# Initialize image publisher
self.publish_image = rospy.get_param("~publish_image")
if self.publish_image:
self.image_pub = rospy.Publisher(
rospy.get_param("~output_image_topic"), Image, queue_size=10
rospy.get_param("~output_image_topic"), Image, queue_size=1
)

# Initialize CV_Bridge
Expand Down