A test method and device for urban intersection unmanned vehicle passing decision
By constructing a simulation environment and kinematic modeling of a four-way, two-lane urban intersection, and randomly generating information on oncoming vehicles, combined with bicycle and intelligent driver models, the problem of the disconnect between the simulation environment and the real-world scenario in existing technologies is solved, and efficient training and verification of unmanned vehicle traffic decisions is achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- ADVANCED TECH RES INST OF BEIJING UNIV OF TECH
- Filing Date
- 2026-05-22
- Publication Date
- 2026-07-31
AI Technical Summary
Existing technologies struggle to construct a simulation testing environment that can realistically simulate the diverse interactive behaviors of drivers on actual roads while achieving efficient closed-loop training with relatively low computing power. This results in a disconnect between the simulation environment and real-world scenarios, leading to low training efficiency and insufficient generalization ability of the decision-making model.
A simulation environment for a four-way, two-lane urban intersection is constructed. The number, location, and driver type of oncoming vehicles are randomly generated. A kinematic modeling method combining a bicycle model and an intelligent driver model is used to generate environmental vehicle state information, which is then input into the unmanned vehicle traffic decision model to output acceleration control quantity. Traffic result data is collected for comprehensive scoring.
It improves the adaptability and robustness of the autonomous vehicle traffic decision model in real-world scenarios, ensuring traffic safety and efficiency, reducing computational complexity, and enabling efficient training and validation under low computing power conditions.
Smart Images

Figure CN122242304B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of autonomous driving testing technology, and in particular to a testing method and equipment for driverless vehicle traffic decision-making at urban intersections. Background Technology
[0002] With the deepening development of autonomous driving technology, the decision-making ability of driverless vehicles in complex traffic scenarios has become a key research direction. Left-turn scenarios at intersections, due to their complex dynamic interactions and concentrated risk factors, have become a significant challenge for the deployment of autonomous driving systems. In this scenario, vehicles not only need to accurately understand their own state but also need to perceive the behavioral intentions of surrounding traffic participants in real time and make safe and efficient decisions. However, existing methods often fail to realistically reproduce the complexity of interactions and the randomness of behavior in actual driving during training, resulting in insufficient adaptability and robustness of the trained decision-making models, thus affecting their safety and traffic efficiency in real-world scenarios.
[0003] Existing training methods can be broadly categorized into two types: real-data training and simulation environment training. Real-data training primarily imitates expert trajectories through imitation learning, but this method suffers from several problems: First, it can only produce suboptimal behavior and cannot surpass the limitations of expert trajectories; second, it exhibits a long-tail effect, making it difficult to cover rare but dangerous edge scenarios in real-world roads; third, the inability to interact with surrounding vehicles prevents closed-loop training, resulting in poor model performance in dynamic interactive scenarios. Simulation environment training constructs virtual scenarios, but existing simulation methods have the following issues: First, insufficient scenario adaptability, with overly idealized modeling of surrounding drivers, typically employing simple rule-based models (such as constant speed driving and fixed trajectories), failing to fit the complex decision-making behaviors of drivers in real-world road interactions; second, achieving high-precision simulations often requires significant computing power, making efficient training and testing difficult under resource-constrained conditions; third, the lack of diversity in the behavior of oncoming vehicles in existing simulation environments makes it impossible to realistically simulate the impact of different driving styles (aggressive, cautious, calm) on left-turning vehicle decisions.
[0004] In summary, the core technical problem faced by existing technologies is: how to construct a simulation testing environment that can realistically simulate the diverse interactive behaviors of drivers on actual roads and achieve efficient closed-loop training with low computing power, thereby solving the technical problems of existing methods such as the disconnect between the simulation environment and the real-world scenario, low training efficiency, and insufficient generalization ability of decision-making models. Summary of the Invention
[0005] To address the aforementioned technical issues, this invention proposes a testing method and device for unmanned vehicle traffic decision-making at urban intersections. By constructing a simulation environment that closely resembles real-world left-turn scenarios, the behavior of surrounding drivers is accurately modeled. This enables effective training and testing of the unmanned vehicle traffic decision-making model with relatively low computing power, improving the adaptability and robustness of the decision-making model in real-world scenarios and ensuring traffic safety and efficiency.
[0006] To achieve the above objectives, the present invention adopts the following technical solution: In a first aspect, this invention proposes a testing method for driverless vehicle traffic decision-making at urban intersections, comprising the following steps: A simulation environment for a four-way, two-lane urban intersection was constructed, and the reference trajectory of the left-turning vehicle was set as a fixed path consisting of an entrance straight segment, a circular arc segment, and an exit straight segment connected in sequence. In the simulation environment, the number of vehicles in the oncoming lane is randomly generated, and the initial position, initial speed and driving intention are randomly generated for each oncoming vehicle; and the driver type is randomly assigned to each oncoming vehicle. According to the driver type, the corresponding decision logic is invoked, and combined with the preset kinematic model, the acceleration control quantity of each oncoming vehicle is calculated. The position and speed of each oncoming vehicle in the simulation environment are updated according to the acceleration control quantity, and the state information of the environmental vehicles is generated. The state information includes the current position and current speed of each oncoming vehicle. The state information is input into the autonomous vehicle traffic decision model to be tested, and the autonomous vehicle traffic decision model outputs the acceleration control quantity of the left-turning vehicle; the position and speed of the left-turning vehicle in the simulation environment are updated according to the acceleration control quantity of the left-turning vehicle; the traffic result data of the left-turning vehicle in the simulation environment are collected, and a comprehensive score is calculated according to the traffic result data to evaluate or optimize the decision model.
[0007] Furthermore, driver types are randomly assigned to each oncoming vehicle, specifically as follows: Each oncoming vehicle is randomly assigned a driver type from a preset set of driver types, which include aggressive, cautious, and calm types.
[0008] Furthermore, the corresponding decision logic is invoked based on the driver type, specifically as follows: When the driver type is aggressive, the aggressive decision logic is invoked. The aggressive decision logic is: oncoming vehicles ignore the existence of the left-turning vehicle and decide whether to pass based only on the safe distance from the vehicle in front. When the driver type is cautious, the cautious decision logic is invoked. The cautious decision logic is as follows: the oncoming vehicle calculates the distance between the vehicle and the collision point and the vehicle's current speed, and determines whether it can stop completely before the collision point. If so, it slows down and yields to the left-turning vehicle; otherwise, it proceeds directly. When the driver type is calm, the calm decision logic is invoked. The calm decision logic is as follows: the oncoming vehicle calculates the first time when it arrives at the conflict point and the second time when the left-turning vehicle arrives at the conflict point. If the first time is later than the second time, the vehicle yields to the left-turning vehicle; otherwise, it proceeds directly.
[0009] Furthermore, based on the driver type, the corresponding decision logic is invoked, and combined with a preset kinematic model, the acceleration control quantity for each oncoming vehicle is calculated. Based on the acceleration control quantity, the position and velocity of each oncoming vehicle in the simulation environment are updated, generating the environmental vehicle state information; specifically: Based on the driver type, the corresponding decision logic is invoked to determine the target behavior of oncoming vehicles, including yielding or proceeding. Determine the target speed or target deceleration of the oncoming vehicle based on the target behavior; The target vehicle speed or target deceleration is input into a preset kinematic model to calculate the acceleration control amount for oncoming vehicles; Based on the acceleration control quantity, the position coordinates and velocity vector of the oncoming vehicle in the simulation environment are updated using the bicycle model; Collect the updated current position and speed of each oncoming vehicle to generate environmental vehicle status information.
[0010] Furthermore, the preset kinematic model adopts an intelligent driver model as the vehicle longitudinal motion control model; In the intelligent driver model: The acceleration of the lead car is expressed as: ; in, Indicates the acceleration of the lead vehicle; This indicates the vehicle's maximum acceleration. Indicates the current vehicle speed. Indicates the target vehicle speed. Indicates the acceleration index; The deceleration of the lead car is expressed as: ; in, This indicates the deceleration of the lead vehicle; Indicates the vehicle's maximum deceleration rate; Indicates the vehicle's current location; Indicates the safe distance for interaction; The acceleration of a following vehicle is expressed as: ; in, Indicates the acceleration of a following vehicle; Indicates the safe following distance.
[0011] Furthermore, the interaction safety distance Represented as:
[0012] safe following distance Represented as: ; in, Indicates the distance to congestion; Indicates a safe time interval; This indicates the relative speed difference between the vehicle and the interacting vehicle.
[0013] Furthermore, based on the acceleration control quantity, the position coordinates and velocity vector of the oncoming vehicle in the simulation environment are updated using the bicycle model, specifically as follows: Get the current speed of oncoming vehicles. Current heading angle Wheelbase and front wheel cornering ; According to the acceleration control amount Update the speed of oncoming vehicles, specifically: ; in, Indicates the updated speed; The acceleration control quantity calculated for the intelligent driver model, wherein the intelligent driver model includes: For the lead car, its acceleration control quantity For the lead car, its deceleration control amount For vehicles following the car, the acceleration control amount ; Indicates the simulation time step; Based on the updated speed Update the position coordinates and heading angle of the oncoming vehicle according to the following kinematic equations:
[0014] in, This indicates the current centroid coordinates of the vehicle.
[0015] Furthermore, the state information is input into the autonomous vehicle traffic decision model to be tested, and the autonomous vehicle traffic decision model outputs the acceleration control quantity of the left-turning vehicle; the position and velocity of the left-turning vehicle in the simulation environment are updated according to the acceleration control quantity of the left-turning vehicle, specifically as follows: Obtain the status information of the vehicles in the environment, including the current position and current speed of each oncoming vehicle; The state information is input into the autonomous vehicle traffic decision model to be tested, and the decision model outputs the longitudinal acceleration control quantity of the left-turning autonomous vehicle. ; Based on the current speed of the left-turning vehicle and the longitudinal acceleration control amount Update the speed of the left-turning vehicle according to the following formula: ; Based on the updated speed Update the position coordinates of the left-turning vehicle in the simulation environment: ; in, This indicates the current centroid coordinates of the vehicle turning left; This indicates the current heading angle of the vehicle turning left.
[0016] Furthermore, the traffic result data includes the collision situation between the left-turning vehicle and the oncoming vehicle, the average traffic speed of the left-turning vehicle, and the driving comfort of the left-turning vehicle. The comprehensive score is obtained by weighting the collision situation, average traffic speed, and driving comfort.
[0017] Secondly, this invention proposes a testing device for autonomous vehicle traffic decision-making at urban intersections, comprising: At least one processor; A memory communicatively connected to the processor, the memory storing a computer program; When the computer program is executed by the at least one processor, it implements the test method for making unmanned vehicle passage decisions at urban intersections.
[0018] The effects described in the invention are merely those of the embodiments, and not all the effects of the invention. One of the above technical solutions has the following advantages or beneficial effects: This invention proposes a testing method and device for autonomous vehicle traffic decision-making at urban intersections, belonging to the field of autonomous driving testing technology. The method includes: constructing a four-way, two-lane urban intersection simulation environment; setting the reference trajectory of a left-turning vehicle as a fixed path formed by sequentially connecting an entrance straight segment, a circular arc segment, and an exit straight segment; randomly generating the number of vehicles in the oncoming lanes within the simulation environment, and randomly generating an initial position, initial speed, and driving intention for each oncoming vehicle; randomly assigning a driver type to each oncoming vehicle; and calling the corresponding decision logic based on the driver type, and combining it with a preset kinematic model to calculate the traffic flow for each oncoming vehicle. The system generates environmental vehicle state information, including the current position and speed of each oncoming vehicle, by controlling the acceleration of approaching vehicles and updating the position and speed of each oncoming vehicle in the simulation environment. This state information is then input into the autonomous vehicle traffic decision model under test, which outputs the acceleration control of the left-turning vehicle. The left-turning vehicle's position and speed in the simulation environment are updated based on this acceleration control. Traffic result data of the left-turning vehicle in the simulation environment is collected, and a comprehensive score is calculated based on this data to evaluate or optimize the decision model. Based on this method, a corresponding device is also proposed. This invention constructs a complete test closed loop from simulation environment construction, vehicle parameter generation, decision logic invocation, kinematic model calculation to comprehensive score calculation, providing a complete technical solution for the training and testing of left-turn traffic decisions for autonomous vehicles at unsignalized intersections.
[0019] This invention models the behavior of drivers in surrounding vehicles, categorizing oncoming vehicles into three types: aggressive, cautious, and calm, and defining corresponding decision-making logic for each. This approach better fits the driving behavior of drivers on real roads, making the simulation environment more closely resemble real traffic scenarios. Furthermore, this invention employs a kinematic modeling method combining a bicycle model and an intelligent driver model. While maintaining simulation accuracy, this significantly reduces computational complexity, enabling the training and validation of decision-making models for unprotected left turns at intersections with lower computational power.
[0020] This invention, by randomly generating the number, position, speed, and driver type of oncoming vehicles, can cover a variety of complex traffic scenarios. Experimental verification shows that the decision model trained in this invention, when tested in a driver-in-the-loop simulation on the Carla-ROS2 platform, achieved a 100% success rate in 100 repetitions. Tests revealed that the trained decision model not only performs well with a high number of oncoming vehicles in the training environment, but also ensures traffic safety and efficiency even with fewer oncoming vehicles. Attached Figure Description
[0021] Figure 1This is a flowchart of a test method for making decisions on the passage of unmanned vehicles at urban intersections, as proposed in Embodiment 1 of the present invention. Figure 2 This is an architecture diagram of a test method for making traffic decisions for unmanned vehicles at urban intersections, as proposed in Embodiment 1 of the present invention. Figure 3 This is a schematic diagram of a four-way two-lane intersection scenario constructed according to Embodiment 1 of the present invention; Figure 4 This is a schematic diagram of a test device for making decisions on unmanned vehicle passage at urban intersections, as proposed in Embodiment 2 of the present invention. Detailed Implementation
[0022] To clearly illustrate the technical features of this solution, the invention will be described in detail below through specific embodiments and in conjunction with the accompanying drawings. The following disclosure provides many different embodiments or examples for implementing different structures of the invention. To simplify the disclosure of the invention, components and arrangements of specific examples are described below. Furthermore, reference numerals and / or letters may be repeated in different examples. This repetition is for simplification and clarity and does not in itself indicate a relationship between the various embodiments and / or arrangements discussed. It should be noted that the components illustrated in the drawings are not necessarily drawn to scale. Descriptions of well-known components, processing techniques, and processes are omitted in this invention to avoid unnecessarily limiting the invention.
[0023] Example 1 Embodiment 1 of this invention proposes a testing method for autonomous vehicle traffic decision-making at urban intersections. This method addresses the challenges in existing technologies for constructing a simulation testing environment that can realistically simulate the diverse interactive behaviors of drivers on actual roads while achieving efficient closed-loop training with low computing power. This solves the technical problems of existing methods, such as the disconnect between the simulation environment and the real-world scenario, low training efficiency, and insufficient generalization ability of the decision model.
[0024] Figure 1 This is a flowchart of a test method for making unmanned vehicle traffic decisions at urban intersections, as proposed in Embodiment 1 of the present invention. Figure 2 This is an architecture diagram of a testing method for unmanned vehicle traffic decision-making at urban intersections proposed in Embodiment 1 of the present invention; combined with Figure 1 and Figure 2 The process of implementing this invention will be explained together.
[0025] In step S1, a simulation environment for a four-way two-lane urban intersection is constructed, and the reference trajectory of the left-turning vehicle is set as a fixed path consisting of an entrance straight segment, a circular arc segment, and an exit straight segment connected in sequence.
[0026] Figure 3This is a schematic diagram of a four-way two-lane intersection scenario constructed according to Embodiment 1 of the present invention; in the diagram, Ego represents the vehicular vehicle, and Other represents oncoming vehicles. The left-turn trajectory consists of three segments: the entrance segment straight ahead (ab), the left-turn semicircle (bc) (radius R), and the exit segment straight ahead (cd). Green represents the driving trajectory of oncoming straight-going vehicles, and black represents the possible trajectory of oncoming vehicles with uncertain intentions.
[0027] The complex traffic environment in this application is characterized by: the left-turning vehicle needs to interact with many vehicles, the driving intention of oncoming vehicles is uncertain, and the type of oncoming vehicle drivers is uncertain.
[0028] In step S2, the number of vehicles in the oncoming lane is randomly generated in the simulation environment, and an initial position, initial speed and driving intention are randomly generated for each oncoming vehicle; and a driver type is randomly assigned to each oncoming vehicle. The number of vehicles in the oncoming lane is randomly generated, ranging from 1 to 5. For each oncoming vehicle, the initial position, initial speed, and driving intention are randomly generated. The initial position is randomly generated according to a preset position range, the initial speed is randomly generated according to a preset speed range, and the driving intention is randomly set to go straight or turn right. The probability of vehicles in the oncoming left lane turning right is 50%, and the probability of going straight is 50%.
[0029] A driver type is randomly assigned to each oncoming vehicle. Specifically, a driver type is randomly assigned to each oncoming vehicle from the preset driver types. The driver types include Aggressive, Careful, and Calm.
[0030] The behavior of an aggressive driver is: regardless of the behavior of the vehicle making a left turn, oncoming vehicles will pass directly while maintaining a safe distance from the vehicle in front; The behavior of a cautious driver is as follows: when an oncoming vehicle notices a vehicle turning left and intends to turn left, if it can stop before the point of collision, it will slow down and give way to the vehicle turning left; otherwise, it will proceed directly. The behavior of a calm driver is as follows: when an oncoming vehicle notices a left-turning vehicle expressing its intention to turn left, the oncoming vehicle decides whether to slow down and give way based on the time it takes to reach the conflict point P / Q. If the oncoming vehicle arrives at the conflict point after the left-turning vehicle, it will give way to the left-turning vehicle.
[0031] In this invention, vehicles in the oncoming lanes include vehicles in the right lane and vehicles in the left lane. Vehicles in the right lane are numbered S1, S2, and S3 according to their distance from the left-turning vehicle, and are used to test the traffic efficiency of the autonomous vehicle's traffic decision-making model in complex scenarios, verifying the model's human-like interaction capabilities. Vehicles in the left lane are numbered S4 and S5 according to their distance from the left-turning vehicle, and are used to test the model's ability to recognize complex traffic situations, verifying the model's human-like attention capabilities. The specific parameter value ranges for S1, S2, S3, S4, and S5 are shown in Table 1.
[0032] Table 1: Parameters of Oncoming Vehicles
[0033] in, , , , , This represents the initial longitudinal position coordinates of vehicles S1, S2, S3, S4, and S5. , , , , Table 1 shows the initial speeds of vehicles S1, S2, S3, S4, and S5. As can be seen from Table 1, the initial positions of vehicles S1, S2, and S3 in the right lane increase sequentially, while their initial speeds decrease sequentially; similarly, the initial positions of vehicles S4 and S5 in the left lane increase sequentially, while their initial speeds decrease sequentially.
[0034] In step S3, the corresponding decision logic is invoked according to the driver type, and the acceleration control quantity of each oncoming vehicle is calculated in combination with the preset kinematic model. The position and speed of each oncoming vehicle in the simulation environment are updated according to the acceleration control quantity, and the state information of the environmental vehicles is generated. The state information includes the current position and current speed of each oncoming vehicle. Specifically, based on the driver type, the corresponding decision logic is invoked to determine the target behavior of oncoming vehicles, including yielding or proceeding. Determine the target speed or target deceleration of oncoming vehicles based on the target behavior; Input the target vehicle speed or target deceleration into the preset kinematic model to calculate the acceleration control amount for oncoming vehicles; Based on the acceleration control quantity, the position coordinates and velocity vector of the oncoming vehicle in the simulation environment are updated using the bicycle model; Collect the updated current position and speed of each oncoming vehicle to generate environmental vehicle status information.
[0035] In this step, the corresponding decision logic is invoked based on the driver type, specifically as follows: When the driver type is aggressive, the aggressive decision logic is invoked. The aggressive decision logic is: oncoming vehicles ignore the existence of the left-turning vehicle and decide whether to pass based only on the safe distance from the vehicle in front. When the driver type is cautious, the cautious decision logic is invoked. The cautious decision logic is as follows: the oncoming vehicle calculates the distance between the vehicle and the collision point and the vehicle's current speed, and determines whether it can stop completely before the collision point. If so, it slows down and yields to the left-turning vehicle; otherwise, it proceeds directly. When the driver type is calm, the calm decision logic is invoked. The calm decision logic is as follows: the oncoming vehicle calculates the first time when it arrives at the conflict point and the second time when the left-turning vehicle arrives at the conflict point. If the first time is later than the second time, the vehicle yields to the left-turning vehicle; otherwise, it proceeds directly.
[0036] The preset kinematic model uses an intelligent driver model as the vehicle's longitudinal motion control model; In the intelligent driver model: The acceleration of the lead car is expressed as: ; in, Indicates the acceleration of the lead vehicle; This indicates the vehicle's maximum acceleration. Indicates the current vehicle speed. Indicates the target vehicle speed. Indicates the acceleration index; The deceleration of the lead car is expressed as: ; in, This indicates the deceleration of the lead vehicle; Indicates the vehicle's maximum deceleration rate; Indicates the vehicle's current location; Indicates the safe distance for interaction; The acceleration of a following vehicle is expressed as: ; in, Indicates the acceleration of a following vehicle; Indicates the safe following distance.
[0037] Interaction safety distance Represented as:
[0038] safe following distance Represented as: ; in, Indicates the distance to congestion; Indicates a safe time interval; This indicates the relative speed difference between the vehicle and the interacting vehicle.
[0039] The main parameter values of the above kinematic model are shown in Table 2.
[0040] Table 2: Kinematic Model Parameters of Surrounding Vehicles
[0041] In step S4, the state information is input into the autonomous vehicle traffic decision model to be tested, and the autonomous vehicle traffic decision model outputs the acceleration control quantity of the left-turning vehicle; the position and velocity of the left-turning vehicle in the simulation environment are updated according to the acceleration control quantity of the left-turning vehicle; specifically: Obtain the status information of the vehicles in the environment, including the current position and current speed of each oncoming vehicle; The state information is input into the autonomous vehicle traffic decision model under test, and the decision model outputs the longitudinal acceleration control quantity of the left-turning autonomous vehicle. ; Based on the current speed of the left-turning vehicle and the longitudinal acceleration control amount Update the speed of the left-turning vehicle according to the following formula: ; Based on the updated speed Update the position coordinates of the left-turning vehicle in the simulation environment: ; in, This indicates the current centroid coordinates of the vehicle turning left; This indicates the current heading angle of the vehicle turning left.
[0042] In this invention, the autonomous vehicle traffic decision model is preferably a deep reinforcement learning model, whose input is the state information of the environment and vehicle, and whose output is the longitudinal acceleration control quantity of the left-turning autonomous vehicle.
[0043] In step S5, traffic result data of left-turning vehicles in the simulation environment is collected, and a comprehensive score is calculated based on the traffic result data to evaluate or optimize the decision model.
[0044] The traffic data includes collision scenarios between left-turning vehicles and oncoming vehicles, the average speed of left-turning vehicles, and the driving comfort of left-turning vehicles. The comprehensive score is obtained by weighting the collision scenarios, average speed, and driving comfort. In this embodiment, the weight of the collision scenarios is 0.5, the weight of the average speed is 0.3, and the weight of the driving comfort is 0.2.
[0045] The comprehensive score calculated is used to evaluate or optimize the decision model. If the preset training or testing termination condition is not met, the process returns to step S3 to continue to the next simulation step; if the termination condition is met, the process ends and the evaluation result is output.
[0046] The simulation frequency of the simulation environment and the policy output frequency of the autonomous vehicle traffic decision model are set according to a preset ratio, and the speed limit of the left-turning vehicle is limited according to a preset threshold. For example, the simulation frequency is set to 10Hz, the policy output frequency of the autonomous vehicle traffic decision model is set to 5Hz, and the speed limit of the left-turning vehicle is set to 8m / s.
[0047] The present invention, in embodiment 1, proposes a testing method for autonomous vehicle traffic decision-making at urban intersections. By modeling the behavior model of surrounding vehicle drivers and the kinematic model of surrounding vehicles, a training / testing environment for autonomous vehicles at unsignalized intersections is built. This method can better fit the actual driving behavior of drivers on real roads and can better train / verify traffic decision-making in unprotected left-turn scenarios at cross intersections with low computing power.
[0048] The decision-making model trained in this invention is validated through a driver-in-the-loop experiment on the Carla-ROS2 simulation platform. Specifically, an experimental scenario is built using the Carla simulation platform. The driver manipulates the Logitech G29 steering wheel and pedals, inputting steering angle, accelerator, and brake signals into the Carla environment via ROS2 communication, controlling the vehicle to pass through an unsignalized intersection. For left-turning vehicles, the model calculates the control input based on the state space input and inputs it into the Carla environment to control the left-turning vehicle.
[0049] The driver-in-the-loop experiment was repeated 100 times, with a 100% success rate each time. The test showed that the trained decision-making model not only made good decisions with the number of oncoming vehicles in the training environment, but also ensured traffic safety and efficiency when the number of oncoming vehicles was lower.
[0050] Example 2 The present invention also proposes a device, Figure 4 This is a schematic diagram of a test device for making decisions on unmanned vehicle passage at urban intersections, as proposed in Embodiment 2 of the present invention.
[0051] At the hardware level, the electronic device 400 includes a processor 410, and optionally, an internal bus 420, a network interface 430, and memory. The memory may include main memory, such as high-speed random-access memory (RAM), or it may also include non-volatile memory, such as at least one disk storage device. Of course, the electronic device may also include other hardware required for its functions. The processor 410, network interface 430, and memory can be interconnected via an internal bus 420. This internal bus 420 can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. The bus can be categorized as an address bus, data bus, control bus, etc. For ease of illustration, only a single bidirectional arrow is used in this diagram, but this does not imply that there is only one bus or one type of bus. The memory is used to store programs. Specifically, the program can include program code, which includes computer operation instructions. The memory can include main memory 440 and non-volatile memory 450, and provides instructions and data to the processor 410. Processor 410 reads the corresponding computer program from non-volatile memory 450 into memory 440 and then runs it, forming a device for locating the target user at the logical level. Processor 410 executes the program stored in memory and specifically performs the following: In step S1, a simulation environment for a four-way two-lane urban intersection is constructed, and the reference trajectory of the left-turning vehicle is set as a fixed path consisting of an entrance straight segment, a circular arc segment, and an exit straight segment connected in sequence.
[0052] In step S2, the number of vehicles in the oncoming lane is randomly generated in the simulation environment, and an initial position, initial speed and driving intention are randomly generated for each oncoming vehicle; and a driver type is randomly assigned to each oncoming vehicle. In step S3, the corresponding decision logic is invoked according to the driver type, and the acceleration control quantity of each oncoming vehicle is calculated in combination with the preset kinematic model. The position and speed of each oncoming vehicle in the simulation environment are updated according to the acceleration control quantity, and the state information of the environmental vehicles is generated. The state information includes the current position and current speed of each oncoming vehicle. In step S4, the state information is input into the autonomous vehicle traffic decision model to be tested, and the autonomous vehicle traffic decision model outputs the acceleration control quantity of the left-turning vehicle; the position and speed of the left-turning vehicle in the simulation environment are updated according to the acceleration control quantity of the left-turning vehicle. In step S5, traffic result data of left-turning vehicles in the simulation environment is collected, and a comprehensive score is calculated based on the traffic result data to evaluate or optimize the decision model.
[0053] The comprehensive score calculated is used to evaluate or optimize the decision model. If the preset training or testing termination condition is not met, the process returns to step S3 to continue to the next simulation step; if the termination condition is met, the process ends and the evaluation result is output.
[0054] Figure 1 It can be applied to processor 410, or implemented by processor 410. The processor may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by the integrated logic circuit in the processor or by instructions in the form of software. The processor mentioned above can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. It can implement or execute the various methods, steps, and logic block diagrams disclosed in the embodiments of this application. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in the embodiments of this application can be directly embodied as being executed by a hardware decoding processor, or executed by a combination of hardware and software modules in the decoding processor. The software module can reside in a mature storage medium in the field, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, or registers. This storage medium is located in memory, and the processor reads information from the memory and, in conjunction with its hardware, completes the steps of the above method. Of course, in addition to software implementation, the electronic device of this application does not exclude other implementation methods, such as logic devices or a combination of hardware and software, etc. In other words, the execution subject of the following processing flow is not limited to each logic unit, but can also be hardware or logic devices.
[0055] Example 3 The present invention also proposes a readable storage medium on which a computer program is stored, wherein the computer program, when executed by a processor, implements the following method steps: In step S1, a simulation environment for a four-way two-lane urban intersection is constructed, and the reference trajectory of the left-turning vehicle is set as a fixed path consisting of an entrance straight segment, a circular arc segment, and an exit straight segment connected in sequence.
[0056] In step S2, the number of vehicles in the oncoming lane is randomly generated in the simulation environment, and an initial position, initial speed and driving intention are randomly generated for each oncoming vehicle; and a driver type is randomly assigned to each oncoming vehicle. In step S3, the corresponding decision logic is invoked according to the driver type, and the acceleration control quantity of each oncoming vehicle is calculated in combination with the preset kinematic model. The position and speed of each oncoming vehicle in the simulation environment are updated according to the acceleration control quantity, and the state information of the environmental vehicles is generated. The state information includes the current position and current speed of each oncoming vehicle. In step S4, the state information is input into the autonomous vehicle traffic decision model to be tested, and the autonomous vehicle traffic decision model outputs the acceleration control quantity of the left-turning vehicle; the position and speed of the left-turning vehicle in the simulation environment are updated according to the acceleration control quantity of the left-turning vehicle. In step S5, traffic result data of left-turning vehicles in the simulation environment is collected, and a comprehensive score is calculated based on the traffic result data to evaluate or optimize the decision model.
[0057] The comprehensive score calculated is used to evaluate or optimize the decision model. If the preset training or testing termination condition is not met, the process returns to step S3 to continue to the next simulation step; if the termination condition is met, the process ends and the evaluation result is output.
[0058] This application also provides a storage medium, namely a computer storage medium, specifically a computer-readable storage medium, such as a memory that stores a computer program, which can be executed by a processor to complete the steps described in the aforementioned method. The computer-readable storage medium may be a memory such as FRAM, ROM, PROM, EPROM, EEPROM, Flash Memory, magnetic surface memory, optical disc, or CD-ROM.
[0059] Those skilled in the art will understand that all or part of the steps of the above method embodiments can be implemented by hardware related to program instructions. The aforementioned program can be stored in a computer-readable storage medium. When the program is executed, it performs the steps of the above method embodiments. The aforementioned storage medium includes various media capable of storing program code, such as mobile storage devices, ROM, RAM, magnetic disks, or optical disks. Alternatively, if the integrated units of this application are implemented as software functional modules and sold or used as independent products, they can also be stored in a computer-readable storage medium. Based on this understanding, the technical solutions of the embodiments of this application, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause an electronic device (which may be a personal computer, server, or network device, etc.) to execute all or part of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as mobile storage devices, ROM, RAM, magnetic disks, or optical disks.
[0060] The descriptions of relevant parts in the test equipment for unmanned vehicle traffic decision-making at urban intersections provided in Embodiment 2 of this application and the test storage medium for unmanned vehicle traffic decision-making at urban intersections provided in Embodiment 3 of this application can be found in the detailed description of the corresponding parts in the test method for unmanned vehicle traffic decision-making at urban intersections provided in Embodiment 1 of this application, and will not be repeated here.
[0061] It should be noted that, in this document, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that the elements inherent in a process, method, article, or apparatus that includes a list of elements are included. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element. Additionally, portions of the technical solutions provided in the embodiments of this application that are consistent with the implementation principles of corresponding technical solutions in the prior art have not been described in detail to avoid excessive elaboration.
[0062] While specific embodiments of the present invention have been described above in conjunction with the accompanying drawings, this is not intended to limit the scope of protection of the present invention. Those skilled in the art can make other modifications or variations based on the above description. It is neither necessary nor possible to exhaustively describe all embodiments here. Various modifications or variations that can be made by those skilled in the art without creative effort based on the technical solutions of the present invention are still within the scope of protection of the present invention.
Claims
1. A method for testing urban intersection unmanned vehicle passage decision, characterized in that, Includes the following steps: A simulation environment for a four-way, two-lane urban intersection was constructed, and the reference trajectory of the left-turning vehicle was set as a fixed path consisting of an entrance straight segment, a circular arc segment, and an exit straight segment connected in sequence. In the simulation environment, the number of vehicles in the oncoming lane is randomly generated, and the initial position, initial speed, and driving intention are randomly generated for each oncoming vehicle. And randomly assign driver type to each oncoming vehicle; According to the driver type, the corresponding decision logic is invoked, and combined with the preset kinematic model, the acceleration control quantity of each oncoming vehicle is calculated. The position and velocity of each oncoming vehicle in the simulation environment are updated according to the acceleration control quantity, and the environmental vehicle state information is generated. The state information includes the current position and current velocity of each oncoming vehicle. The preset kinematic model adopts the intelligent driver model as the vehicle longitudinal motion control model. In the intelligent driver model: The acceleration of the lead car is expressed as: ; in, Indicates the acceleration of the lead vehicle; This indicates the vehicle's maximum acceleration. Indicates the current vehicle speed. Indicates the target vehicle speed. Indicates the acceleration index; The deceleration of the lead car is expressed as: ; in, This indicates the deceleration of the lead vehicle; Indicates the vehicle's maximum deceleration rate; Indicates the vehicle's current location; Indicates the safe distance for interaction; The acceleration of a following vehicle is expressed as: ; wherein, denotes the acceleration of the following vehicle; denotes the following vehicle safety distance; Based on the acceleration control quantity, the position coordinates and velocity vector of the oncoming vehicle in the simulation environment are updated using the bicycle model, specifically as follows: acquiring a current speed of an oncoming vehicle , a current heading angle , a wheelbase , and a front wheel steering angle ; According to the acceleration control amount The speed of the oncoming vehicle is updated, specifically: ; wherein, denotes the updated speed; an acceleration control quantity calculated for the intelligent driver model, in which: for the lead vehicle, an acceleration control amount for the lead vehicle, a deceleration control amount for the follower vehicle, an acceleration control amount ; denotes a simulation time step; According to the updated speed The position coordinates and heading angle of the oncoming vehicle are updated according to the following kinematic equations: wherein, represents the current center of mass coordinate of the vehicle; The state information is input into the autonomous vehicle traffic decision model to be tested, and the autonomous vehicle traffic decision model outputs the acceleration control quantity of the left-turning vehicle; the position and speed of the left-turning vehicle in the simulation environment are updated according to the acceleration control quantity of the left-turning vehicle; the traffic result data of the left-turning vehicle in the simulation environment are collected, and a comprehensive score is calculated according to the traffic result data to evaluate or optimize the decision model.
2. The method of claim 1, wherein, Each oncoming vehicle is randomly assigned a driver type, specifically: Each oncoming vehicle is randomly assigned a driver type from a preset set of driver types, which include aggressive, cautious, and calm types.
3. The method of claim 2, wherein, The corresponding decision logic is invoked based on the driver type, specifically as follows: When the driver type is aggressive, the aggressive decision logic is invoked. The aggressive decision logic is: oncoming vehicles ignore the existence of the left-turning vehicle and decide whether to pass based only on the safe distance from the vehicle in front. When the driver type is cautious, the cautious decision logic is invoked. The cautious decision logic is as follows: the oncoming vehicle calculates the distance between the vehicle and the collision point and the vehicle's current speed, and determines whether it can stop completely before the collision point. If so, it slows down and yields to the left-turning vehicle; otherwise, it proceeds directly. When the driver type is calm, the calm decision logic is invoked. The calm decision logic is as follows: the oncoming vehicle calculates the first time when it arrives at the conflict point and the second time when the left-turning vehicle arrives at the conflict point. If the first time is later than the second time, the vehicle yields to the left-turning vehicle; otherwise, it proceeds directly.
4. The method of claim 1, wherein, According to the driver type, the corresponding decision logic is invoked, and combined with the preset kinematic model, the acceleration control quantity of each oncoming vehicle is calculated. The position and speed of each oncoming vehicle in the simulation environment are updated according to the acceleration control quantity, and the state information of the vehicles in the environment is generated. Specifically: Based on the driver type, the corresponding decision logic is invoked to determine the target behavior of oncoming vehicles, including yielding or proceeding. Determine the target speed or target deceleration of the oncoming vehicle based on the target behavior; The target vehicle speed or target deceleration is input into a preset kinematic model to calculate the acceleration control amount for oncoming vehicles; Based on the acceleration control quantity, the position coordinates and velocity vector of the oncoming vehicle in the simulation environment are updated using the bicycle model; Collect the updated current position and speed of each oncoming vehicle to generate environmental vehicle status information.
5. The testing method for unmanned vehicle traffic decision-making at urban intersections according to claim 1, characterized in that, The interaction safe distance is represented as: Car following safety distance is represented as: ; wherein, represents a congestion distance; represents a safety time interval; represents a relative speed difference between the host vehicle and the interacting vehicle.
6. The method of claim 5, wherein, The state information is input into the autonomous vehicle traffic decision model to be tested, and the autonomous vehicle traffic decision model outputs the acceleration control quantity of the left-turning vehicle; the position and velocity of the left-turning vehicle in the simulation environment are updated according to the acceleration control quantity of the left-turning vehicle, specifically as follows: Obtain the status information of the vehicles in the environment, including the current position and current speed of each oncoming vehicle; inputting the state information into a self-driving vehicle passing decision model to be tested, outputting a longitudinal acceleration control amount of the left-turning self-driving vehicle by the decision model ; According to the current speed of the left-turning ego vehicle and the longitudinal acceleration control amount , the speed of the left-turning ego vehicle is updated according to the following formula: ; According to the updated speed , update the position coordinates of the left-turn ego vehicle in the simulation environment: ; in, This indicates the current centroid coordinates of the vehicle turning left; This indicates the current heading angle of the vehicle turning left.
7. The testing method for unmanned vehicle traffic decision-making at urban intersections according to claim 1, characterized in that, The traffic results data include the collision situation between the left-turning vehicle and the oncoming vehicle, the average speed of the left-turning vehicle, and the driving comfort of the left-turning vehicle. The comprehensive score is obtained by weighting the collision situation, average speed, and driving comfort.
8. A testing device for unmanned vehicle traffic decision-making at urban intersections, characterized in that, include: At least one processor; A memory communicatively connected to the processor, the memory storing a computer program; When the computer program is executed by the at least one processor, it implements a test method for making unmanned vehicle traffic decisions at urban intersections as described in any one of claims 1 to 7.