Scene construction methods, apparatus, computer equipment, and readable storage media

By acquiring and analyzing data on road structure and traffic participants at intersections, dynamic simulation scenarios are constructed, solving the problem of overly idealized simulation scenarios in existing technologies and achieving higher accuracy and applicability in autonomous driving testing.

CN119623237BActive Publication Date: 2026-06-30TSINGHUA UNIVERSITY

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
TSINGHUA UNIVERSITY
Filing Date
2024-10-28
Publication Date
2026-06-30

AI Technical Summary

Technical Problem

Existing scenario construction methods, based on fixed driving trajectories and road structure datasets, create overly idealized simulation scenarios, resulting in low accuracy in autonomous driving tests.

Method used

By acquiring road structure datasets and traffic participant motion datasets at intersections, driving features of vehicles are extracted. A surrogate model is used to determine the predicted offset trajectory sequence set, and vehicle driving trajectories are dynamically adjusted to construct a dynamic simulation scenario.

Benefits of technology

It improves the realism and applicability of dynamic simulation scenarios, enables two-way avoidance by both autonomous and manually driven vehicles, and enhances the accuracy of autonomous driving testing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119623237B_ABST
    Figure CN119623237B_ABST
Patent Text Reader

Abstract

This application relates to a scenario construction method, apparatus, computer device, computer-readable storage medium, and computer program product. The method includes: acquiring a road structure dataset and a traffic participant motion dataset for an intersection; the traffic participant motion dataset contains motion datasets of each vehicle and each reference object passing through the intersection; extracting driving features of each vehicle passing through the intersection based on the road structure dataset and the traffic participant motion dataset to obtain a vehicle driving feature set, and determining a predicted offset trajectory sequence set of the vehicle based on the driving feature set and a proxy model; using the predicted offset trajectory sequence set to dynamically adjust the vehicle's driving trajectory; and obtaining a dynamic simulation scenario of the intersection based on the predicted offset trajectory sequence sets, the traffic participant motion dataset, and the road structure dataset. This method can improve the realism of the dynamic simulation scenario and the accuracy of autonomous driving testing.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of vehicle testing technology, and in particular to a scenario construction method, apparatus, computer equipment, computer-readable storage medium, and computer program product. Background Technology

[0002] With the rapid development of autonomous driving technology, there is a need to construct simulated scenarios of vehicles passing through intersections using scenario building methods. These simulated scenarios are then used to test the behavior of vehicles in autonomous driving mode when passing through intersections on computer equipment.

[0003] Current scenario construction methods collect road structure datasets from real intersections and natural driving data of vehicles passing through the intersection within a preset time period. The natural driving data only includes fixed driving trajectories of vehicles passing through the intersection. The road structure dataset and each fixed driving trajectory are then combined to create a simulated intersection scenario.

[0004] However, current scenario construction methods, which construct simulation scenarios based on fixed driving trajectories and fixed road structure datasets, are overly idealized simulation scenarios with significant limitations, resulting in low accuracy in autonomous driving tests. Summary of the Invention

[0005] Therefore, it is necessary to provide a scenario construction method, apparatus, computer equipment, computer-readable storage medium, and computer program product to address the aforementioned technical problems.

[0006] Firstly, this application provides a scenario construction method, including:

[0007] Obtain the road structure dataset and traffic participant motion dataset of the intersection; the traffic participant motion dataset includes the motion datasets of each vehicle and each reference object passing through the intersection;

[0008] Based on the road structure dataset and the traffic participant motion dataset, driving features of each vehicle passing through the intersection are extracted to obtain the driving feature set of the vehicle. Based on the driving feature set and the surrogate model, the estimated offset trajectory sequence set of the vehicle is determined. The estimated offset trajectory sequence set is used to dynamically adjust the driving trajectory of the vehicle.

[0009] Based on the predicted offset trajectory sequence sets, the traffic participant motion dataset, and the road structure dataset, a dynamic simulation scenario of the intersection is obtained.

[0010] In one embodiment, obtaining the road structure dataset of the intersection includes:

[0011] Obtain the initial road structure dataset of the intersection; the initial road structure dataset includes the lane lines and boundary lines of the intersection;

[0012] Each lane of the intersection is determined based on each of the lane lines and each of the boundary lines, and each of the lanes is marked.

[0013] Traverse each lane and establish a reference driving trajectory between the lane and other lanes, starting from the lane, to obtain a set of reference driving trajectories;

[0014] The initial road structure dataset is updated based on the reference driving trajectory set and each of the lanes to obtain the road structure dataset.

[0015] In one embodiment, the road structure dataset includes a reference driving trajectory set, and the driving features include traffic intention features, interaction features, and offset features. The driving features of each vehicle passing through the intersection are extracted based on the road structure dataset and the traffic participant motion dataset to obtain the vehicle's driving feature set, including:

[0016] For each of the aforementioned vehicles, the motion dataset is determined as the main motion dataset.

[0017] In the traffic participant motion dataset, each reference vehicle and each reference object that appears simultaneously with the vehicle is filtered out, and the motion datasets of each reference vehicle and each reference object are determined as each sub-motion dataset;

[0018] Based on the traffic intention rules and the main motion dataset, the traffic intention features of the vehicle are extracted, and the reference driving trajectory corresponding to the traffic intention features is determined in the reference driving trajectory set.

[0019] Based on the road structure dataset, the reference driving trajectory, the main motion dataset, and each of the secondary motion datasets, the interaction features and offset features of the vehicle are extracted, and the driving feature set of the vehicle is constructed based on the traffic intention features, the interaction features, and the offset features.

[0020] In one embodiment, the road structure dataset includes boundary lines and stop lines, and the main motion dataset includes subsets of main motion data at each acquisition time. The step of extracting the vehicle's interaction features and offset features based on the road structure dataset, the reference driving trajectory, the main motion dataset, and each of the secondary motion datasets includes:

[0021] For each subset of the main motion data, offset operations are performed on the stop line, the reference driving trajectory, and the actual position data in the subset of the main motion data according to the horizontal and vertical offset algorithms to obtain offset features;

[0022] In each of the sub-motion datasets, determine the sub-motion data subset corresponding to the primary motion data subset;

[0023] Based on the interaction feature algorithm, features are extracted from the main motion data subset, each of the secondary motion data subsets, and each boundary line to obtain the interaction features of the vehicle.

[0024] In one embodiment, constructing the vehicle's driving feature set based on the travel intention feature, the interaction feature, and the offset feature includes:

[0025] Based on each of the interaction features, the offset features corresponding to the interaction features, and the travel intention features, a subset of the vehicle's driving features at the time of data collection is constructed.

[0026] The driving feature set of the vehicle is constructed based on each of the aforementioned driving feature subsets.

[0027] In one embodiment, determining the predicted offset trajectory sequence set of the vehicle based on the driving feature set and the agent model includes:

[0028] Each subset of driving features in the driving feature set is divided into a driving feature subset group;

[0029] Based on the surrogate model, each of the aforementioned driving feature subsets is predicted to obtain an initial estimated offset trajectory sequence.

[0030] The initial estimated offset trajectory sequence is subjected to coordinate transformation to obtain an estimated offset trajectory sequence, and an estimated offset trajectory sequence set is constructed based on each of the estimated offset trajectory sequences.

[0031] Secondly, this application also provides a scene construction apparatus, including:

[0032] The acquisition module is used to acquire the road structure dataset and traffic participant motion dataset of the intersection; the traffic participant motion dataset includes the motion datasets of each vehicle and each reference object passing through the intersection;

[0033] An extraction module is used to extract driving features of each vehicle passing through the intersection based on the road structure dataset and the traffic participant motion dataset, to obtain the driving feature set of the vehicle, and to determine the estimated offset trajectory sequence set of the vehicle based on the driving feature set and the surrogate model; the estimated offset trajectory sequence set is used to dynamically adjust the driving trajectory of the vehicle.

[0034] The combination module is used to obtain the dynamic simulation scene of the intersection based on the predicted offset trajectory sequence set, the traffic participant motion dataset, and the road structure dataset.

[0035] Thirdly, this application also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to perform the following steps:

[0036] Obtain the road structure dataset and traffic participant motion dataset of the intersection; the traffic participant motion dataset includes the motion datasets of each vehicle and each reference object passing through the intersection;

[0037] Based on the road structure dataset and the traffic participant motion dataset, driving features of each vehicle passing through the intersection are extracted to obtain the driving feature set of the vehicle. Based on the driving feature set and the surrogate model, the estimated offset trajectory sequence set of the vehicle is determined. The estimated offset trajectory sequence set is used to dynamically adjust the driving trajectory of the vehicle.

