@@ -124,17 +124,14 @@ def __init__(self) -> None:
124124
125125 self .bridge = CvBridge ()
126126
127- self .pub = self .create_publisher (BoundingBoxes ,"yolox/bounding_boxes" , 10 )
128- # self.pub_image = self.create_publisher(Image,"yolox/image_raw", 10)
127+ self .pub = self .create_publisher (BoundingBoxes ,"bounding_boxes" , 10 )
129128
130129 if (self .sensor_qos_mode ):
131130 self .sub = self .create_subscription (Image ,"image_raw" ,self .imageflow_callback , qos_profile_sensor_data )
132131 else :
133132 self .sub = self .create_subscription (Image ,"image_raw" ,self .imageflow_callback , 10 )
134133
135134 def setting_yolox_exp (self ) -> None :
136- # set environment variables for distributed training
137- # ==============================================================
138135
139136 WEIGHTS_PATH = '../../weights/yolox_nano.pth'
140137
@@ -245,9 +242,6 @@ def imageflow_callback(self,msg:Image) -> None:
245242 bboxes_msg = self .yolox2bboxes_msgs (bboxes , scores , cls , cls_names , msg .header , img_rgb )
246243
247244 self .pub .publish (bboxes_msg )
248- # msg = self.bridge.cv2_to_imgmsg(img_rgb,"bgr8")
249- # msg.header.frame_id = "camera"
250- # self.pub_image.publish(msg)
251245
252246 if (self .imshow_isshow ):
253247 cv2 .imshow ("YOLOX" ,result_img_rgb )
0 commit comments