Skip to content

Commit

Permalink
feat(shape_estimation): fix truck filter max size is too small problem (
Browse files Browse the repository at this point in the history
autowarefoundation#5650)

fix truck size filtering

Signed-off-by: yoshiri <[email protected]>
  • Loading branch information
YoshiRi authored Nov 27, 2023
1 parent 1eb962e commit 9b42006
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@ class TruckCorrector : public VehicleCorrector
{
corrector_utils::CorrectionBBParameters params;
params.min_width = 1.5;
params.max_width = 3.2;
params.max_width = 3.5;
params.default_width = (params.min_width + params.max_width) * 0.5;
params.min_length = 4.0;
params.max_length = 7.9;
params.default_length = (params.min_length + params.max_length) * 0.5;
params.max_length = 18.0;
params.default_length = 7.0; // 7m is the most common length of a truck in Japan
setParams(params);
}

Expand Down
4 changes: 2 additions & 2 deletions perception/shape_estimation/lib/filter/truck_filter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ bool TruckFilter::filter(
[[maybe_unused]] const geometry_msgs::msg::Pose & pose)
{
constexpr float min_width = 1.5;
constexpr float max_width = 3.2;
constexpr float max_length = 7.9; // upto 12m in japanese law
constexpr float max_width = 3.5;
constexpr float max_length = 18.0; // upto 12m in japanese law
return utils::filterVehicleBoundingBox(shape, min_width, max_width, max_length);
}

0 comments on commit 9b42006

Please sign in to comment.