[0038] Based on the predicted offset trajectory sequence sets, the traffic participant motion dataset, and the road structure dataset, a dynamic simulation scenario of the intersection is obtained.

[0039] Fourthly, this application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, performs the following steps:

[0040] Obtain the road structure dataset and traffic participant motion dataset of the intersection; the traffic participant motion dataset includes the motion datasets of each vehicle and each reference object passing through the intersection;

[0041] Based on the road structure dataset and the traffic participant motion dataset, driving features of each vehicle passing through the intersection are extracted to obtain the driving feature set of the vehicle. Based on the driving feature set and the surrogate model, the estimated offset trajectory sequence set of the vehicle is determined. The estimated offset trajectory sequence set is used to dynamically adjust the driving trajectory of the vehicle.

[0042] Based on the predicted offset trajectory sequence sets, the traffic participant motion dataset, and the road structure dataset, a dynamic simulation scenario of the intersection is obtained.

[0043] Fifthly, this application also provides a computer program product, including a computer program that, when executed by a processor, performs the following steps:

[0044] Obtain the road structure dataset and traffic participant motion dataset of the intersection; the traffic participant motion dataset includes the motion datasets of each vehicle and each reference object passing through the intersection;

[0045] Based on the road structure dataset and the traffic participant motion dataset, driving features of each vehicle passing through the intersection are extracted to obtain the driving feature set of the vehicle. Based on the driving feature set and the surrogate model, the estimated offset trajectory sequence set of the vehicle is determined. The estimated offset trajectory sequence set is used to dynamically adjust the driving trajectory of the vehicle.

[0046] Based on the predicted offset trajectory sequence sets, the traffic participant motion dataset, and the road structure dataset, a dynamic simulation scenario of the intersection is obtained.

[0047] The aforementioned scenario construction method, apparatus, computer equipment, computer-readable storage medium, and computer program product acquire a road structure dataset and a traffic participant motion dataset for an intersection. The traffic participant motion dataset includes motion datasets of each vehicle and each reference object passing through the intersection. Based on the road structure dataset and the traffic participant motion dataset, driving features of each vehicle passing through the intersection are extracted to obtain a vehicle driving feature set. Based on the driving feature set and a proxy model, a predicted offset trajectory sequence set for the vehicle is determined. The predicted offset trajectory sequence set is used to dynamically adjust the vehicle's driving trajectory. Based on each predicted offset trajectory sequence set, the traffic participant motion dataset, and the road structure dataset, a dynamic simulation scenario of the intersection is obtained. Using this method, by extracting driving features of vehicles passing through the intersection and determining the predicted offset trajectory sequence set of vehicles through a proxy model and the driving feature set, the driving trajectory can be dynamically adjusted based on the predicted offset trajectory sequence set. Furthermore, a dynamic simulation scenario can be obtained based on each offset trajectory sequence set, the traffic participant motion dataset, and the road structure dataset, improving the realism of the dynamic simulation scenario and expanding its applicability. Testing autonomous vehicles based on this dynamic simulation scenario enables two-way avoidance between autonomous and manually driven vehicles, improving the accuracy of autonomous driving testing. Attached Figure Description

[0048] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the description of the embodiments of this application or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.

[0049] Figure 1 This is a flowchart illustrating a scene construction method in one embodiment;

[0050] Figure 2 This is a flowchart illustrating the process of obtaining a road structure dataset in one embodiment;

[0051] Figure 3 This is a flowchart illustrating the process of extracting driving features in one embodiment;

[0052] Figure 4 This is a flowchart illustrating the process of extracting interaction features and offset features in one embodiment;

[0053] Figure 5 This is a schematic diagram of the process for constructing a driving feature set in one embodiment;

[0054] Figure 6 This is a flowchart illustrating the process of determining the estimated offset trajectory sequence set in one embodiment;

[0055] Figure 7 This is a schematic diagram of the process of training the initial agent model in one embodiment;

[0056] Figure 8 This is an architectural diagram of a scene construction device in one embodiment;

[0057] Figure 9 This is a schematic diagram illustrating the vehicle trajectory in a static simulation scene and the vehicle trajectory in a dynamic simulation scene in one embodiment;

[0058] Figure 10 This is a schematic diagram of the architecture of the training module in one embodiment;

[0059] Figure 11 This is a structural block diagram of a scene construction device in one embodiment;

[0060] Figure 12 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation

[0061] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0062] In one embodiment, such as Figure 1 As shown, a scene construction method is provided. This application embodiment uses the application of this method to a computer device as an example for illustration. This application embodiment does not limit the execution device of the scene construction method, and includes the following steps 102 to 106:

[0063] Step 102: Obtain the road structure dataset and traffic participant motion dataset of the intersection.

[0064] The traffic participant motion dataset includes motion datasets of each vehicle and each reference object passing through the intersection.

[0065] In implementation, the computer equipment acquires an initial road structure dataset of the intersection and preprocesses it to obtain a new road structure dataset. Simultaneously, based on preset acquisition conditions, the computer equipment acquires motion datasets of each traffic participant passing through the intersection, resulting in a traffic participant motion dataset. The traffic participants include each vehicle and each reference object.

[0066] Specifically, the acquisition condition is a first time period. The computer device acquires all lane lines and all boundary lines of the intersection, and acquires the traffic light phases of the intersection. The computer device constructs an initial road structure dataset of the intersection based on each lane line, each boundary line, and the traffic light phases. The computer device determines each lane and a reference driving trajectory set based on each lane line and each boundary line, and updates the initial road structure dataset according to each lane and the reference driving trajectory set, thus obtaining the road structure dataset. Then, the computer device acquires the motion dataset of each traffic participant passing through the intersection within a preset period, thus obtaining the traffic participant dataset.

[0067] In an exemplary embodiment, the data acquisition device collects motion datasets of each traffic participant passing through the intersection at preset time intervals and a first time period. The motion datasets include the position, speed, acceleration, and attribute information of each traffic participant at each acquisition time. Based on the actual position data of the traffic participants at each acquisition time, the travel trajectory of each traffic participant passing through the intersection can be constructed. The data acquisition device transmits the motion datasets of each traffic participant at each acquisition time to a computer device. The computer device receives the motion datasets of each traffic participant at each acquisition time and obtains the traffic participant dataset.

[0068] Optionally, the reference object may be, but is not limited to, non-motorized vehicles and humans. Non-motorized vehicles include bicycles and electric bicycles, and the acquisition condition can be set to a first time period or the number of traffic participants. This application does not limit the reference object or the acquisition condition in its embodiments.

[0069] Step 104: Extract the driving features of each vehicle passing through the intersection based on the road structure dataset and traffic participant motion dataset to obtain the vehicle driving feature set, and determine the vehicle's predicted offset trajectory sequence set based on the driving feature set and the surrogate model.

[0070] The predicted offset trajectory sequence set is used to dynamically adjust the vehicle's driving trajectory. Driving features include offset features, driving intention features, and interaction features.

[0071] In implementation, the computer equipment extracts driving intention features, offset features, and interaction features for each vehicle passing through the intersection based on the road structure dataset and traffic participant motion dataset, obtaining a vehicle driving feature set. Then, the computer equipment performs predictive processing on the driving feature set based on a surrogate model to obtain a set of predicted vehicle offset estimation sequences.

[0072] Specifically, for each vehicle's motion dataset, the computer device designates the primary motion dataset and then filters the corresponding secondary motion datasets from the traffic participant dataset. Next, based on the primary motion dataset, the secondary motion datasets, and the road structure dataset, the computer device extracts the vehicle's travel intention features, offset features, and interaction features at the intersection, thus obtaining the vehicle's driving feature set. The travel intention features characterize the traffic participant's direction of travel. The interaction features are the interactions between the traffic participant and reference objects or other vehicles or the intersection environment. The offset features are the amount of deviation between the vehicle's trajectory and the reference trajectory.

[0073] Step 106: Based on the predicted offset trajectory sequence sets, traffic participant motion datasets, and road structure datasets, a dynamic simulation scenario of the intersection is obtained.

[0074] The dynamic simulation scenario at the intersection is used to test the autonomous driving of vehicles.

[0075] In practice, computer equipment combines various predicted offset trajectory sequences, interactive participant motion datasets, and road structure datasets to obtain a dynamic simulation scenario of the intersection.

