Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(behavior_velocity): parameterlize detection area length #1346

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ struct PlannerParam
bool use_moving_object_ray_cast; // [-]
bool use_partition_lanelet; // [-]
// parameters in yaml
double detection_area_offset; // [m]
double detection_area_length; // [m]
double detection_area_max_length; // [m]
double stuck_vehicle_vel; // [m/s]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ OcclusionSpotModuleManager::OcclusionSpotModuleManager(rclcpp::Node & node)
pp.is_show_processing_time = node.declare_parameter(ns + ".debug.is_show_processing_time", false);

// threshold
pp.detection_area_offset = node.declare_parameter(ns + ".threshold.detection_area_offset", 30.0);
pp.detection_area_length = node.declare_parameter(ns + ".threshold.detection_area_length", 200.0);
pp.stuck_vehicle_vel = node.declare_parameter(ns + ".threshold.stuck_vehicle_vel", 1.0);
pp.lateral_distance_thr = node.declare_parameter(ns + ".threshold.lateral_distance", 10.0);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,12 +93,11 @@ bool OcclusionSpotModule::modifyPathVelocity(
param_.v.v_ego = planner_data_->current_velocity->twist.linear.x;
param_.v.a_ego = planner_data_->current_accel.get();
param_.v.delay_time = planner_data_->system_delay;
const double detection_area_offset = 5.0; // for visualization and stability
param_.detection_area_max_length =
planning_utils::calcJudgeLineDistWithJerkLimit(
param_.v.v_ego, param_.v.a_ego, param_.v.non_effective_accel, param_.v.non_effective_jerk,
planner_data_->delay_response_time) +
detection_area_offset;
param_.detection_area_offset; // To fill difference between planned and measured acc
}
const geometry_msgs::msg::Pose ego_pose = planner_data_->current_pose.pose;
PathWithLaneId clipped_path;
Expand Down