From 49b95aeeaa28b92728f37b25fbf55da69cad47c4 Mon Sep 17 00:00:00 2001 From: dan-du-car Date: Tue, 27 Aug 2024 14:33:03 -0400 Subject: [PATCH] update --- src/v2i-hub/MUSTSensorDriverPlugin/src/MUSTSensorDetection.cpp | 2 +- src/v2i-hub/MUSTSensorDriverPlugin/src/MUSTSensorDetection.h | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/v2i-hub/MUSTSensorDriverPlugin/src/MUSTSensorDetection.cpp b/src/v2i-hub/MUSTSensorDriverPlugin/src/MUSTSensorDetection.cpp index 906c24089..0256bb93a 100644 --- a/src/v2i-hub/MUSTSensorDriverPlugin/src/MUSTSensorDetection.cpp +++ b/src/v2i-hub/MUSTSensorDriverPlugin/src/MUSTSensorDetection.cpp @@ -34,7 +34,7 @@ namespace MUSTSensorDriverPlugin { detectedObject.set_objectId(detection.trackID); tmx::messages::Position pos(detection.position_x, detection.position_y, 0); detectedObject.set_position(pos); - detectedObject.set_confidence(detection.confidence/PERCENTAGE_TO_DECIMAL); + detectedObject.set_confidence(detection.confidence/100.0); detectedObject.set_timestamp(static_cast(detection.timestamp*1000)); // convert decimal seconds to int milliseconds. detectedObject.set_velocity(headingSpeedToVelocity(detection.heading, detection.speed)); detectedObject.set_type(detectionClassificationToSensorDetectedObjectType(detection.cl)); diff --git a/src/v2i-hub/MUSTSensorDriverPlugin/src/MUSTSensorDetection.h b/src/v2i-hub/MUSTSensorDriverPlugin/src/MUSTSensorDetection.h index 71bb62ac8..9140b0252 100644 --- a/src/v2i-hub/MUSTSensorDriverPlugin/src/MUSTSensorDetection.h +++ b/src/v2i-hub/MUSTSensorDriverPlugin/src/MUSTSensorDetection.h @@ -94,7 +94,6 @@ namespace MUSTSensorDriverPlugin { DetectionSize size = DetectionSize::NA; // Confidence in type double confidence = 0; - int PERCENTAGE_TO_DECIMAL = 100.0; // Unique ID unsigned int trackID = 0; // Timestamp in seconds