首页 > 其他 > 详细

Lane keeping in autonomous driving with Model Predictive Control

时间:2020-11-26 09:13:14      阅读:32      评论:0      收藏:0      [点我收藏+]

Modell-pr?diktiven Regelung
Kinematic bicycle model

技术分享图片

 

we define a cost function to optimize our path with the trajectory

our cost includes:

  • Cross-track error,
  • Heading error,
  • Speed cost (prefer staying at say 100 miles/hr ),
  • Steering cost (prefer zero steering)
  • Acceleration cost (prefer zero acceleration)
  • Steering rate change (prefer small values)
  • Acceleration rate change (prefer small values)

Optimize MPC

We solve the control problem as an optimization problem using a cost function under constraints include those for actuators controlling the gas/brake pedal and the steering wheel.

  1. We read the next 6 waypoints from the lane detection and compute a 3rd order polynomial to model our trajectory.
  2. We read the current speed v, heading ψ, steering angle δ, and acceleration a from the censors.
  3. We compute our first vehicle state using these readings and the dynamic model.
  4. We want to optimize the actions for the next 1 sec while adjusting steering angle and acceleration every 100 ms. i.e. we have 10 time periods.
  5. We define an MPC with 2 independent variables: one controls the acceleration (positive for the gas pedal and negative for the brake) and the other for the steering angle.
  6. We define the allowable range of values (constraints) for acceleration and steering.
  7. We unroll the dynamic model 9 times, so we can compute the next 9 states.
  8. We also define the cost from each time period.
  9. We use an optimizer for MPC to find the best actions for time period 1 to time period 9 that have the minimum total cost under the defined constraints. (Note, in our notation, time period does not start from 0. Instead, we start from 1: period 1 to 10.)
  10. We will only take the actions suggested in the period 1 and ignore others.
  11. But, we delay 100 ms before issuing the actions to the simulator. This imitates the real world which commands take time to process and execute.
  12. We repeat step 1 again to find the next optimized actions.

https://jonathan-hui.medium.com/lane-keeping-in-autonomous-driving-with-model-predictive-control-50f06e989bc9

Lane keeping in autonomous driving with Model Predictive Control

原文:https://www.cnblogs.com/leon2014dresden/p/14040011.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!