Skip to content

Commit

Permalink
#2218 Switch twist source for Detections
Browse files Browse the repository at this point in the history
The external object to detection conversion function was using
velocity_inst instead of velocity. The former has twist values but not
the corresponding covariance matrixes.
  • Loading branch information
adamlm committed Dec 15, 2023
1 parent a3d27f6 commit 54efb55
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions carma_cooperative_perception/src/msg_conversion.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -314,8 +314,8 @@ auto to_detection_msg(
detection.pose = object.pose;
}

if (object.presence_vector & object.VELOCITY_INST_PRESENCE_VECTOR) {
detection.twist = object.velocity_inst;
if (object.presence_vector & object.VELOCITY_PRESENCE_VECTOR) {
detection.twist = object.velocity;
}

if (object.presence_vector & object.OBJECT_TYPE_PRESENCE_VECTOR) {
Expand Down

0 comments on commit 54efb55

Please sign in to comment.