[0076] In an exemplary embodiment, a computer device performs dynamic simulation based on a dynamic simulation scenario of an intersection to obtain a simulation model. The computer device adds an autonomous vehicle to the simulation model. When the autonomous vehicle's trajectory conflicts with that of a target vehicle among the traffic participants, the target vehicle adjusts its trajectory based on a predicted offset trajectory sequence from a set of predicted offset trajectory sequences corresponding to the target vehicle, thereby avoiding the autonomous vehicle. Simultaneously, the autonomous vehicle also adjusts its trajectory to avoid the target vehicle. After successfully avoiding the autonomous vehicle, the target vehicle adjusts its trajectory again based on the predicted offset trajectory sequence from the set of predicted offset trajectory sequences, thereby achieving the target vehicle's intended passage.

[0077] In the aforementioned scenario construction method, driving features of vehicles passing through intersections are extracted, and a predicted offset trajectory sequence set of vehicles is determined through a proxy model and the driving feature set. Based on this predicted offset trajectory sequence set, the driving trajectory can be dynamically adjusted. Furthermore, a dynamic simulation scenario can be obtained based on each offset trajectory sequence set, traffic participant motion dataset, and road structure dataset, improving the realism of the dynamic simulation scenario and expanding its applicability. Testing autonomous vehicles based on this dynamic simulation scenario enables bidirectional avoidance by both autonomous and manually driven vehicles, improving the accuracy of autonomous driving testing.

[0078] In one exemplary embodiment, such as Figure 2 As shown, the specific processing steps for obtaining the road structure dataset of the intersection in step 102 include steps 202 to 208. Wherein:

[0079] Step 202: Obtain the initial road structure dataset of the intersection.

[0080] The initial road structure dataset includes lane lines and boundary lines at intersections.

[0081] During implementation, the computer equipment acquires the lane lines, boundary lines, and stop lines of the intersection. Simultaneously, it acquires the traffic light phases. Traffic light phases refer to the different display states of traffic lights, used to indicate when vehicles and pedestrians can cross the intersection. Phases are generally divided into four stages, each with different indicator lights. The stop line is a solid white line located at the intersection's approach lane. The stop line indicates the stopping position for vehicles waiting for the traffic light; vehicles must wait behind the stop line and cannot cross or touch it. The computer equipment combines the lane lines, boundary lines, stop lines, and traffic light phases to obtain the initial road structure dataset.

[0082] Specifically, the computer equipment draws the lane lines, boundary lines, and stop lines of the intersection and acquires the traffic light phases. Specifically, the lane lines, boundary lines, and stop lines are all obtained by piecewise fitting of discrete points. The computer equipment approximates the non-interactive area of ​​the intersection as a straight line y = kx + b, and converts the arcs connecting the straight lines in the interactive area into standard circular arcs. Approximate fitting yields the fitted lane lines, boundary lines, and stop lines.

[0083] Step 204: Determine each lane of the intersection based on each lane line and each boundary line, and mark each lane.

[0084] In practice, the computer equipment draws the roads of the intersection based on the boundary lines, and divides each road into lanes based on the lane lines, thus obtaining the lanes for each road. Then, the computer equipment marks each lane based on its direction, thus obtaining the lane name.

[0085] In an exemplary embodiment, the computer device draws four roads (east, west, south, and north) at an intersection based on boundary lines, and draws a circular interaction area. Then, the computer device divides each road according to lane lines to obtain lanes. There are six lanes in total on the eastbound and westbound roads, and four lanes in total on the southbound and northbound roads. The computer device names the six lanes on the eastbound road as East Lane 1, East Lane 2, East Lane 3, East Lane 4, East Lane 5, and East Lane 6, respectively, from north to south, and names the lanes on the westbound road as West Lane 1, West Lane 2, West Lane 3, West Lane 4, West Lane 5, and West Lane 6, respectively. Similarly, the computer device names the four lanes on the northbound road as North Lane 1, North Lane 2, North Lane 3, and North Lane 4, respectively, from north to west, and names the four lanes on the southbound road as South Lane 1, South Lane 2, South Lane 3, and South Lane 4, respectively.

[0086] Step 206: Traverse each lane and establish a reference driving trajectory between the lane and other lanes, starting from the lane, to obtain a set of reference driving trajectories.

[0087] In practice, the computer equipment determines the lane centerline for each lane based on the lane lines and boundary lines. Then, starting from the lane centerline, the computer equipment connects that lane centerline with the lane centerlines of other lanes to obtain a reference driving trajectory from one lane to another.

[0088] For example, if the lane is the middle lane, the computer determines the lane centerline based on the lane lines. If the lane is an edge lane, the computer determines the lane centerline based on both the lane lines and the boundary lines.

[0089] In an exemplary embodiment, the lanes include east lane 1, east lane 2, east lane 3, east lane 4, east lane 5, and east lane 6 for eastbound roads; west lane 1, west lane 2, west lane 3, west lane 4, west lane 5, and west lane 6 for westbound roads; north lane 1, north lane 2, north lane 3, and north lane 4 for northbound roads; and south lane 1, south lane 2, south lane 3, and south lane 4 for southbound roads. For east lane 1, the computer device starts from the center line of east lane 1 and connects the center line of east lane 1 with the center line of west lane 1 to obtain a reference driving trajectory for the vehicle from east lane 1 to west lane 1. Then, the computer device draws the reference driving trajectories from east lane 1 to west lane 2, west lane 3, west lane 4, west lane 5, west lane 6, south lane 1, south lane 2, south lane 3, south lane 4, north lane 1, north lane 2, north lane 3, and north lane 4 according to the above execution process.

[0090] Step 208: Update the initial road structure dataset based on the reference driving trajectory set and each lane to obtain the road structure dataset.

[0091] In practice, the computer equipment adds the reference driving trajectory set and each lane to the initial road structure dataset to obtain the road structure dataset.

[0092] In one exemplary embodiment, the computer device constructs a static simulation scenario based on a reference driving trajectory set, each lane, and an initial road structure dataset.

[0093] In this embodiment, the initial road structure dataset is preprocessed to obtain a reference driving trajectory set and each lane, which facilitates the subsequent extraction of vehicle travel intention features and offset features. Furthermore, the initial road result dataset is updated based on the reference driving trajectory set and each lane, making the intersection structure clearer and improving the accuracy of the road result dataset.

[0094] In one exemplary embodiment, the road structure dataset includes a set of reference driving trajectories, and the driving features include traffic intention features, interaction features, and offset features, such as... Figure 3 As shown, step 104 involves extracting the driving features of each vehicle passing through the intersection based on the road structure dataset and the traffic participant motion dataset, thus obtaining the vehicle's driving feature set. The specific processing steps for obtaining the road structure dataset of the intersection include steps 302 to 308. Wherein:

[0095] Step 302: For each vehicle's motion dataset, determine the motion dataset as the main motion dataset.

[0096] In implementation, the computer equipment designates the motion dataset for each vehicle as the master motion dataset. By designating the vehicle's motion dataset as the master motion dataset, it becomes possible to determine the vehicle's driving characteristics from the vehicle's perspective.

[0097] Step 304: Filter out each reference vehicle and each reference object that appears simultaneously with the vehicle in the traffic participant motion dataset, and determine the motion datasets of each reference vehicle and each reference object as each sub-motion dataset.

[0098] In implementation, the computer equipment determines the second time period of vehicle appearance and filters each reference vehicle and reference object within the second time period from among the traffic participants in the traffic participant motion dataset. Then, the computer equipment identifies the motion datasets of each reference lane and each reference object in the traffic participant motion dataset as sub-motion datasets. By filtering the reference vehicles and reference objects that appear simultaneously with the vehicle, the reference objects and reference vehicles that may interact with the vehicle are obtained.

[0099] In an exemplary embodiment, the computer device determines the start time of vehicle appearance and the end time of lane disappearance, and determines a second time period for vehicle appearance based on the start and end times. For example, if the start time of vehicle appearance is 16:24:41 on October 16, 2024, and the end time of lane disappearance is 16:25:56 on October 16, 2024, the computer device determines the period from 16:24:41 on October 16, 2024 to 16:25:56 on October 16, 2024 as the second time period for the vehicle, and filters each reference vehicle and each reference object within the second time period from each traffic parameter in the traffic participant motion dataset. The computer device then determines the motion datasets of each reference vehicle and each reference object as sub-motion datasets.

[0100] Step 306: Based on the traffic intention rules and the main motion dataset, extract the traffic intention features of the vehicle, and determine the reference driving trajectory corresponding to the traffic intention features in the reference driving trajectory set.

[0101] The main motion dataset contains the driving trajectories of vehicles passing through intersections. These trajectories include the vehicle's position at each acquisition time.

