Commit 6cfc017b authored by ChengQingshui's avatar ChengQingshui
parents b11afb2f 1e5f7c1d
......@@ -66,8 +66,8 @@ units:
outputNames: [tracked_instances]
frame_rate: 10
track_buffer: 30
track_thresh: 0.15
high_thresh: 0.2
track_thresh: 0.15 # threshold for high-confidence detections
high_thresh: 0.2 # threshold for new track creation
match_thresh: 0.6
init_frames: 2
out_lost_threshold: 0
......
......@@ -5,7 +5,7 @@
* @Date: 2023-09-03 02:18:07
* @email: xin.wang@waytous.com
* @LastEditors: yangxue xue.yang@waytous.com
* @LastEditTime: 2025-04-18 01:48:25
* @LastEditTime: 2025-06-12 08:21:08
*/
......@@ -56,7 +56,7 @@ sensorManager::sensorManager(ros::NodeHandle& nodehandle, ImageInferNodeParam& p
// 初始化订阅、发布话题
image_subscriber_ = nodehandle.subscribe<sensor_msgs::Image>(param.rgb_sub_topic_name, 1, boost::bind(&sensorManager::updateImage, this, _1));
pointcloud_subscriber_ = nodehandle.subscribe<sensor_msgs::PointCloud2>(param.pointcloud_sub_topic_name, 1, boost::bind(&sensorManager::updatePointcloud, this, _1));
obj_publisher_ = nodehandle.advertise<waytous_perception_msgs::ObjectTrackArray>(param.detection_pub_topic_name, 1);
obj_publisher_ = nodehandle.advertise<waytous_perception_msgs::ObjectArray>(param.detection_pub_topic_name, 1);
pub_thread_ = new boost::thread(boost::bind(&sensorManager::publishDetection, this));
};
......@@ -190,6 +190,7 @@ void sensorManager::publishDetection()
waytous_perception_msgs::ObjectTrackArray obTrackFrame;
obTrackFrame.header = frame_ptr->sensor_header;
obTrackFrame.header.frame_id = "vehicle_link";
obFrame.header = obTrackFrame.header;
// obTrackFrame.header.stamp = ros::Time(frame_ptr->timestamp_);
int8_t obj_id = 0;
......@@ -312,7 +313,7 @@ void sensorManager::publishDetection()
obFrame.foreground_objects.emplace_back(ob);
obTrackFrame.object_track.emplace_back(obTrack);
}
obj_publisher_.publish(obTrackFrame); // obFrame or obTrackFrame
obj_publisher_.publish(obFrame); // obFrame or obTrackFrame
std::cout<<" onRun : "<<double(clock()-start_)/CLOCKS_PER_SEC<<"s. "<< "Detected Objects: "
<< obFrame.foreground_objects.size() <<std::endl; //输出时间(单位:s)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment