Skip to content

Commit ce24c7a

Browse files
committed
chore: align comments
Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp>
1 parent ca40f14 commit ce24c7a

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

perception/multi_object_tracker/src/tracker/model/bicycle_tracker.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -143,8 +143,8 @@ BicycleTracker::BicycleTracker(
143143
ekf_.init(X, P);
144144

145145
// Set lf, lr
146-
lf_ = std::max(bounding_box_.length * 0.3, 0.3); // 30% front from the center
147-
lr_ = std::max(bounding_box_.length * 0.3, 0.3); // 30% rear from the center
146+
lf_ = std::max(bounding_box_.length * 0.3, 0.3); // 30% front from the center, minimum of 0.3m
147+
lr_ = std::max(bounding_box_.length * 0.3, 0.3); // 30% rear from the center, minimum of 0.3m
148148
}
149149

150150
bool BicycleTracker::predict(const rclcpp::Time & time)

perception/multi_object_tracker/src/tracker/model/big_vehicle_tracker.cpp

+4-4
Original file line numberDiff line numberDiff line change
@@ -158,8 +158,8 @@ BigVehicleTracker::BigVehicleTracker(
158158
setNearestCornerOrSurfaceIndex(self_transform); // this index is used in next measure step
159159

160160
// Set lf, lr
161-
lf_ = std::max(bounding_box_.length * 0.3, 1.5); // 30% front from the center
162-
lr_ = std::max(bounding_box_.length * 0.25, 1.5); // 25% rear from the center
161+
lf_ = std::max(bounding_box_.length * 0.3, 1.5); // 30% front from the center, minimum of 1.5m
162+
lr_ = std::max(bounding_box_.length * 0.25, 1.5); // 25% rear from the center, minimum of 1.5m
163163
}
164164

165165
bool BigVehicleTracker::predict(const rclcpp::Time & time)
@@ -457,8 +457,8 @@ bool BigVehicleTracker::measureWithShape(
457457
bbox_object.shape.dimensions.x, bbox_object.shape.dimensions.y, bbox_object.shape.dimensions.z};
458458

459459
// update lf, lr
460-
lf_ = std::max(bounding_box_.length * 0.3, 1.5); // 30% front from the center
461-
lr_ = std::max(bounding_box_.length * 0.25, 1.5); // 25% rear from the center
460+
lf_ = std::max(bounding_box_.length * 0.3, 1.5); // 30% front from the center, minimum of 1.5m
461+
lr_ = std::max(bounding_box_.length * 0.25, 1.5); // 25% rear from the center, minimum of 1.5m
462462
return true;
463463
}
464464

perception/multi_object_tracker/src/tracker/model/normal_vehicle_tracker.cpp

+4-4
Original file line numberDiff line numberDiff line change
@@ -158,8 +158,8 @@ NormalVehicleTracker::NormalVehicleTracker(
158158
setNearestCornerOrSurfaceIndex(self_transform); // this index is used in next measure step
159159

160160
// Set lf, lr
161-
lf_ = std::max(bounding_box_.length * 0.3, 1.0); // 30% front from the center
162-
lr_ = std::max(bounding_box_.length * 0.25, 1.0); // 25% rear from the center
161+
lf_ = std::max(bounding_box_.length * 0.3, 1.0); // 30% front from the center, minimum of 1.0m
162+
lr_ = std::max(bounding_box_.length * 0.25, 1.0); // 25% rear from the center, minimum of 1.0m
163163
}
164164

165165
bool NormalVehicleTracker::predict(const rclcpp::Time & time)
@@ -457,8 +457,8 @@ bool NormalVehicleTracker::measureWithShape(
457457
bbox_object.shape.dimensions.x, bbox_object.shape.dimensions.y, bbox_object.shape.dimensions.z};
458458

459459
// update lf, lr
460-
lf_ = std::max(bounding_box_.length * 0.3, 1.0); // 30% front from the center
461-
lr_ = std::max(bounding_box_.length * 0.25, 1.0); // 25% rear from the center
460+
lf_ = std::max(bounding_box_.length * 0.3, 1.0); // 30% front from the center, minimum of 1.0m
461+
lr_ = std::max(bounding_box_.length * 0.25, 1.0); // 25% rear from the center, minimum of 1.0m
462462

463463
return true;
464464
}

0 commit comments

Comments
 (0)