[0102] In implementation, the computer equipment determines the vehicle's entry and exit points at the intersection based on the driving trajectory in the main motion dataset. The entry point is the starting point for the vehicle to enter the intersection, and the exit point is the ending point for the vehicle to leave the intersection. The computer equipment determines the vehicle's primary and secondary travel intentions based on the relative directions between the entry and exit points. Then, the computer equipment determines the entry lane where the entry point is located and the exit lane where the exit point is located. Then, the computer equipment constructs the vehicle's tertiary travel intention based on the entry and exit lanes. The computer equipment constructs the vehicle's travel intention based on the primary, secondary, and tertiary travel intentions. Then, the computer equipment determines the reference driving trajectory corresponding to the tertiary travel intention from the reference driving trajectory set.

[0103] Specifically, Level 1 traffic intentions include left turn, straight ahead, and right turn. Level 2 traffic intentions refer to the vehicle's direction of travel, such as from east to west or from south to east. Level 3 traffic intentions refer to the vehicle's entry and exit lanes. The computer equipment determines the vehicle's entry and exit points within the driving trajectory. Then, based on the lane boundaries of each lane, the computer equipment determines the entry lane where the entry point is located and the exit lane where the exit point is located. Next, the computer equipment determines the vehicle's Level 1 and Level 2 traffic intentions based on the relative positions of the entry and exit lanes. The computer equipment then constructs the vehicle's Level 3 traffic intentions based on the entry and exit lanes.

[0104] For example, if the vehicle enters from lane 1 (East) and exits from lane 1 (West). The computer determines the vehicle's primary traffic intention as going straight and its secondary traffic intention as traveling from east to west. Then, the computer determines the vehicle's tertiary traffic intention as the lane from East to West. The computer then determines the vehicle's traffic intention based on the lanes from East to West and East to West. Finally, the computer determines a reference travel trajectory from East to West from the reference travel trajectory set.

[0105] Step 308: Extract the vehicle's interaction features and offset features based on the road structure dataset, reference driving trajectory, main motion dataset, and each secondary motion dataset, and construct the vehicle's driving feature set based on the travel intention features, interaction features, and offset features.

[0106] The road structure dataset includes boundary lines and stop lines.

[0107] In implementation, the computer equipment determines the vehicle's offset relative to the reference driving trajectory based on the stop line, the reference driving trajectory, and a subset of the main motion data, thus obtaining the vehicle's offset characteristics. Then, the computer equipment extracts the vehicle's interaction characteristics based on each boundary line, the main motion dataset, and each secondary motion dataset. Finally, the computer equipment constructs the vehicle's driving feature set based on the communication intent characteristics, interaction characteristics, offset characteristics, and vehicle attribute information.

[0108] In this embodiment, by extracting the vehicle's driving intention features, the vehicle's driving purpose is clarified. Furthermore, by extracting the vehicle's interaction features and offset features, the relationship between the vehicle's offset and the intersection environment is clarified, thus obtaining the vehicle's driving feature set during the driving process.

[0109] In one exemplary embodiment, the road structure dataset includes boundary lines and stop lines, and the main motion dataset includes a subset of main motion data at each acquisition time, such as... Figure 4 As shown, the specific processing steps in step 308, which involve extracting the vehicle's interaction and offset features based on the road structure dataset, reference driving trajectory, main motion dataset, and various secondary motion datasets, include steps 402 to 406. Among them:

[0110] Step 402: For each subset of main motion data, offset calculations are performed on the stop line, reference driving trajectory, and actual position data in the subset of main motion data according to the horizontal and vertical offset algorithms to obtain offset features.

[0111] The vehicle's trajectory is composed of the vehicle's actual position data at each acquisition time. The offset features include the offset direction, offset distance, and the distance between the vehicle and the stop line.

[0112] In implementation, for each subset of main motion data, the computer equipment calculates the offset between the reference driving trajectory and the actual position data using lateral and longitudinal offset algorithms to obtain the vehicle's offset direction and distance. Then, the computer equipment determines the distance between the vehicle and the stop line using a stop line offset algorithm. The computer equipment combines the distance between the vehicle and the stop line, the vehicle's offset direction, and the offset distance to obtain the vehicle's offset characteristics.

[0113] Specifically, the actual location data is point P. The computer equipment locates the point N closest to P based on vector operations. Specifically, the computer equipment uses the reference driving trajectory as the center line of the Frenet coordinate system and performs a coordinate transformation to obtain the transformed reference driving trajectory. The computer equipment connects point P to the starting point S of each segment on the reference driving trajectory, forming a vector. The computer device constructs a vector from two adjacent points S and E (start and end points) on the reference driving trajectory. vector Identify the local direction of the reference driving trajectory. The computer calculates the vector. exist The projection length is used to obtain the foot N of the perpendicular from point P to the reference trajectory segment. The formula for calculating the projection length is shown in formula (1):

[0114]

[0115] In formula (1) above, l is the projection length ratio, and · represents the vector dot product. It is a vector The modulus of the line segment is determined. The value of l is restricted to the range [0, 1] to ensure that point N falls on the line segment formed by S and E. Then, the computer device determines the point N closest to P based on a linear interpolation algorithm. The linear interpolation algorithm is shown in the following formula (2):

[0116]

[0117] In formula (2) above, N is the point closest to P. S is the starting point of each segment on the reference driving trajectory. For formula (1) l is the projection length ratio.

[0118] Then, the computer device performs a cross product calculation on the vectors to obtain the cross product result, and determines the vehicle's offset direction based on the sign of the cross product result. If the sign of the cross product result is positive, the computer device determines the vehicle's offset direction to the right. If the sign of the cross product result is negative, the computer device determines the vehicle's offset direction to the left. The cross product calculation is shown in the following formula (3):

[0119]

[0120] In the above formula (3), For vectors The modulus. `sign()` is the sign function, used to determine the sign of a number. For the above formula (1) For the above formula (1)

[0121] The computer equipment calculates the Euclidean distance between points P and N to obtain the lateral offset. The Euclidean distance calculation process is shown in the following formula (4):

[0122]

[0123] In the above formula (4), Let P be the x-coordinate. Let px be the ordinate of point P. Let px be the abscissa of point N. The x-coordinate and y-coordinate of N.

[0124] Then, the computer device calculates the distance d between point P and the stop line. lane The distance between point P and the stop line is shown in the following formula group (5):

[0125]

[0126] In the above formula group (5), flagfa l "se" indicates that the vehicle has not yet crossed the stop line or entered the intersection interaction area. "flagtr" indicates that the vehicle has not yet crossed the stop line or entered the intersection interaction area. ue This indicates that the vehicle has crossed the stop line and is located in the intersection interaction area. The distance between the actual location data and the stop line also characterizes the interaction between the vehicle and the traffic light phase.

[0127] Step 404: Determine the subset of sub-motion data corresponding to the subset of main motion data in each subset of sub-motion data dataset.

[0128] The sub-motion dataset contains subsets of sub-motion data.

[0129] In practice, for each sub-motion dataset, the computer equipment determines the sub-motion data subset at the acquisition time of the main motion data subset in the sub-motion dataset based on the acquisition time of the main motion data subset, thus obtaining each sub-motion data subset corresponding to the main motion data subset.

[0130] In one exemplary embodiment, the acquisition time of the primary motion data subset is 16:24:41 on October 16, 2024. For each secondary motion dataset, the computer device determines a secondary motion data subset within the secondary motion dataset that was acquired at 16:24:41 on October 16, 2024.

[0131] Step 406: Based on the interaction feature algorithm, feature extraction is performed on the main motion data subset, each secondary motion data subset, and each boundary line to obtain the vehicle's interaction features.

[0132] The primary motion data subset contains the vehicle's actual position data at the time of data acquisition. The secondary motion data subset contains the reference position data of the reference object or reference vehicle.

[0133] In implementation, the computer equipment constructs a circular radar sensing area centered on the actual location data. Based on the reference position data of each reference object, each reference vehicle, and the radar sensing area, the computer equipment filters for target reference objects and target reference vehicles. If neither a target reference object nor a target reference vehicle exists, the computer equipment determines the vehicle's interaction characteristics based on the boundary lines and the actual location data. If a target reference object, a target reference vehicle, or both exist simultaneously, the computer equipment determines the vehicle's interaction characteristics based on the reference position data of the target reference object, the reference position data of the target reference vehicle, and the actual location data.

