Application of Data-driven Model Predictive Control for Autonomous Vehicle Steering
数据驱动模型预测控制应用于自动驾驶车辆转向
Abstract
With the development of autonomous driving technology, there are increasing demands for vehicle control, and MPC has become a widely researched topic in both industry and academia. Existing MPC control methods based on vehicle kinematics or dynamics have challenges such as difficult modeling, numerous parameters, strong nonlinearity, and high computational cost. To address these issues, this paper adapts an existing Data-driven MPC control method and applies it to autonomous vehicle steering control. This method avoids the need for complex vehicle system modeling and achieves trajectory tracking with relatively low computational time and small errors. We validate the control effectiveness of the algorithm in specific scenario through CarSim-Simulink simulation and perform comparative analysis with PID and vehicle kinematics MPC, confirming the feasibility and superiority of it for vehicle steering control.
Index Terms—data-driven control, autonomous vehicle steering, model predictive control, path tracking
随着自动驾驶技术的发展,对车辆控制的需求不断增加,模型预测控制(MPC)已成为工业界和学术界广泛研究的话题。基于车辆运动学或动力学的现有MPC控制方法面临诸如建模困难、参数众多、强非线性、高计算成本等挑战。为了解决这些问题,本文采用了一种现有的数据驱动MPC控制方法,并将其应用于自动驾驶车辆的转向控制。这种方法避免了复杂的车辆系统建模需求,实现了轨迹跟踪,具有相对较低的计算时间和小误差。我们通过CarSim-Simulink仿真在特定场景下验证了算法的控制效果,并与PID和车辆运动学MPC进行了比较分析,确认了其在车辆转向控制方面的可行性和优越性。
索引术语—数据驱动控制、自动驾驶车辆转向、模型预测控制、路径跟踪。
I. INTRODUCTION
Currently, autonomous driving has matured and is gradually coming into the public eye. Numerous internet and vehicle manufacturing companies are investing increasing efforts into researching autonomous driving technology, which has significantly contributed to improving traffic congestion, reducing traffic accidents, and enhancing economic benefits [1], [2]. Mastinu et al. analyzed the reasons and scenarios in which drivers lose control of the vehicle. They pointed out that after severe lane changes, gusts of wind, or other disturbances, drivers might be unable to regain the intended actions, potentially posing traffic safety hazards [3]. Moreover, Ahangar et al. found that the number of fatalities due to road traffic accidents is continually rising, with many accidents resulting from driver fatigue and distraction [4]. Additionally, the proportion of carbon dioxide emissions from road traffic in the total human carbon dioxide emissions is also increasing [5]. Therefore, research on autonomous driving technology is urgently needed.
目前,自动驾驶技术已经成熟,并逐渐进入公众视野。众多互联网公司和汽车制造企业正在加大对自动驾驶技术研究的投入,这在改善交通拥堵、减少交通事故和提升经济效益方面做出了显著贡献[1]、[2]。Mastinu等人分析了驾驶员失去对车辆控制的原因和场景。他们指出,在剧烈变道、阵风或其他干扰之后,驾驶员可能无法恢复预期动作,这可能会带来交通安全隐患[3]。此外,Ahangar等人发现,由于道路交通事故导致的死亡人数持续上升,许多事故是由于驾驶员疲劳和分心造成的[4]。同时,道路交通产生的二氧化碳排放量在人类总二氧化碳排放量中的比例也在增加[5]。因此,对自动驾驶技术的研究迫在眉睫。
Autonomous vehicles are composed of multiple modules, including perception, prediction, planning, decision-making, and control. Among them, control is one of the most critical modules, and the control methods have always been a key research focus. In the field of autonomous driving control, PID and adaptive control, etc. are widely used in the industry, which do not require mathematical modeling of the system, and the optimal control quantity can be obtained using the vehicle’s state and reference trajectory [6], [7]. In academia, however, Model Predictive Control (MPC) is a widely researched topic. First proposed by Richalet et al. in 1978 [8], MPC have since evolved with various modifications to suit different control scenarios and controlled objects [9]–[11].
自动驾驶车辆由多个模块组成,包括感知、预测、规划、决策和控制。其中,控制是最关键的模块之一,控制方法一直是研究的重点。在自动驾驶控制领域,PID和自适应控制等方法在工业界得到了广泛应用,这些方法不需要对系统进行数学建模,可以直接使用车辆的状态和参考轨迹来获得最优控制量[6]、[7]。然而,在学术界,模型预测控制(MPC)是一个广泛研究的话题。MPC最早由Richalet等人在1978年提出[8],自那以后,MPC经历了各种改进,以适应不同的控制场景和控制对象[9]–[11]。
However, general MPC require precise modeling of the controlled system. Currently, most MPC methods for autonomous driving steering control are based on vehicle kinematics or dynamics models [12], [13]. Vehicle kinematics models have fewer parameters and simple structures, but they simplify the autonomous vehicle into a two-wheel model, which significantly deviates from the actual vehicle situation and results in low control precision. On the other hand, vehicle dynamics models contain more parameters and require parameter calibration through experiments, and also the strong nonlinearity of the models leads to high optimization computational costs. Therefore, researchers have begun considering how to avoid the cumbersome modeling process and directly use data for system characteristics analysis [14] and controller design [15]– [17].
然而,传统的MPC需要对被控系统进行精确建模。目前,大多数自动驾驶转向控制的MPC方法都是基于车辆运动学或动力学模型[12]、[13]。车辆运动学模型参数较少、结构简单,但它们将自动驾驶车辆简化为双轮模型,这与实际车辆情况相差甚远,导致控制精度较低。另一方面,车辆动力学模型包含更多参数,需要通过实验进行参数校准,而且模型的强非线性导致优化计算成本高。因此,研究人员开始考虑如何避免繁琐的建模过程,直接使用数据进行系统特性分析[14]和控制器设计[15]–[17]。
Currently, Data-driven MPC becomes widely researched. This control method avoids the precise modeling of system, as required by traditional MPC algorithms, and reduces computational time while maintaining high control accuracy. To address existing vehicle control problems, this paper studies the existing Data-driven MPC and, by integrating vehicle system characteristics, applies it to vehicle steering control and verifies the feasibility of this method. The contributions of this paper are presented as follows:
目前,数据驱动的模型预测控制(MPC)被广泛研究。这种控制方法避免了传统MPC算法所要求的系统精确建模,并在保持高控制精度的同时减少了计算时间。为了解决现有的车辆控制问题,本文研究了现有的数据驱动MPC,并通过整合车辆系统特性,将其应用于车辆转向控制,并验证了这种方法的可行性。本文的贡献如下:
1.Based on the research of [18]–[21], a Data-driven Model Predictive Control method is applied to autonomous vehicle steering control.
2.The feasibility of the application of DDMPC to autonomous vehicle steering was verified through simulation experiments, and the superiority of this algorithm was demonstrated by comparing it with other algorithms.
The rest of the paper is organized as follows. Section II provides a brief introduction to our research problem and discusses Willems’ Lemma. In Section III, we introduce the existing research on DDMPC. Based on this, we make minor modifications to make the algorithm applicable to autonomous vehicle control. In Section IV, we validate the effectiveness of the proposed algorithm through CarSim and Simulink simulation experiments and conduct a comparative analysis with PID and vehicle kinematics MPC algorithms. Finally, conclusions are drawn in Section V.
1.基于对文献[18]-[21]的研究,将数据驱动的模型预测控制方法应用于自动驾驶车辆的转向控制。
2.通过仿真实验验证了DDMPC在自动驾驶车辆转向应用的可行性,并通过与其他算法的比较展示了这种算法的优越性。本文的其余部分组织如下:第二节简要介绍了我们的研究问题,并讨论了Willems引理。在第三节中,我们介绍了关于DDMPC的现有研究。基于此,我们进行了小幅修改,使算法适用于自动驾驶车辆控制。在第四节中,我们通过CarSim和Simulink仿真实验验证了所提算法的有效性,并与PID和车辆运动学MPC算法进行了比较分析。最后,在第五节中得出结论。
II. PROBLEM STATEMENT
The development of autonomous vehicle technology relies on efficient and reliable control algorithms. The advantage of MPC lies in its ability to calculate high-precision control inputs within a limited prediction horizon, based on the vehicle model and reference trajectory. Consequently, MPC often depends on accurate vehicle models, but modeling and parameter calibration of traditional vehicle models—especially dynamic models—become extremely challenging. Additionally, vehicle models often have many parameters and strong nonlinearity, which may consume a significant amount of computational time during optimization. Most scholars and engineers address this issue by linearization, but this often leads to a decrease in model accuracy.
自动驾驶车辆技术的发展依赖于高效且可靠的控制算法。模型预测控制(MPC)的优势在于其能够在有限的预测范围内,基于车辆模型和参考轨迹,计算出高精度的控制输入。因此,MPC往往依赖于精确的车辆模型,但传统车辆模型——尤其是动态模型——的建模和参数校准变得极其具有挑战性。此外,车辆模型通常包含许多参数且具有很强的非线性,这可能会在优化过程中消耗大量的计算时间。大多数学者和工程师通过线性化来解决这一问题,但这往往会导致模型准确性的降低。
Based on the Willems’s lemma, which is a data-based method for system identification [22], Jeremy first proposed an algorithmic framework called Data-enabled Predictive Control and applied it on aerial robotics [18]. Thereafter, Berberich et al. designed a robust Data-driven MPC control method [19]–[21]. This method can directly use the Hankel matrix constructed from offline input-output trajectory data of the system to replace complex system models, predicting future states of the system and thereby calculating the optimal control inputs. Lu et al. used this method to complete the data-driven identification of vehicle and designed a DDMPC controller for vehicle lateral stability control [23]. Subsequently, many scholars have expanded and applied this method [24], [25].
基于Willems引理,这是一种基于数据的系统辨识方法,Jeremy首次提出了一个名为Data-enabled Predictive Control的算法框架,并将其应用于空中机器人。此后,Berberich等人设计了一种鲁棒的数据驱动MPC控制方法–。这种方法可以直接使用从系统的离线输入输出轨迹数据构建的Hankel矩阵来替代复杂的系统模型,预测系统的未来状态,从而计算出最优的控制输入。Lu等人使用这种方法完成了车辆的数据驱动辨识,并为车辆横向稳定性控制设计了一个DDMPC控制器。随后,许多学者扩展并应用了这种方法,。
We build on this foundation by applying the data-driven MPC algorithm proposed by [18] and [19] to steering control of autonomous vehicles and provide the algorithm application flowchart, as shown in Fig. 1.
我们在[18]和[19]提出的数据驱动MPC算法的基础上,将其应用于自动驾驶车辆的转向控制,并提供了算法应用流程图,如 图1 所示。
III. APPLICATION OF DDMPC FOR AUTONOMOUS VEHICLE STEERING
A. Willems’ Lemma and Application
Here, we first review the description and application of Willems’ Lemma by [18] and [19].
在这里,我们首先回顾了[18]和[19]对Willems引理的描述和应用。
Suppose the dynamic behavior of a system is described by the following input-output relationship expressed by Eq. 1.
假设系统的动态行为由以下输入输出关系描述,如 方程1 所示。
where u(t) ∈ U ⊂ Rm is the system input at time t, with m being the input dimension; y(t) ∈ Y ⊂ Rp is the system output at time t, with p being the output dimension; G(·) is the system behavior model, generally represented by a transfer function or state-space equations.
其中
u
(
t
)
∈
U
⊂
R
m
u(t) \in U \subset \mathbb{R}^m
u(t)∈U⊂Rm 是系统在时间
t
t
t 的输入,
m
m
m 是输入的维度;
y
(
t
)
∈
Y
⊂
R
p
y(t) \in Y \subset \mathbb{R}^p
y(t)∈Y⊂Rp 是系统在时间
t
t
t 的输出,
p
p
p 是输出的维度;
G
(
⋅
)
G(\cdot)
G(⋅) 是系统行为模型,通常由传递函数或状态空间方程表示。
Apply a set of inputs U to the system, which correspondingly generates a set of outputs Y . The collected open-loop input-output data are represented as two sets of vectors in Eq. 2.
对系统应用一组输入
U
U
U,相应地产生一组输出
Y
Y
Y。收集的开环输入输出数据在 方程2 中表示为两组向量。
where N is the number of data sets, and the selection of this parameter will directly influence the subsequent design of the Data-driven MPC.
其中
N
N
N 是数据集的数量,这个参数的选择将直接影响后续数据驱动MPC的设计 。
Process the collected input-output data, which mainly includes data cleansing, continuity checking and noise removal, etc. Then, extend the data into Hankel matrices. The resulting order L Hankel matrix is as Eq. 3 and Eq. 4.
处理收集到的输入输出数据,主要包括数据清洗、连续性检查和噪声去除等。然后,将数据扩展成Hankel矩阵。得到的阶数为
L
L
L 的Hankel矩阵如方程3和方程4所示。
where L is the basic prediction horizon of the MPC algorithm. For the input matrix HL(U), we determine whether the input sequence U satisfies the requirement of persistent excitation based on the following definition.
其中
L
L
L 是MPC算法的基本预测范围。对于输入矩阵
H
L
(
U
)
H_L(U)
HL(U),我们根据以下定义判断输入序列
U
U
U 是否满足持续激励的要求。
Definition in [18], [19]: The input sequence U is order L persistently exciting if and only if the rank of the order L Hankel matrix HL(U) constructed from this input sequence satisfies the Eq. 5.
定义来自文献[18]和[19]:如果由输入序列
U
U
U 构建的阶数为
L
L
L 的Hankel矩阵
H
L
(
U
)
H_L(U)
HL(U) 的秩满足方程5,则称输入序列
U
U
U 是阶数
L
L
L 的持续激励的。
This means that the input sequence is rich enough to excite all dynamic modes of the system. Based on this definition, we can further explore the relationship between the input-output Hankel matrix and the system under study for predicting system outputs.
这意味着输入序列足够丰富,能够激发系统的所有动态模式。基于这个定义,我们可以进一步探索输入输出Hankel矩阵与被研究系统之间的关系,以预测系统输出。
Willems’ Lemma [22]: If {U, Y } = {uk, yk}N k=0 −1 is a set of N input-output data measured from system G, and U is order L + n persistently exciting, then {u¯k, y¯k}Lk=0 −1 are the predicted input-output sequences of system G for the future L time steps based on {U, Y }, if and only if there exists an α ∈ RN−L+1 that satisfies Eq. 6.
Willems引理[22]:如果
{
U
,
Y
}
=
{
u
k
,
y
k
}
k
=
0
N
−
1
\{U, Y\} = \{u_k, y_k\}_{k=0}^{N-1}
{U,Y}={uk,yk}k=0N−1 是从系统
G
G
G 测量得到的一组
N
N
N 个输入输出数据,并且
U
U
U 是阶数
L
+
n
L+n
L+n 的持续激励的,那么
{
u
ˉ
k
,
y
ˉ
k
}
k
=
0
L
−
1
\{ū_k, ȳ_k\}_{k=0}^{L-1}
{uˉk,yˉk}k=0L−1 是基于
{
U
,
Y
}
\{U, Y\}
{U,Y} 对系统
G
G
G 未来
L
L
L 个时间步的预测输入输出序列,当且仅当存在一个
α
∈
R
N
−
L
+
1
\alpha \in \mathbb{R}^{N-L+1}
α∈RN−L+1 满足方程6。
where n is the number of states of the controlled system. According to the previously given definition of persistent excitation, the rank of the order L+n Hankel matrix HL+n(U) constructed from the input sequence U of length N must satisfy the Eq. 7.
其中
n
n
n 是被控制系统的状态数。根据之前给出的持续激励的定义,由长度为
N
N
N 的输入序列
U
U
U 构建的阶数为
L
+
n
L+n
L+n 的Hankel矩阵
H
L
+
n
(
U
)
H_{L+n}(U)
HL+n(U) 的秩必须满足方程7。
Therefore, with known historical input-output data, if an optimal α can be found, we can use the above lemma to predict the system’s future inputs and outputs. This lemma is of great interest in the fields of system identification and datadriven control because it provides a new approach that allows us to bypass the derivation of the system model (and even the knowledge of the specific form of the system) and directly obtain dynamic behavior information from the open-loop data generated by the system [18]–[21]. This is because, when the input signal meets certain persistent excitation conditions, the Hankel matrix constructed from a pre-collected known input-output data segment implicitly represents the system’s dynamic characteristics and can be used to represent any inputoutput trajectory of the system of the basic prediction horizon L through linear combinations.
因此,有了已知的历史输入输出数据,如果能找到最优的
α
\alpha
α,我们就可以利用上述引理来预测系统未来的输入和输出。这个引理在系统辨识和数据驱动控制领域具有极大的兴趣,因为它提供了一种新的方法,使我们能够绕过系统模型的推导(甚至不需要知道系统的具体形式),直接从系统产生的开环数据中获得动态行为信息[18]-[21]。这是因为,当输入信号满足某些持续激励条件时,从预先收集的已知输入输出数据段构建的Hankel矩阵隐含地代表了系统的动态特性,并且可以通过线性组合用来表示基本预测范围
L
L
L 内系统的任何输入输出轨迹。
B. DDMPC for Vehicle Steering Control
Based on Willems’ lemma, existing research combined it with MPC roll optimization and designed the DDMPC optimization model [18], [19], and we adapt it in this subsection for vehicle steering control as shown in Eq. 8 to Eq. 12.
基于Willems引理,现有研究将其与MPC滚动优化相结合,设计了DDMPC优化模型[18],[19],我们在本小节中将其适应于车辆转向控制,如 方程8 至 方程12 所示。
where ykr(t) and ur k(t) represent the expected output and input of the system at time t for k time steps ahead from the current state; Q ∈ Rp×p and R ∈ Rm×m are symmetric positive definite matrices. In the context of autonomous driving control, ykr(t) corresponds to the trajectory point information of the vehicle’s position and state at the current time t extended k time steps ahead; ur k(t), from the perspective of safety and comfort, is generally set to be a zero vector, indicating that the desired control action should be minimized as much as possible. Based on Willems’ lemma, we describe y¯ and u¯ using the Hankel matrix and constrain the system state, thereby forming the equality and inequality constraint equations for the following optimization problem.
其中
y
k
r
(
t
)
y_{k}^r(t)
ykr(t) 和
u
k
r
(
t
)
u_{k}^r(t)
ukr(t) 分别代表从当前状态开始,系统在时间
t
t
t 向前
k
k
k 个时间步的预期输出和输入;
Q
∈
R
p
×
p
Q \in \mathbb{R}^{p \times p}
Q∈Rp×p 和
R
∈
R
m
×
m
R \in \mathbb{R}^{m \times m}
R∈Rm×m 是对称正定矩阵。在自动驾驶控制的背景下,
y
k
r
(
t
)
y_{k}^r(t)
ykr(t) 对应于车辆在当前时间
t
t
t 向前
k
k
k 个时间步的位置和状态的轨迹点信息;从安全和舒适的角度来看,
u
k
r
(
t
)
u_{k}^r(t)
ukr(t) 通常被设置为零向量,表示期望的控制动作应尽可能小。基于Willems引理,我们使用Hankel矩阵描述
y
ˉ
\bar{y}
yˉ 和
u
ˉ
\bar{u}
uˉ,并约束系统状态,从而形成了以下优化问题的等式和不等式约束方程。
In this context, Eq. 9 represents the initial constraint, where u −n(t) and y−n(t) denote the actual control inputs and outputs of the system for n time steps before time t, respectively. This constraint aims to use the actual dynamic behavior of the system to constrain the decision variable α(t), ensuring that the prediction results closely match the actual system behavior.
在这种情况下,方程9 表示初始约束,其中
u
−
n
(
t
)
u_{-n}(t)
u−n(t) 和
y
−
n
(
t
)
y_{-n}(t)
y−n(t) 分别表示在时间
t
t
t 之前
n
n
n 个时间步的实际控制输入和输出。这个约束旨在利用系统的实际动态行为来约束决策变量
α
(
t
)
\alpha(t)
α(t),确保预测结果与实际系统行为紧密匹配。
Eq. 10 is the application of Willems’ lemma in the Datadriven MPC algorithm. It uses the Hankel matrix to predict the system’s input-output, serving as the equality constraint of this optimization problem. By comparing the predicted system output y¯(t) with the reference trajectory ykr(t), the optimal control sequence u¯(t) is obtained.
方程10 是Willems引理在数据驱动MPC算法中的应用。它使用Hankel矩阵来预测系统的输入输出,作为这个优化问题的等式约束。通过将预测的系统输出
y
ˉ
(
t
)
\bar{y}(t)
yˉ(t) 与参考轨迹
y
k
r
(
t
)
y_{k}^r(t)
ykr(t) 进行比较,可以获得最优的控制序列
u
ˉ
(
t
)
\bar{u}(t)
uˉ(t)。
Eq. 11 represents the upper and lower bounds constraints on the decision variables. Unlike general systems, in the context of autonomous driving control, constraints on the control input u¯(t) are particularly critical because the control inputs are typically acceleration or front wheel steering angles. We generally need to limit the range of u¯(t) from the perspectives of both safety and comfort. It is worth noting that the prediction horizon chosen here should be L+n, which requires the openloop input sequence to be order L + 2n persistently exciting [19]. Additionally, the Hankel matrix constructed from the open-loop data should be of order L + n, satisfying Eq. 13.
方程11 表示对决策变量的上下界约束。与一般系统不同,在自动驾驶控制的背景下,对控制输入
u
ˉ
(
t
)
\bar{u}(t)
uˉ(t) 的约束尤为重要,因为控制输入通常是加速度或前轮转向角度。我们通常需要从安全和舒适的角度限制
u
ˉ
(
t
)
\bar{u}(t)
uˉ(t) 的范围。值得注意的是,这里选择的预测范围应该是
L
+
n
L+n
L+n,这要求开环输入序列是阶数
L
+
2
n
L + 2n
L+2n 的持续激励[19]。此外,从开环数据构建的Hankel矩阵应该是阶数
L
+
n
L+n
L+n,满足方程13。
At this point, we have obtained the DDMPC framework for vehicle steering control. We only need to solve the optimization problem Eq. 8 to Eq. 12 at time t, and apply the first control input of the optimal control sequence u¯1(t) (In this study, it is the left and right front wheel angle values) to the autonomous vehicle to complete the control at the current time.
此时,我们已经得到了车辆转向控制的数据驱动MPC框架。我们只需要在时间
t
t
t 解决优化问题方程8至方程12,并应用最优控制序列
u
ˉ
1
(
t
)
\bar{u}_1(t)
uˉ1(t) 的第一个控制输入(在本研究中,是左右前轮角度值)到自动驾驶车辆上,以完成当前时间的控制。
IV. EXPERIMENTS AND RESULTS
To verify the effectiveness of the algorithm, simulation experiments are conducted based on CarSim and Simulink softwares. CarSim is a commonly used simulation platform for vehicle experiments, providing precise vehicle dynamics models which can realistically reproduce vehicle operations in real-world scenarios. The simulation experiments are divided into two stages: open-loop data collection and closed-loop algorithm simulation verification, following the same logic as the design of algorithm.
为了验证算法的有效性,我们基于CarSim和Simulink软件进行了仿真实验。CarSim是一个常用的车辆实验仿真平台,提供了精确的车辆动力学模型,能够真实地再现现实世界场景中的车辆操作。仿真实验分为两个阶段:开环数据收集和闭环算法仿真验证,遵循算法设计的相同逻辑。
In CarSim, a D-Class Sedan vehicle model is selected as the test vehicle for open-loop data collection and algorithm simulation verification. The specific parameters are shown in Table. I.
在CarSim中,选择了一个D级轿车模型作为开环数据收集和算法仿真验证的测试车辆。具体参数如 表I 所示。
A. Open-Loop Data Collection
In CarSim, we set up a test environment for open-loop data collection. This environment should include as many steering scenarios as possible to ensure that the input sequence is sufficiently rich to activate the dynamic characteristics of the vehicle.
在CarSim中,我们建立了一个用于开环数据收集的测试环境。这个环境应该包含尽可能多的转向场景,以确保输入序列足够丰富,能够激发车辆的动态特性。
The vehicle’s horizontal coordinate X and vertical coordinate Y are chosen in the global coordinate system, as well as the vehicle’s heading angle ϕ, as the output variables. The left front wheel steering angle δL and the right front wheel steering angle δR are selected as the control variables. Thus, the vehicle’s open-loop input-output sequence can be expressed as Eq. 14 and Eq. 15.
在全局坐标系中,我们选择车辆的水平坐标
X
X
X 和垂直坐标
Y
Y
Y,以及车辆的航向角
ϕ
\phi
ϕ 作为输出变量。左前轮转向角
δ
L
\delta_L
δL 和右前轮转向角
δ
R
\delta_R
δR 被选作控制变量。因此,车辆的开环输入输出序列可以表示为方程14和方程15。
Due to the non-constant speed of the vehicle, it is necessary to interpolate the sparser parts of the collected raw data. Additionally, the data needs to be preprocessed, including data cleaning and outlier removal. The final amount of data obtained is N = 646.
由于车辆的速度不恒定,因此需要对收集到的原始数据中较稀疏的部分进行插值处理。此外,数据还需要进行预处理,包括数据清洗和异常值剔除。最终获得的数据量为 ( N = 646 )。
B. Simulation Experiments
Since we do not need to model the vehicle system, the system order n is unknown here. Therefore, we assign an upper bound v to the system order, and set v = 6 to substitute for n in the algorithm. Additionally, we set the basic prediction horizon L = 24, making the prediction horizon L + v = 30. The weight matrices are set as Q = Ip, R = 10−2 · Im, and λ = 1 · 10−3. To meet the vehicle’s safety and comfort requirements, we set umin = −1.5◦ and umax = +1.5◦. Besides, We don’t bind α(t) and y¯(t), and keep the vehicle speed around 36 km/h.
由于我们不需要对车辆系统进行建模,因此在这里系统阶数
n
n
n 是未知的。因此,我们给系统阶数指定一个上限
v
v
v,并设置
v
=
6
v = 6
v=6 来替代算法中的
n
n
n。此外,我们设置基本预测范围
L
=
24
L = 24
L=24,使得预测范围
L
+
v
=
30
L + v = 30
L+v=30。权重矩阵设置为
Q
=
I
p
Q = I_p
Q=Ip,
R
=
1
0
−
2
⋅
I
m
R = 10^{-2} \cdot I_m
R=10−2⋅Im,并且
λ
=
1
⋅
1
0
−
3
\lambda = 1 \cdot 10^{-3}
λ=1⋅10−3。为了满足车辆的安全和舒适性要求,我们设置
u
min
=
−
1.
5
∘
u_{\text{min}} = -1.5^\circ
umin=−1.5∘ 和
u
max
=
+
1.
5
∘
u_{\text{max}} = +1.5^\circ
umax=+1.5∘。此外,我们不对
α
(
t
)
\alpha(t)
α(t) 和
y
ˉ
(
t
)
\bar{y}(t)
yˉ(t) 进行约束,并保持车辆速度在大约36公里/小时。
A dual-lane switching scenario shown in Fig. 2 is selected as the simulation experiment case. Additionally, the experiments are conducted using PID and vehicle kinematics MPC control algorithms in the same scenario and the comparative analysis is performed with the results of the Data-driven MPC experiments to demonstrate the advantages of the application of it in vehicle steering control.
选择了 图2 所示的双车道变换场景作为仿真实验案例。此外,在同一场景下使用PID和车辆运动学MPC控制算法进行实验,并将这些结果与数据驱动MPC实验的结果进行比较分析,以展示数据驱动MPC在车辆转向控制中应用的优势。
C. Results Analysis
Fig. 4 shows the variation of the left and right front wheel steering angles over time under the control of DDMPC. As can be seen, the trends of the left and right front wheel steering angles are almost identical and change smoothly without severe fluctuations, remaining −5◦ to +5◦. This indicates that the algorithm allows for stable lane changes without excessively aggressive steering maneuvers, ensuring vehicle stability and comfort. Moreover, DDMPC can respond quickly in turning scenarios, ensuring vehicle control safety during emergency lane changes.
图4 显示了在数据驱动MPC控制下左右前轮转向角度随时间的变化。可以看出,左右前轮转向角度的趋势几乎相同,变化平稳,没有剧烈波动,保持在-5°到+5°之间。这表明该算法允许在不采取过于激进的转向操作的情况下稳定地变换车道,确保车辆的稳定性和舒适性。此外,DDMPC在转弯场景中能够快速响应,确保在紧急变道时的车辆控制安全。
To verify the practical value for steering control of DDMPC, we compared it with PID and vehicle kinematics MPC algorithms. Fig. 3 and Fig. 5 show the global trajectory and tracking error of the three algorithms in the same scenario. All three algorithms can achieve trajectory tracking within a certain error range. However, the vehicle kinematics MPC and PID algorithms exhibit vehicle deviation from the track during the curve-to-straight transition, whereas DDMPC ensures a quick response in steering angles during this transition, allowing the vehicle to follow the desired trajectory continuously. Additionally, as shown in Fig. 5, the error variation range of DDMPC is relatively small and generally maintained between −0.1 m and 0.2 m with almost no outliers, which indicates that there are almost no severe deviations.
为了验证DDMPC在转向控制方面的实际价值,我们将其与PID和车辆运动学MPC算法进行了比较。图3 和 图5 显示了这三种算法在同一场景下的全局轨迹和跟踪误差。所有三种算法都能在一定误差范围内实现轨迹跟踪。然而,车辆运动学MPC和PID算法在曲线到直线的过渡过程中表现出车辆偏离轨迹的情况,而DDMPC在这种过渡期间能够快速响应转向角度,使车辆能够连续跟随期望轨迹。此外,如 图5 所示,DDMPC的误差变化范围相对较小,通常保持在-0.1米到0.2米之间,几乎没有异常值,这表明几乎没有严重的偏离。
From Fig. 6, it can be observed that the computation time of DDMPC is almost half that of the vehicle kinematics MPC, since the computation time of it is only related to the data volume N and the prediction horizon L + v, and not to the complexity of the system. This shows that we can ensure control accuracy while minimizing computation time by choosing appropriate values for N, L, and v.
从 图6 可以看出,DDMPC的计算时间几乎是车辆运动学MPC的一半,因为其计算时间只与数据量
N
N
N 和预测范围
L
+
v
L + v
L+v 有关,而与系统的复杂性无关。这表明我们可以通过为
N
、
L
和
v
N、L 和 v
N、L和v 选择适当的值,在确保控制精度的同时最小化计算时间。
V. CONCLUSION
In this study, we researched the existing Data-driven Model Predictive Control method proposed by [18]–[21] and apply it to steering control of autonomous vehicle. Our experiments demonstrated that the algorithm could achieve stable front wheel angle control for tracking the reference trajectory, and compared to traditional MPC algorithms, it effectively reduces control errors and computation time. For more demonstrations of the effects of the experimental section go to: https://john0915aaa.github.io/DDMPC-for-AV-steering/.
在本研究中,我们研究了现有的数据驱动模型预测控制方法,该方法由文献[18]-[21]提出,并将其应用于自动驾驶车辆的转向控制。我们的实验表明,该算法能够实现稳定的前轮角度控制以跟踪参考轨迹,与传统的MPC算法相比,它有效地减少了控制误差和计算时间。有关实验部分效果的更多演示,您可以参考以下链接:DDMPC-for-AV-steering。
Our future work will focus on enhancing the algorithm’s robustness and real-time adaptability to further improve its effectiveness in diverse driving conditions.
我们未来的工作将专注于增强算法的鲁棒性和实时适应性,以进一步提高其在多样化驾驶条件下的有效性。