[0134] Specifically, the computer equipment changes the states of other traffic participants to simulate vehicle perception. Specifically, the computer equipment establishes a circular radar perception area with the vehicle's actual position as the center and a preset radius. Then, the computer equipment divides the radar perception area into evenly distributed blocks along the left front of the vehicle's long axis in a counter-clockwise direction, resulting in individual perception areas. Each perception area is a sector with an interior angle of 10 degrees. The computer equipment determines the vehicle's interaction characteristics based on each perception area, the main motion data subset, each secondary motion data subset, and each boundary line. These interaction characteristics include two interaction variables: the interaction type of the object closest to the vehicle hit by the virtual laser. Secondly, the interaction distance between the object and the vehicle. Specifically, interaction types are divided into entity and non-entity. Entities are the target reference object or target reference vehicle. Non-entities are the environment, i.e., the boundary of the intersection.

[0135] For each reference object, the computer equipment determines whether it is located within the sensing area based on the reference object's reference position data and the sensing area. If the reference object is located within the sensing area, the computer equipment identifies it as a target reference object. For each reference vehicle, the computer equipment determines whether it is located within the sensing area based on the vehicle's reference position data and the sensing area. If the reference vehicle is located within the sensing area, the computer equipment identifies it as a target reference vehicle. If a target reference object or target reference vehicle exists, the computer equipment will... The value is set to 1. If no target reference object or target reference vehicle exists, the computer equipment will... The value is set to 0. When a target reference object or vehicle exists, the computer calculates the distance between each target reference object and vehicle, and the distance between each target reference vehicle and other vehicles. Then, the computer determines the closest distance among these distances as 0. If there is no target reference vehicle and no target reference object, the actual position data of the vehicle is used as the center, and the starting and ending angles of the radar scanning angle are determined according to the vehicle's orientation. Then, the computer device calculates the angle of each boundary point in the boundary point set relative to the vehicle for each boundary line. Before calculating the angle of the boundary point relative to the vehicle, the computer device transforms the coordinates of the boundary points to the vehicle coordinate system and calculates the angle. The angle calculation formula is shown in the following formula (6):

[0136]

[0137] In formula (6) above, (x c ,y c θ represents the vehicle's actual position data, i.e., its actual position coordinates. i Starting angle θs Or the ending angle θ e x i y i These are the coordinates of the boundary points.

[0138] Then, the computer device according to θ s and θ e The values ​​are used to construct angle conditions, and boundary points within a specified angle range are filtered based on these conditions. For boundary points that satisfy the angle conditions, the computer calculates the square of the Euclidean distance between the boundary point and the vehicle. The formula for calculating Euclidean distance is shown in formula (7) below:

[0139]

[0140] In formula (7) above, (x c ,y c (x) represents the vehicle's actual position data, i.e., its actual position coordinates. i y i The coordinates of the boundary points that meet the angle conditions are given. Then, the computer equipment determines the minimum distance among the distances between each boundary point and the vehicle, and sets the minimum distance as...

[0141] In this embodiment, by extracting the vehicle's offset features and interaction features, the relationship between the vehicle's location at each moment and its environment is clarified, which facilitates the subsequent construction of the vehicle's driving feature set based on the offset features and interaction features.

[0142] In one exemplary embodiment, the road structure dataset includes boundary lines and stop lines, and the main motion dataset includes a subset of main motion data at each acquisition time, such as... Figure 5 As shown, the specific processing steps for constructing the vehicle's driving feature set based on traffic intention features, interaction features, and offset features in step 308 include steps 502 to 504. Wherein:

[0143] Step 502: Construct a subset of driving features of the vehicle at the time of data collection based on each interaction feature, the offset feature corresponding to the interaction feature, and the travel intention feature.

[0144] In implementation, the computer equipment preprocesses each interaction feature, offset feature, and communication intent feature to obtain preprocessed interaction features, offset features, and travel intent features. Then, for each interaction feature, the computer equipment determines the corresponding offset feature based on the acquisition time of the interaction feature. Finally, the interaction feature, the corresponding offset feature, the vehicle's travel intent feature, and attribute information are used to construct a subset of the vehicle's driving features at the acquisition time.

[0145] Specifically, the vehicle's attribute information includes its width and length. The computer equipment encodes and normalizes each interaction feature, offset feature, and traffic intention feature using normalization and encoding algorithms. Simultaneously, the computer equipment normalizes the vehicle's attribute information using a normalization algorithm. Specifically, if the features (interaction features, offset features, and traffic intention features) are string data, the computer equipment encodes the features using a one-hot encoding algorithm to obtain the processed features. If the features are numerical data, the computer equipment normalizes the features using a Min-Max (Min-Max Normalization) algorithm to obtain the processed features. The computer equipment normalizes the attribute information using the Min-Max algorithm to obtain the processed attribute information. Then, for each interaction feature, the computer equipment determines the corresponding offset feature based on the acquisition time of the interaction feature. Then, the interaction feature, the corresponding offset feature, the vehicle's traffic intention feature, and the attribute information are used to construct a subset of the vehicle's driving features at the acquisition time. This subset of driving features ξ includes dir1, dir2, dir3, and d. lat d lon d lane Vehicle width l, vehicle length w, interactive features Where dir1 is the first traffic intent feature, dir2 is the second traffic intent feature, dir3 is the third traffic intent feature, and d lat For the offset direction, d lon d is the offset distance. lane The distance between the vehicle and the stop line. For interaction type, This represents the interaction distance.

[0146] Step 504: Construct the vehicle's driving feature set based on each subset of driving features.

[0147] In practice, computer equipment combines the various driving feature subsets into a vehicle driving feature set.

[0148] In this embodiment, a vehicle's posture feature set is constructed by using the vehicle's attribute information, traffic intention features, interaction features, and offset features. This clarifies the relationship between the vehicle's driving trajectory and its traffic intention features and interaction features, making it easier to determine the vehicle's predicted offset trajectory sequence set in the future.

[0149] In one exemplary embodiment, such as Figure 6 As shown, the specific processing steps for determining the predicted offset trajectory sequence set of the vehicle based on the driving feature set and the surrogate model in step 104 include steps 602 to 606. Wherein:

[0150] Step 602: Divide each subset of driving features in the driving feature set into each driving feature subset group.

[0151] In practice, the computer equipment sorts the driving feature subsets in the driving feature set according to the acquisition time from smallest to largest, obtaining a sequence of driving feature subsets. The computer equipment then divides the sequence of driving feature subsets according to preset values, obtaining groups of driving feature subsets.

[0152] In an exemplary embodiment, one acquisition time is one frame. The number of frames is 30. The computer device sorts the driving feature subsets in the driving feature set in ascending order of acquisition time to obtain a sequence of driving feature subsets. Then, the computer device divides the 30 driving feature subsets in the sequence of driving feature subsets into driving feature subset groups to obtain each driving feature subset group.

[0153] Step 604: Based on the surrogate model, perform prediction processing on each driving feature subset group to obtain the initial estimated offset trajectory sequence.

[0154] The proxy model is obtained by training the initial proxy model based on the sample feature set.

[0155] In practice, the computer equipment inputs each subset of driving features into the proxy model, and the proxy model performs prediction processing on the subset of driving features to obtain the initial estimated offset trajectory sequence.

[0156] In one exemplary embodiment, the driving feature subset group comprises a 30-frame driving feature subset. A computer device inputs the 30-frame driving feature subset into a proxy model, and the proxy model performs prediction processing on the 30-frame driving feature subset to obtain an initial predicted offset estimation sequence for the last 10 frames. Specifically, the proxy model includes a generator and a discriminator. The generator is an LSTM (Long Short-Term Memory) network with an attention mechanism, receiving a three-dimensional feature matrix with dimensions n, t, and m as input. The features received by the generator are the feature input dimensions of the proxy model, including: n is the number of traffic participants in the batch (driving feature subset group), is 1; t is the time frame of the training input; and m is the feature dimension. The discriminator is a feedforward neural network, receiving a feature input dimension of n, t+t. f n a , where t f For the features of traffic participants in the first 30 frames, n a The dimensions are the lateral and longitudinal offsets of traffic participants. The surrogate model is input with the d values ​​from the next 10 frames. lat d lon That is, the estimated offset direction and the estimated offset distance.

[0157] Step 606: Perform coordinate transformation on the initial estimated offset trajectory sequence to obtain the estimated offset trajectory sequence, and construct an estimated offset trajectory sequence set based on each estimated offset trajectory sequence.

[0158] In implementation, since the initial estimated offset sequence output by the surrogate model is in Frenet coordinates (a coordinate system used to describe the motion and position of an object on a curve), it is necessary to convert the initial estimated offset sequence into coordinate points in the real coordinate system through coordinate transformation. The computer device performs coordinate transformation on the initial estimated offset trajectory sequence according to a transformation algorithm to obtain the estimated offset trajectory sequence. Then, the computer device constructs a set of estimated offset trajectory sequences based on each estimated offset trajectory sequence. Among these, at trajectory point (S... ix S iy Under these conditions, the coordinate system transformation algorithm is shown in the following formula group (8):

[0159]

[0160] In the above formula (8), (S ix ,S iy (S) represents the trajectory point at the current time (current frame). (i+1)x S (i+1)y ) represents the trajectory point at the next moment. x and p y N represents the predicted trajectory points after coordinate transformation. x and N y d is the reference coordinate. lat To estimate the offset distance.

[0161] In this embodiment, a predicted offset trajectory sequence set for the vehicle is determined through a proxy model and a driving feature set, enabling dynamic adjustment of the vehicle's driving trajectory based on this sequence set. Furthermore, a dynamic simulation scenario can be obtained based on each offset trajectory sequence set, traffic participant motion dataset, and road structure dataset, improving the realism of the dynamic simulation scenario and expanding its applicability. Testing autonomous vehicles based on this dynamic simulation scenario allows for bidirectional avoidance between autonomous and manually driven vehicles, improving the accuracy of autonomous driving testing.

[0162] In one exemplary embodiment, before applying the proxy model, an initial proxy model needs to be trained based on a sample dataset to obtain the proxy model. For example... Figure 7 As shown, before step 102 is executed, the specific execution process of this scene construction method also includes:

[0163] Step 702: Obtain the sample dataset and road structure dataset of the intersection, and extract the sample driving features of each sample vehicle passing through the intersection based on the road structure dataset and sample dataset to obtain the sample driving feature set of the vehicle.

[0164] In implementation, the computer equipment acquires a sample dataset and a road structure dataset of the intersection. The sample dataset is the SinD dataset (Signalized Intersection Dataset, a drone aerial photography dataset focusing on urban signalized intersections), which contains motion datasets of each sample traffic participant. The sample traffic participants include sample vehicles and sample reference objects. The computer equipment extracts sample driving features for each sample vehicle passing through the intersection based on the road structure data and the sample dataset, obtaining a sample driving feature set. The extraction process of sample driving features is the same as the extraction process of driving features; the specific process is described in steps 302 to 308 above, and will not be repeated here in this embodiment.

[0165] In an optional embodiment, the computer device performs Monte Carlo sampling on the sample travel intention features in each sample driving feature set to obtain each lane and reference driving trajectory set of the intersection.

[0166] Step 704: Determine the driving feature subset group for each sample based on the driving feature set of each sample.

[0167] Each sample driving feature set contains a subset of driving features from each sample.

[0168] In implementation, the computer equipment will divide each sample driving feature set into an initial sample driving feature subset group according to a preset value. Then, according to a preset number of vehicles, the computer equipment will combine the initial sample driving feature subset groups of vehicles that appeared at similar times into a sample driving feature subset group.

[0169] In an exemplary embodiment, the computer device contains sample driving feature set A for vehicle A, sample driving feature set B for vehicle B, and sample driving feature set C for vehicle B. Sample driving feature set A includes sample driving feature subsets A1 to A90. Sample driving feature set B includes sample driving feature subsets B1 to B90. Sample driving feature set C includes sample driving feature subsets C1 to C90. The computer device divides sample driving feature set A into initial sample driving feature subset groups a1, a2, and a3 according to a preset value of 30. Initial sample driving feature subset group a1 includes sample driving feature subsets A1 to A30. Initial sample driving feature subset group a1 includes sample driving feature subsets A31 to A60. Initial sample driving feature subset group a1 includes sample driving feature subsets A61 to A90. Simultaneously, the computer equipment divides the sample driving feature set B into initial sample driving feature subsets b1, b2, and b3, and the sample driving feature set C into initial sample driving feature subsets c1, c2, and c3. According to a preset number of vehicles (3), the computer equipment combines the initial sample driving feature subsets a1, b1, and c1 into sample driving feature subset X. Simultaneously, the computer equipment combines the initial sample driving feature subsets a2, b2, and c2 into sample driving feature subset Y, and the initial sample driving feature subsets a3, b3, and c3 into sample driving feature subset Z.

[0170] Optionally, the number of vehicles can be set to, but is not limited to, 3, and the value can be set to, but is not limited to, 30. The number and value of vehicles are determined according to training requirements, and this application embodiment does not limit the number and value of vehicles.

[0171] Step 706: Train the initial proxy model based on the driving feature subsets of each sample to obtain the proxy model.

[0172] In this embodiment, the computer device inputs each sample driving feature subset into an initial surrogate model. The surrogate model then performs prediction processing on the sample driving feature subsets to obtain sample output results. The computer device calculates the loss value for each sample output result and its corresponding true result based on a preset loss function algorithm. The computer device then determines whether the loss value meets a preset training stopping condition. If the loss value meets the preset stopping condition, the computer device determines the initial surrogate model as the surrogate model. If the loss value does not meet the stopping condition, the computer device updates the parameters of the initial surrogate model based on the loss value and continues to execute the step of inputting each sample driving feature subset into the initial surrogate model until the loss value reaches the training stopping condition.

[0173] Specifically, the initial proxy model includes a generator and a discriminator. The computer device constructs a three-dimensional feature matrix of size n, t, m based on a subset of sample driving features, where n is the number of traffic participants in the subset, t is the time frame of the training input, and m is the feature dimension. The discriminator is a feedforward neural network that receives feature inputs of dimension n, t + t. f ,n a , where t f For the features of traffic participants in the first 30 frames, n a The dimensions are the lateral and longitudinal offsets of traffic participants.

[0174] The computer device inputs a three-dimensional feature matrix into the generator and discriminator. The generator outputs a sequence of predicted offset trajectories based on the input features. The discriminator provides a probability that the action in the three-dimensional feature matrix, i.e., the sequence of predicted offset trajectories, is "true". This probability is compared with the true value and scored to obtain a score. The loss for true and false actions is further calculated, which can be interpreted as: the discriminator can correctly identify "true" as "true", and the discriminator can identify "false" as "true". The optimizer is Adam. The generator network is an LSTM network, and the generator solution is shown in the following formula (9):

[0175] h t c t =LSTM(x t h t-1 c t-1 (9)

[0176] In the above formula (9), h t and c t Let x represent the hidden state and cell state at time step t, respectively. t The input features are at time step t. The attention weights are calculated through a new fully connected layer, which maps the LSTM output to a weight coefficient matrix. The weight coefficient matrix is ​​then normalized using a softmax function to ensure that the sum of all weights is 1. The attention weights are calculated using the following formula (10):

[0177]

[0178] In the above formula (10), w and b are the weights and biases of the fully connected layer, respectively, and α t These are the attention weights at time step t, seq l The feature sequence is defined. Losses include cross-entropy loss, discontinuity loss, and dissimilarity loss. The cross-entropy of the discriminator is shown in formula (11), and the cross-entropy of the generator is shown in formula (12).

[0179]

[0180] In formulas (11) and (12) above, N is the number of samples in the batch, and x i The input sequence is y. i It is a label, D(x) i ) is the discriminator network's response to the input sequence x. i The predicted probability. Wherein, G(z) i The generator is based on the state input z. i The generated sample, D(G(z) i The probability value predicted by the discriminator for the authenticity of the generated sample is denoted as ). The overall loss function is:

[0181]

[0182] In the above formula (13), For formula (11) For formula (12) coefficient λ C , λ S It is a weighting factor that balances the importance of the custom loss. Among them, and As shown in formulas (14) and (15) below:

[0183]

[0184] In formulas (14) and (15) above, Δtraj g This is the difference used to generate the offset sequence; θ is a set threshold used to evaluate whether the current difference value is acceptable; λ is a scaling factor to adjust the penalty sensitivity; γ and μ are the exponent and multiplier to adjust the penalty strength; traj g and traj e These are the generated offset sequence and the actual offset sequence, respectively. v is the weighting factor, and i is the count value calculated in the batch.

[0185] Based on the above loss function, the optimization function of the initial agent model is obtained. The computer device optimizes the model parameters of the initial dialing model based on the optimization function. The optimization function is shown in the following formula (16):

[0186]

[0187] In formula (16), traj represents the expected value; e x represents the trajectory derived from expert data. t p represents the input features of the generator G at time step t; daiaFor the true data distribution, p G (x) represents the output distribution of the generator G.

[0188] In this embodiment, a subset of driving features for each sample is determined using the sample dataset, and an initial surrogate model is trained based on the subset of driving features for each sample to obtain the surrogate model. This improves the accuracy of the surrogate model and, consequently, the accuracy of the predicted offset trajectory sequence set.

[0189] In one exemplary embodiment, Figure 8 This is an architectural diagram of a scene construction device in one embodiment. An architectural diagram of a scene construction device corresponding to a scene construction method is provided. The scene construction device includes a data and feature processing module, a proxy model construction module, and a scene generator. The data and feature processing module is used to extract sample driving features of each sample vehicle passing through the intersection based on a road structure dataset and a sample dataset, obtaining a sample driving feature set for the vehicle. The proxy model training module is used to train an initial proxy model based on each sample driving feature set, obtaining a proxy model. The scene generator model is used to acquire the road structure dataset and traffic participant motion dataset of the intersection; the traffic participant motion dataset contains the motion datasets of each vehicle and each reference object passing through the intersection; based on the road structure dataset and the traffic participant motion dataset, the driving features of each vehicle passing through the intersection are extracted, obtaining a vehicle driving feature set; and based on the driving feature set and the proxy model, a predicted offset trajectory sequence set for the vehicle is determined; the predicted offset trajectory sequence set is used to dynamically adjust the vehicle's driving trajectory; based on each predicted offset trajectory sequence set, the traffic participant motion dataset, and the road structure dataset, a dynamic simulation scene of the intersection is obtained. By modeling and reconstructing the behavioral decisions of traffic participants, the deviation trajectory sequence is predicted, and the predicted deviation trajectory sequence is added as a dynamic element to the simulation scenario, ensuring the realism and interactive complexity of the test scenario. Figure 9 This is a schematic diagram of a vehicle trajectory in a static simulation scene and a vehicle trajectory in a dynamic simulation scene, as shown in one embodiment. Figure 9 (a) Schematic diagram of vehicle trajectory in static simulation scenario. Figure 9 (b) Schematic diagram of vehicle trajectory in dynamic simulation scenario.

[0190] In one exemplary embodiment, Figure 10 This is a schematic diagram of the training module architecture in one embodiment. Figure 10As shown, the upper layer is the feature processing stage. The construction idea of ​​the traffic participant agent model is derived from the way human drivers travel at intersections, which involves the following assumptions: drivers will not arbitrarily change their direction of travel when crossing an intersection; under different directions of travel, drivers will try to travel along the expected trajectory in that direction unless other vehicles interfere with their own vehicle; when drivers perceive other vehicles in the same direction, they only pay attention to the closest other vehicle and react accordingly. Based on the above assumptions, in the feature processing stage, this application designs the following... Figure 10 The driving feature set shown includes attributes, temporal features, and perception features including perception type and distance. After encoding, normalizing, batch processing, and sequence extraction of the extracted features, all rounds, scene file fragments, batches, and time frames are sequentially traversed. The lower layer is the training implementation process, including generator network design, discriminator network design, loss design, and training. The initial agent model contains a generator (LSTM) and a discriminator (feedforward network). The computer device inputs a 3D feature matrix to the generator and discriminator. The generator outputs a sequence of predicted offset trajectories based on the input features. The discriminator provides a probability that the action in the 3D feature matrix, i.e., the sequence of predicted offset trajectories, is "true." This probability is compared with the true value, and the discriminator is scored to obtain a score. The losses for true and false actions are further calculated, and the generator is optimized based on the losses and the optimizer.

[0191] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.

[0192] Based on the same inventive concept, this application also provides a scene construction apparatus for implementing the scene construction method described above. The solution provided by this apparatus is similar to the implementation scheme described in the above method; therefore, the specific limitations in one or more scene construction apparatus embodiments provided below can be found in the limitations of the scene construction method described above, and will not be repeated here.

[0193] In one exemplary embodiment, such as Figure 11As shown, a scene construction device 1100 is provided, including: an acquisition module 1101, an extraction module 1102, and a combination module 1103, wherein:

[0194] The acquisition module 1101 is used to acquire the road structure dataset and traffic participant motion dataset of the intersection; the traffic participant motion dataset contains the motion dataset of each vehicle and each reference object passing through the intersection.

[0195] The extraction module 1102 is used to extract the driving features of each vehicle passing through the intersection based on the road structure dataset and the traffic participant motion dataset, to obtain the driving feature set of the vehicle, and to determine the predicted offset trajectory sequence set of the vehicle based on the driving feature set and the surrogate model; the predicted offset trajectory sequence set is used to dynamically adjust the vehicle's driving trajectory.

[0196] The combined module 1103 is used to obtain a dynamic simulation scene of the intersection based on each predicted offset trajectory sequence set, traffic participant motion dataset, and road structure dataset.

[0197] In one exemplary embodiment, the acquisition module 1101 includes a first acquisition submodule and a second acquisition submodule. The first acquisition submodule includes:

[0198] The third acquisition submodule is used to acquire the initial road structure dataset of the intersection; the initial road structure dataset contains the lane lines and boundary lines of the intersection.

[0199] The first determination submodule is used to determine each lane of the intersection based on each lane line and each boundary line, and to mark each lane.

[0200] The first submodule is used to traverse each lane, establish a reference driving trajectory between the lane and other lanes, and obtain a set of reference driving trajectories.

[0201] The first update submodule is used to update the initial road structure dataset based on the reference driving trajectory set and each lane, thus obtaining the road structure dataset.

[0202] In an exemplary embodiment, the road structure dataset includes a reference driving trajectory set, and the driving features include traffic intention features, interaction features, and offset features. The extraction module 1102 includes a first extraction submodule and a second determination submodule. The first extraction submodule includes:

[0203] The second determination submodule is used to determine the motion dataset as the main motion dataset for each vehicle's motion dataset.

[0204] The first filtering submodule is used to filter each reference vehicle and each reference object that appears simultaneously with the vehicle in the traffic participant motion dataset, and to determine the motion datasets of each reference vehicle and each reference object as each sub-motion dataset.

[0205] The second extraction submodule is used to extract the traffic intention features of vehicles based on the traffic intention rules and the main motion dataset, and to determine the reference driving trajectory corresponding to the traffic intention features in the reference driving trajectory set.

[0206] The third extraction submodule is used to extract the vehicle's interaction features and offset features based on the road structure dataset, reference driving trajectory, main motion dataset, and various secondary motion datasets, and to construct the vehicle's driving feature set based on the traffic intention features, interaction features, and offset features.

[0207] In an exemplary embodiment, the road structure dataset includes boundary lines and stop lines, the main motion dataset includes subsets of main motion data at each acquisition time, and the third extraction submodule includes a fourth extraction submodule and a first construction submodule. The fourth extraction submodule includes:

[0208] The first calculation submodule is used to perform offset calculations on the stop line, reference driving trajectory, and actual position data in the main motion data subset according to the horizontal and vertical offset algorithms for each main motion data subset, so as to obtain the offset features.

[0209] The third determination submodule is used to determine the sub-motion data subset corresponding to the primary motion data subset in each sub-motion dataset.

[0210] The fifth extraction submodule is used to extract features from the main motion data subset, each secondary motion data subset, and each boundary line based on the interaction feature algorithm, so as to obtain the vehicle's interaction features.

[0211] In one exemplary embodiment, the third extraction submodule includes a fourth extraction submodule and a first construction submodule. The first construction submodule includes:

[0212] The second construction submodule is used to construct a subset of driving features of the vehicle at the time of collection based on each interaction feature, the offset feature corresponding to the interaction feature, and the traffic intention feature.

[0213] The third construction submodule is used to construct the vehicle's driving feature set based on each subset of driving features.

[0214] In an exemplary embodiment, the road structure dataset includes a reference driving trajectory set, and the driving features include traffic intention features, interaction features, and offset features. The extraction module 1102 includes a first extraction submodule and a second determination submodule. The second determination submodule includes:

[0215] The partitioning module is used to divide each subset of driving features in the driving feature set into different driving feature subset groups.

[0216] The first processing submodule is used to perform prediction processing on each subset of driving features based on the surrogate model to obtain an initial estimated offset trajectory sequence.

[0217] The second processing submodule is used to perform coordinate transformation on the initial estimated offset trajectory sequence to obtain the estimated offset trajectory sequence, and to construct an estimated offset trajectory sequence set based on each estimated offset trajectory sequence.

[0218] Each module in the aforementioned scene construction device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device, or stored in the memory of a computer device as software, so that the processor can call and execute the operations corresponding to each module.

[0219] In one exemplary embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 12 As shown, the computer device includes a processor, memory, input / output interfaces, a communication interface, a display unit, and an input device. The processor, memory, and input / output interfaces are connected via a system bus, and the communication interface, display unit, and input device are also connected to the system bus via the input / output interfaces. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The input / output interfaces are used for exchanging information between the processor and external devices. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, mobile cellular networks, Near Field Communication (NFC), or other technologies. When the computer program is executed by the processor, it implements a scene construction method. The display unit is used to form a visually visible image and can be a display screen, a projection device, or a virtual reality imaging device. The display screen can be an LCD screen or an e-ink screen. The input device of the computer device can be a touch layer covering the display screen, or buttons, trackballs, or touchpads set on the casing of the computer device, or external keyboards, touchpads, or mice, etc.

[0220] Those skilled in the art will understand that Figure 12The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0221] In one embodiment, a computer device is also provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps in the above method embodiments.

[0222] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon that, when executed by a processor, implements the steps in the above method embodiments.

[0223] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps in the above method embodiments.

[0224] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, artificial intelligence (AI) processors, etc., and are not limited to these.

[0225] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.

[0226] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.

Claims

1. A scene construction method, characterized in that, The method includes: Obtain the road structure dataset and traffic participant motion dataset of the intersection; the traffic participant motion dataset includes the motion datasets of each vehicle and each reference object passing through the intersection; Based on the road structure dataset and the traffic participant motion dataset, driving features of each vehicle passing through the intersection are extracted to obtain the vehicle's driving feature set. Based on the driving feature set and the surrogate model, a predicted offset trajectory sequence set for the vehicle is determined. The predicted offset trajectory sequence set is used to dynamically adjust the vehicle's driving trajectory. The driving feature set includes traffic intention features, offset features, and interaction features. The traffic intention features characterize the traffic participant's direction of travel. The interaction features are the interaction features between the traffic participant and a reference object or other vehicles or the intersection environment. The offset features are the amount of offset between the vehicle's driving trajectory and the reference driving trajectory. The traffic intention features include three levels of traffic intention. The reference driving trajectory is obtained by connecting the center lines of the entering lane and the exit lane in the three levels of traffic intention. The offset features include the distance between the vehicle and the stop line, the offset direction of the vehicle, and the offset distance; the offset direction is based on a vector. , and The result of the cross product of the vectors is determined; for The point and the starting point of each segment on the reference driving trajectory Obtained by connection; Points represent the actual location data in the vehicle's trajectory; vectors represent the actual location data in the vehicle's trajectory. Based on two adjacent points on the reference driving trajectory and Founded; This refers to the endpoint of each segment on the reference driving trajectory; For point The offset distance, at the foot of the perpendicular on the reference trajectory segment, is relative to the point. and points Obtained by Euclidean distance calculation; The interaction features include the interaction type with the nearest object to the vehicle. and the interaction distance between the object and the vehicle The interaction types are divided into entity and non-entity; entity refers to the target reference object or target reference vehicle; non-entity refers to the environment, i.e., the boundary of the intersection. Based on the predicted offset trajectory sequence sets, the traffic participant motion dataset, and the road structure dataset, a dynamic simulation scenario of the intersection is obtained; the predicted offset estimation sequence sets are used in the dynamic simulation scenario to adjust the trajectory of the target vehicle to avoid the autonomous vehicle when the driving trajectories of the autonomous vehicle and the target vehicle among the traffic participants conflict.

2. The method according to claim 1, characterized in that, The process of obtaining the road structure dataset for the intersection includes: Obtain the initial road structure dataset of the intersection; the initial road structure dataset includes the lane lines and boundary lines of the intersection; Each lane of the intersection is determined based on each of the lane lines and each of the boundary lines, and each of the lanes is marked. Traverse each lane and establish a reference driving trajectory between the lane and other lanes, starting from the lane, to obtain a set of reference driving trajectories; The initial road structure dataset is updated based on the reference driving trajectory set and each of the lanes to obtain the road structure dataset.

3. The method according to claim 1, characterized in that, The road structure dataset contains a reference driving trajectory set. The driving features of each vehicle passing through the intersection are extracted based on the road structure dataset and the traffic participant motion dataset to obtain the vehicle's driving feature set, including: For each of the aforementioned vehicles, the motion dataset is determined as the main motion dataset. In the traffic participant motion dataset, each reference vehicle and each reference object that appears simultaneously with the vehicle is filtered out, and the motion datasets of each reference vehicle and each reference object are determined as each sub-motion dataset; Based on the traffic intention rules and the main motion dataset, the traffic intention features of the vehicle are extracted, and the reference driving trajectory corresponding to the traffic intention features is determined in the reference driving trajectory set. Based on the road structure dataset, the reference driving trajectory, the main motion dataset, and each of the secondary motion datasets, the interaction features and offset features of the vehicle are extracted, and the driving feature set of the vehicle is constructed based on the traffic intention features, the interaction features, and the offset features.

4. The method according to claim 3, characterized in that, The road structure dataset includes boundary lines and stop lines, and the main motion dataset includes subsets of main motion data at each acquisition time. The step of extracting the vehicle's interaction features and offset features based on the road structure dataset, the reference driving trajectory, the main motion dataset, and each of the sub-motion datasets includes: For each subset of the main motion data, offset operations are performed on the stop line, the reference driving trajectory, and the actual position data in the subset of the main motion data according to the horizontal and vertical offset algorithms to obtain offset features; In each of the sub-motion datasets, determine the sub-motion data subset corresponding to the primary motion data subset; Based on the interaction feature algorithm, features are extracted from the main motion data subset, each of the secondary motion data subsets, and each boundary line to obtain the interaction features of the vehicle.

5. The method according to claim 4, characterized in that, The step of constructing the vehicle's driving feature set based on the travel intention feature, the interaction feature, and the offset feature includes: Based on each of the interaction features, the offset features corresponding to the interaction features, and the travel intention features, a subset of the vehicle's driving features at the time of data collection is constructed. The driving feature set of the vehicle is constructed based on each of the aforementioned driving feature subsets.

6. The method according to claim 1, characterized in that, The step of determining the predicted offset trajectory sequence set of the vehicle based on the driving feature set and the surrogate model includes: Each subset of driving features in the driving feature set is divided into a driving feature subset group; Based on the surrogate model, each of the aforementioned driving feature subsets is predicted to obtain an initial estimated offset trajectory sequence. The initial estimated offset trajectory sequence is subjected to coordinate transformation to obtain an estimated offset trajectory sequence, and an estimated offset trajectory sequence set is constructed based on each of the estimated offset trajectory sequences.

7. A scene construction device, characterized in that, The device includes: The acquisition module is used to acquire the road structure dataset and traffic participant motion dataset of the intersection; the traffic participant motion dataset includes the motion datasets of each vehicle and each reference object passing through the intersection; An extraction module is used to extract driving features of each vehicle passing through the intersection based on the road structure dataset and the traffic participant motion dataset, obtaining a driving feature set of the vehicle, and determining a predicted offset trajectory sequence set of the vehicle based on the driving feature set and the surrogate model; the predicted offset trajectory sequence set is used to dynamically adjust the vehicle's driving trajectory; the driving feature set includes traffic intention features, offset features, and interaction features; the traffic intention features represent the traffic participant's direction of travel; the interaction features are the interaction features between the traffic participant and a reference object or other vehicles or the intersection environment; the offset features are the offset of the vehicle's driving trajectory relative to the reference driving trajectory; The traffic intention feature includes three levels of traffic intention; the reference driving trajectory is obtained by connecting the center lines of the entering lane and the exit lane in the three levels of traffic intention. The offset features include the distance between the vehicle and the stop line, the offset direction of the vehicle, and the offset distance; the offset direction is based on a vector. , and The result of the cross product of the vectors is determined; for The point and the starting point of each segment on the reference driving trajectory Obtained by connection; Points represent the actual location data in the vehicle's trajectory; vectors represent the actual location data in the vehicle's trajectory. Based on two adjacent points on the reference driving trajectory and Founded; This refers to the endpoint of each segment on the reference driving trajectory; For point The offset distance, at the foot of the perpendicular on the reference trajectory segment, is relative to the point. and points Obtained by Euclidean distance calculation; The interaction features include the interaction type with the nearest object to the vehicle. and the interaction distance between the object and the vehicle The interaction types are divided into entity and non-entity; entity refers to the target reference object or target reference vehicle; non-entity refers to the environment, i.e., the boundary of the intersection. The combination module is used to obtain a dynamic simulation scenario of the intersection based on the predicted offset trajectory sequence sets, the traffic participant motion dataset, and the road structure dataset; the predicted offset estimation sequence sets are used to adjust the driving trajectory of the target vehicle in the dynamic simulation scenario when the driving trajectories of the autonomous vehicle and the target vehicle among the traffic participants conflict, so as to avoid the autonomous vehicle.

8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 6.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.

10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.