A method for storing and updating multi-agent traffic simulation data

By adopting graph data structure and edge indexing technology in traffic simulation, the problem of inefficiency of simulation systems in large-scale traffic environments in the existing technology is solved, efficient microsimulation state storage and update are achieved, and the accuracy of vehicle collision warning is improved. Spend.

CN113392106BInactive Publication Date: 2025-01-07SOUTHEAST UNIV
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202110603441.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-05-31
Publication Date
2025-01-07
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

The existing traffic simulation software is too complex in large-scale traffic environments due to the storage method of single lane linked list, which cannot efficiently deal with the problem of vehicle lane change and vehicle interference, and the accuracy of vehicle movement model is not high, resulting in vehicle collision warning. Not very accurate.

Method used

The new traffic simulation space data structure is adopted, and nodes and edges are defined as simulated vehicle agents and vehicle interaction relationships. The whole-domain vehicle traversal is avoided through edge indexing, all simulation spaces are stored as graph data structures, and state updates are used using depth-first algorithms.

Benefits of technology

It improves the operating efficiency of microscopic simulation, reduces the repeated reading process of state updates, significantly optimizes the time complexity, and improves the operating efficiency of the simulation system and the accuracy of vehicle collision warning.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113392106B_ABST
    Figure CN113392106B_ABST
Patent Text Reader

Abstract

The present invention discloses a multi-agent traffic simulation data storage and update method, including: establishing corresponding vehicle agents for all vehicles; constructing a simulation space graph, each vehicle agent corresponds to a node in the simulation space graph; determining the connection correspondence between nodes, and completing the edge definition of the simulation space graph; combining the vehicle attribute information, vehicle following decision-making ability and vehicle lane-changing decision-making ability of each vehicle agent, using a depth-first algorithm to update the state of the vehicle agent corresponding to each node on the simulation space graph, and then updating the node corresponding to the connection edge of each node on the simulation space graph based on the vehicle agent position after the state update, to achieve data update of the simulation space graph until the simulation time ends. The present invention avoids the process of repeated reading during the state update process, thereby accelerating the storage and update of micro-simulation states from the perspective of data structure, and improving the operation efficiency of micro-simulation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of intelligent traffic simulation storage, and in particular to a multi-agent traffic simulation data storage and updating method and device, electronic equipment and computer-readable storage medium. Background Art

[0002] With the rapid development of the economy, the number of cars per capita has exploded, and the problem of urban traffic congestion has become increasingly prominent. Due to the complex composition and numerous individual traffic characteristics of urban traffic, it is difficult to complete the modeling of urban traffic systems through traditional aggregate methods. With the development of data science and the popularization of microcomputers, traffic simulation has gradually become an important tool for analyzing the characteristics of traffic systems. Through the non-aggregate simulation of the micro-operation process of individual traffic, the aggregate becomes the macro traffic indicator of the city, which can not only effectively simulate the expected traffic operation status under a given environment to find traffic jams in advance, but also can be used to screen planning schemes through intuitive simulation data comparison. Traffic simulation enables traffic schemes to be quantified and evaluated in a low-cost and efficient manner.

[0003] Micro traffic simulation is a non-aggregate simulation, which simulates the operation status of each individual vehicle, and the aggregate becomes the operation status of the entire traffic flow; however, due to the differences between each individual vehicle, its operation status decision cannot be simply judged using traditional mathematical models, so traffic simulation modeling in a multi-agent environment is born. By giving each vehicle agent the ability to make decisions, each vehicle agent has its own decision-making characteristics based on the traditional mathematical model, thereby achieving differential simulation.

[0004] After the introduction of vehicle agents, microscopic traffic simulation faces the problem of too much computational content in a single simulation step and high simulation system overhead due to the expansion of the simulation scope. Therefore, it is particularly important to design the storage and update structure of microscopic traffic simulation from the level of algorithms and data structures.

[0005] Existing traffic simulation software, including Paramics and VISSIM, all use a single-lane linked list to store vehicles. This method establishes an index for the vehicle sequence on each lane, which is easy to create and maintain, and performs well in traffic environments with small simulation scales and few road vehicles. However, as the simulation scale increases, this method will lose its efficiency advantage due to the high complexity of the algorithm for obtaining adjacent lane information. The invention patent with patent number 201910699018.8 discloses a neighboring vehicle query method, which mainly uses a multi-pointer linked list to avoid the problem of traversing the entire lane linked list to query adjacent lane information. In general, existing studies lack the necessity of designing data structures for storage and update of simulation space. They only design data structures for single lanes on road sections, ignoring the factors of mutual interference between road section lanes and the characteristics of vehicle autonomous decision-making, which will generate greater time complexity when facing a lane change situation. Similarly, the invention patent with patent number CN112436960A discloses a vehicle driving control method, terminal and computer-readable storage medium, which aims to solve the technical problem that the simulated vehicle movement model in the prior art is not accurate, resulting in low accuracy of vehicle collision warning; although the invention involves the driving data of the target vehicle, wherein the driving data includes at least one of the road information and vehicle information of the vehicle location, the constructed vehicle movement simulation model is based on the simulated vehicle information generated by the microscopic road simulator and at least one parameter in the simulated road information. Correction training is generated, first, it does not involve the vehicle's own lane-changing ability, and second, in the vehicle simulation process, once the vehicle status is updated, it is still necessary to read the data repeatedly, and the operation efficiency is not high. It can be seen that in order to meet the needs of large-scale microscopic simulation of traffic environments, it is urgent to design a data structure for efficient storage and update of the overall simulation space. Summary of the invention

[0006] In view of the deficiencies in the prior art, the present invention provides a method and device for storing and updating multi-agent traffic simulation data, which is oriented to the multi-agent simulation environment. While giving the simulated vehicle the ability to make autonomous decisions, it innovatively considers the similarities between the graph data structure and the microscopic simulation space, adopts a new traffic simulation space data structure, and defines nodes and edges as simulated vehicle agents and vehicle interaction relationships. In updating the relationship between the front and rear vehicles in adjacent lanes in a multi-lane scenario, the traversal of all vehicles in the entire domain is avoided by means of edge indexing; all simulation spaces are stored as a graph data structure, which avoids the process of repeated reading during the state update process, thereby accelerating the storage and update of microscopic simulation states from the perspective of data structure and improving the operating efficiency of microscopic simulations.

[0007] To achieve the above object, the present invention adopts the following technical solutions:

[0008] In a first aspect, an embodiment of the present invention provides a method for storing and updating multi-agent traffic simulation data, the method comprising:

[0009] S1, obtaining attribute information of all vehicles on the microscopic simulation road, the vehicle attribute information includes vehicle number, vehicle performance information and vehicle driving information;

[0010] S2, establish corresponding vehicle agents for all vehicles, each of which has corresponding vehicle attribute information, vehicle following decision-making capabilities and vehicle lane changing decision-making capabilities;

[0011] S3, construct a simulation space graph, each vehicle agent corresponds to a node in the simulation space graph, and complete the node definition of the simulation space graph;

[0012] S4, based on the intelligent microscopic lane-changing relationship of vehicles, determine the connection correspondence between nodes and complete the edge definition of the simulation space graph;

[0013] S5, combining the vehicle attribute information, vehicle following decision-making ability and vehicle lane changing decision-making ability of each vehicle agent, adopts the depth-first algorithm to update the state of the vehicle agent corresponding to each node on the simulation space graph, and then updates the node corresponding to the edge connecting each node on the simulation space graph based on the position of the vehicle agent after the state update, so as to realize the data update of the simulation space graph until the simulation time ends.

[0014] Optionally, in step S1, the vehicle number refers to the sequence number of the vehicle agents entering the simulation road section;

[0015] The vehicle performance information includes vehicle length, maximum acceleration and maximum deceleration;

[0016] The vehicle driving information includes the vehicle position, the vehicle current speed and the vehicle current acceleration; wherein the vehicle position refers to the relative starting position of the vehicle body along the driving direction of the simulated road section and the lane number in which it is located.

[0017] Optionally, in step S2, the vehicle following decision-making capability refers to integrating microscopic following information of surrounding vehicle agents fed back by the connected nodes, obtaining the current lane neighboring vehicle information required for following decision-making; and completing the update of its own microscopic following information through the IDM following model.

[0018] Optionally, in step S2, the vehicle lane-changing decision-making capability refers to integrating microscopic following information of surrounding vehicle agents fed back by connected nodes to obtain adjacent lane neighboring vehicle information required for following decision-making; and making its own microscopic lane-changing decision through a utility selection model to determine whether to change lanes.

[0019] Optionally, in step S4, based on the intelligent microscopic lane-changing relationship of the vehicle, the connection correspondence between the nodes is determined, and the process of completing the edge definition of the simulation space graph includes:

[0020] The vehicle agent represented by any node is regarded as a decision-making agent, and the corresponding information of the front vehicle in the current lane, the rear vehicle in the current lane, the front vehicle in the left lane, the rear vehicle in the left lane, the front vehicle in the right lane, and the rear vehicle in the right lane are obtained;

[0021] Among them, the front vehicle information of the current lane represents the vehicle intelligent entity information that is in the same lane as the decision-making intelligent entity, whose vehicle position is larger than the decision-making intelligent entity and is the nearest vehicle intelligent entity information; the rear vehicle information of the current lane represents the vehicle intelligent entity information that is in the same lane as the decision-making intelligent entity, whose vehicle position is smaller than the decision-making intelligent entity and is the nearest vehicle intelligent entity information; the front vehicle information of the left lane represents the vehicle intelligent entity information that is located in the left lane of the decision-making intelligent entity, whose vehicle position is larger than the decision-making intelligent entity and is the nearest vehicle intelligent entity information; the rear vehicle information of the left lane represents the vehicle intelligent entity information that is located in the left lane of the decision-making intelligent entity, whose vehicle position is smaller than the decision-making intelligent entity and is the nearest vehicle intelligent entity information; the front vehicle information of the right lane represents the vehicle intelligent entity information that is located in the right lane of the decision-making intelligent entity, whose vehicle position is larger than the decision-making intelligent entity and is the nearest vehicle intelligent entity information; the rear vehicle information of the right lane represents the vehicle intelligent entity information that is located in the right lane of the decision-making intelligent entity, whose vehicle position is smaller than the decision-making intelligent entity and is the nearest vehicle intelligent entity information.

[0022] Optionally, in step S5, the process of updating the state of the vehicle agent corresponding to each node on the simulation space graph using the depth-first algorithm includes:

[0023] The driving state of the vehicle body is determined by using the vehicle body micro-following information from the vehicle body connection node; the expected driving state of the vehicle body is calculated through the IDM following model; the lane changing demand of the vehicle body is calculated through the utility selection lane changing model; and the vehicle body state is updated based on the lane changing demand and the expected driving state.

[0024] Optionally, in step S5, the process of updating the node corresponding to each node connection edge on the simulation space graph based on the vehicle agent position after the state update to implement data update of the simulation space graph includes:

[0025] Compare the relative sizes of the vehicle positions of the current node's vehicle agent and the vehicle agent of the node to which the current node is connected, and determine whether the connected node needs to be changed;

[0026] For the node that needs to be changed, read the node it is connected to to determine the new node that needs to be connected;

[0027] Establish an edge between the new node and the current node, and update the node corresponding to the edge connecting each node on the graph.

[0028] In a second aspect, an embodiment of the present invention provides a multi-agent traffic simulation data storage and update device, the device comprising:

[0029] The vehicle attribute information acquisition module is used to acquire the attribute information of all vehicles on the microscopic simulation road, and the vehicle attribute information includes vehicle number, vehicle performance information and vehicle driving information;

[0030] The vehicle agent creation module is used to establish corresponding vehicle agents for all vehicles. Each vehicle agent has corresponding vehicle attribute information, vehicle following decision-making capabilities, and vehicle lane changing decision-making capabilities.

[0031] The node definition module is used to construct a simulation space graph. Each vehicle agent corresponds to a node in the simulation space graph, completing the node definition of the simulation space graph.

[0032] The edge definition module is used to determine the connection correspondence between nodes based on the intelligent microscopic lane-changing relationship of the vehicle, and complete the edge definition of the simulation space graph;

[0033] The simulation space graph update module is used to combine the vehicle attribute information, vehicle following decision-making ability and vehicle lane changing decision-making ability of each vehicle agent, and use the depth-first algorithm to update the state of the vehicle agent corresponding to each node on the simulation space graph. Then, based on the position of the vehicle agent after the state update, the node corresponding to the connection edge of each node on the simulation space graph is updated to realize the data update of the simulation space graph until the simulation time ends.

[0034] In a third aspect, an embodiment of the present invention proposes an electronic device, comprising: one or more processors; a storage device for storing one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the multi-agent traffic simulation data storage and update method as described above.

[0035] In a fourth aspect, an embodiment of the present invention proposes a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the multi-agent traffic simulation data storage and update method as described above.

[0036] The beneficial effects of the present invention are:

[0037] The present invention proposes a method for storing and updating multi-agent traffic simulation data, which is oriented to the multi-agent simulation environment. While giving the simulated vehicle autonomous decision-making capabilities, it innovatively considers the similarities between the graph data structure and the micro-simulation space, adopts a new traffic simulation space data structure, and defines nodes and edges as simulated vehicle agents and vehicle interaction relationships. In updating the relationship between the front and rear vehicles in adjacent lanes in a multi-lane scenario, the traversal of all vehicles in the entire domain is avoided by means of edge indexing; all simulation spaces are stored as a graph data structure, which avoids the process of repeated reading during the state update process, thereby accelerating the storage and update of micro-simulation states from the perspective of data structure and improving the operating efficiency of micro-simulation. BRIEF DESCRIPTION OF THE DRAWINGS

[0038] Figure 1 It is a flow chart of a method for storing and updating multi-agent traffic simulation data according to an embodiment of the present invention.

[0039] Figure 2 Schematic diagram of the vehicle state of vehicle 2 before changing lanes in the example.

[0040] Figure 3 It is a schematic diagram of the simulation space storage of vehicle 2 before changing lanes in the example.

[0041] Figure 4 Schematic diagram of the vehicle status of vehicle 2 after changing lanes in the example.

[0042] Figure 5 This is a schematic diagram of the simulation space storage of vehicle 2 after changing lanes in the example. DETAILED DESCRIPTION

[0043] The present invention will now be described in further detail with reference to the accompanying drawings.

[0044] It should be noted that the terms such as "upper", "lower", "left", "right", "front", "back", etc. cited in the invention are only for the convenience of description and are not used to limit the scope of implementation of the present invention. Changes or adjustments in their relative relationships should be regarded as the scope of implementation of the present invention without substantially changing the technical content.

[0045] Embodiment 1

[0046] Figure 1 The present invention is a flowchart of a method for storing and updating multi-agent traffic simulation data in accordance with an embodiment of the present invention. The present invention can be used in the case where multi-agent traffic simulation data storage and updating is realized through a server or other device. The method can be executed by a multi-agent traffic simulation data storage and updating device, which can be implemented in software and / or hardware and can be integrated in an electronic device, such as an integrated server device.

[0047] See also Figure 1, the storage and update method includes:

[0048] S1, obtaining the attribute information of all vehicles on the microscopic simulation road, the vehicle attribute information includes vehicle number, vehicle performance information and vehicle driving information.

[0049] In step S1, the vehicle number refers to the sequence number of the vehicle agent entering the simulated road section. Vehicle performance information includes vehicle length, maximum acceleration and maximum deceleration, etc. Vehicle driving information includes vehicle position, vehicle current speed and vehicle current acceleration, etc. Among them, the vehicle position refers to the relative starting position of the vehicle agent along the driving direction of the simulated road section and the lane number in which it is located. This embodiment introduces the lane number into the attribute setting of the vehicle agent, because multiple lanes are more in line with the actual road scene.

[0050] by Figure 2 For example, Figure 2 There is a one-way three-lane road section. There are currently nine vehicles numbered 0 to 8 on the road section. The numbering of these nine vehicles is the order in which they enter the road section from small to large. The driving direction is to drive to the right along the lane. For the convenience of description, the driving direction is defined as longitudinal, and the leftmost side of the road section is taken as the starting point, so that the vehicle positions are all positive values.

[0051] S2, establish corresponding vehicle agents for all vehicles, each of which has corresponding vehicle attribute information, vehicle following decision-making capabilities and vehicle lane changing decision-making capabilities.

[0052] In step S2, the vehicle following decision-making capability refers to the integration of the micro-following information of the surrounding vehicle agents fed back by the connected nodes, obtaining the information of the neighboring vehicles in the current lane required for the following decision-making; and completing the update of its own micro-following information through the IDM (Intelligent Driver Model) following model. The vehicle lane change decision-making capability refers to the integration of the micro-following information of the surrounding vehicle agents fed back by the connected nodes, obtaining the information of the neighboring vehicles in the adjacent lanes required for the following decision-making; and making its own micro-lane change decision through the utility selection model to determine whether to change lanes.

[0053] It should be understood that this is only one type of vehicle following decision-making capability and vehicle lane changing decision-making capability. For the data storage and updating method of this embodiment, other types of vehicle following or lane changing decisions can also be used. The purpose is only to judge the driving status of the vehicle intelligent body in the road section in real time, and then quickly realize the data update of the entire simulation space map according to the driving status.

[0054] S3, construct a simulation space graph, each vehicle agent corresponds to a node in the simulation space graph, and complete the node definition of the simulation space graph. For ease of presentation and viewing, the nodes can be arranged according to the relative positions of the actual vehicles.

[0055] S4, based on the intelligent microscopic following and lane changing relationship of the vehicle, determine the connection correspondence between the nodes and complete the edge definition of the simulation space graph.

[0056] Specifically, the edge definition process includes:

[0057] The vehicle agent represented by any node is regarded as a decision-making agent, and the corresponding information of the front vehicle in the current lane, the rear vehicle in the current lane, the front vehicle in the left lane, the rear vehicle in the left lane, the front vehicle in the right lane, and the rear vehicle in the right lane are obtained.

[0058] Among them, the front vehicle information of the current lane represents the vehicle intelligent entity information that is in the same lane as the decision-making intelligent entity, whose vehicle position is larger than the decision-making intelligent entity and is the nearest vehicle intelligent entity information; the rear vehicle information of the current lane represents the vehicle intelligent entity information that is in the same lane as the decision-making intelligent entity, whose vehicle position is smaller than the decision-making intelligent entity and is the nearest vehicle intelligent entity information; the front vehicle information of the left lane represents the vehicle intelligent entity information that is located in the left lane of the decision-making intelligent entity, whose vehicle position is larger than the decision-making intelligent entity and is the nearest vehicle intelligent entity information; the rear vehicle information of the left lane represents the vehicle intelligent entity information that is located in the left lane of the decision-making intelligent entity, whose vehicle position is smaller than the decision-making intelligent entity and is the nearest vehicle intelligent entity information; the front vehicle information of the right lane represents the vehicle intelligent entity information that is located in the right lane of the decision-making intelligent entity, whose vehicle position is larger than the decision-making intelligent entity and is the nearest vehicle intelligent entity information; the rear vehicle information of the right lane represents the vehicle intelligent entity information that is located in the right lane of the decision-making intelligent entity, whose vehicle position is smaller than the decision-making intelligent entity and is the nearest vehicle intelligent entity information.

[0059] As can be seen from the above, in this embodiment, the vehicle attributes of the vehicle agent include the lane number attribute, which is to highlight the multi-lane nature and make the simulation results closer to the actual road driving process. However, since the driving status of each vehicle on the road section is different, for example, some vehicles will change their relative positions in the longitudinal direction due to different driving speeds, and some vehicles will change lanes. If the total number of vehicles in the simulation space is n, the calculation complexity of the traditional simulation software is about O(2n) and O(nlogn) at each state update, and the operation efficiency is extremely low. To this end, this embodiment adopts a new traffic simulation space data structure, defines nodes and edges as simulated vehicle agents and vehicle interaction relationships, and avoids traversing all vehicles in the entire domain by edge indexing when updating the relationship between the front and rear vehicles in adjacent lanes in a multi-lane scenario; all simulation spaces are stored as a graph data structure, avoiding the process of repeated reading during the state update process, thereby accelerating the storage and update of micro-simulation states from the perspective of data structure, and improving the operation efficiency of micro-simulation. Taking the simulation space with a total number of n vehicles as an example, the time complexity of this embodiment is O(n), which is significantly optimized compared with traditional simulation software.

[0060] Likewise Figure 2 As an example, the abstract form of the created simulation space diagram is as follows Figure 3 As shown, it can be expressed in the form of an adjacency list as follows:

[0061]

[0062] The information of all vehicles at a certain moment is shown in Table 1.

[0063] Table 1 Summary of all vehicle information before vehicle 2 changes lanes

[0064]

[0065]

[0066] Among them, None means that the node is not connected to the corresponding position; 0, 1, 2, 3, 4, 5, 6, 7, 8 represent vehicle numbers; the vehicle position is calculated with the starting point of the road section along the driving direction as the zero point; the lanes are 0, 1, and 2 from the center line of the road from the inside to the outside.

[0067] S5, simulation space graph data update. Combined with the vehicle attribute information, vehicle following decision-making ability and vehicle lane changing decision-making ability of each vehicle agent, the depth-first algorithm is used to update the state of the vehicle agent corresponding to each node on the simulation space graph, and then the node corresponding to each node connection edge on the simulation space graph is updated based on the position of the vehicle agent after the state update, so as to realize the data update of the simulation space graph until the simulation time ends.

[0068] In one simulation step, the update process is as follows:

[0069] All vehicle agents in the simulation space graph are traversed by the depth-first algorithm, and the driving state of the vehicle agent is determined by using the microscopic following information of the vehicle agent from the node connected to the vehicle agent. The microscopic following state is updated using the IDM following model method inside the vehicle agent, and the microscopic lane-changing decision is made using the utility selection model method inside the vehicle agent to determine whether each vehicle needs to change lanes. After the position of the vehicle agent is updated, the node corresponding to each node connection edge on the simulation space graph is updated accordingly to realize the data update of the simulation space graph, which specifically includes: comparing the relative size of the vehicle position of the vehicle agent of the current node and the vehicle agent of the node connected to the current node to determine whether the connected node needs to be changed; for the node that needs to be changed, reading the node connected to it to determine the new node that needs to be connected; establishing an edge between the new node and the current node to realize the update of the node corresponding to each node connection edge on the graph. In the above steps, if the total number of vehicles in the simulation space is n, its time complexity is O(n).

[0070] Likewise Figure 2 As an example, after one simulation step, it is determined that vehicle 2 needs to change lanes from lane 0 to lane 1, that is, the scenario is changed from Figure 2 Transform to Figure 4 After the scene changes, the edges connecting the nodes need to be changed. Since vehicle 2 changes lanes to lane 1, the edges connecting the nodes of the surrounding vehicle agents need to be changed. The change method is:

[0071] First, the edge connected to vehicle 2 needs to be changed: the number of the vehicle behind the current lane connected to the front vehicle 1 in the current lane needs to inherit the number 3 of the vehicle behind the current lane of vehicle 2, the number of the vehicle in front of the current lane connected to the rear vehicle 1 in the current lane needs to inherit the number 1 of the vehicle in front of the current lane of vehicle 2, and the number of the vehicle in front of the left lane connected to the rear vehicle 0 in the right lane needs to inherit the number 1 of the vehicle in front of the current lane of vehicle 2.

[0072] The second new edge that needs to be changed is the edge connected to vehicle 2: its left lane front vehicle inherits the current lane front vehicle number 1 before the lane change, its left lane rear vehicle inherits the current lane rear vehicle number 3 before the lane change, its current lane front vehicle inherits the right lane front vehicle number 4 before the lane change, its current lane rear vehicle inherits the right lane rear vehicle number 0 before the lane change, its right lane front vehicle has a vehicle position greater than and closer to number 6 compared to the right lane rear vehicle 6 of the current lane front vehicle number 4 and the right lane front vehicle 7 of the current lane rear vehicle number 0, and is regarded as the right lane front vehicle; its right lane rear vehicle has a vehicle position less than and closer to number 6 compared to the right lane rear vehicle 6 of the current lane front vehicle number 4 and the right lane front vehicle 7 of the current lane rear vehicle number 0, and is regarded as the right lane front vehicle.

[0073] Third, a new edge connected to vehicle 2 needs to be added: vehicle number 1 compares the vehicle positions of the rear vehicle number 0 in the right lane and the vehicle number 2 in the changed lane, and selects vehicle number 2 as the rear vehicle in the right lane; vehicle number 6 compares the vehicle positions of the rear vehicle number 0 in the left lane and the vehicle number 2 in the changed lane, and selects vehicle number 2 as the rear vehicle in the left lane; vehicle number 7 compares the vehicle positions of the front vehicle number 4 in the left lane and the vehicle number 2 in the changed lane, and selects vehicle number 2 as the front vehicle in the left lane.

[0074] The abstract form of the changed simulation space diagram is as follows Figure 5 As shown, it can be expressed in the form of an adjacency list as follows:

[0075]

[0076] After the change Figure 4 The information of all vehicles in the described traffic scene is shown in Table 2.

[0077] Table 2 Summary of all vehicle information after vehicle 2 changes lanes

[0078] Vehicle number 0 1 2 3 4 5 6 7 8 Vehicle location 251 469 317 139 491 118 390 279 171 Lane 1 0 1 0 1 1 2 2 2 speed 20 19 16 20 21 18 19 19 20 Acceleration -1 0 -1 1 0 0 -1 0 -1 Left front vehicle number 1 None 1 None None 3 4 2 0 Left rear vehicle number 3 None 3 None 1 None 2 0 5 Front car number 2 None 4 1 None 0 None 6 7 Rear car number 5 3 0 None 2 None 7 8 None Right front vehicle number 7 4 6 0 None 8 None None None Right rear car number 8 None 7 5 6 None None None None

[0079] The multi-agent traffic simulation data storage and update method designed by the above technical solution is oriented to the multi-agent simulation environment. While giving the simulated vehicle the ability to make autonomous decisions, it innovatively considers the similarities between the graph data structure and the micro-simulation space, adopts a new traffic simulation space data structure, and defines nodes and edges as simulated vehicle agents and vehicle interaction relationships. In the multi-lane scenario, when updating the relationship between the front and rear vehicles in adjacent lanes, the traversal of all vehicles in the entire domain is avoided by means of edge indexing; all simulation spaces are stored as a graph data structure, avoiding the process of repeated reading during the state update process, thereby accelerating the storage and update of micro-simulation states from the perspective of data structure and improving the operating efficiency of micro-simulation.

[0080] Embodiment 2

[0081] An embodiment of the present invention proposes a multi-agent traffic simulation data storage and update device, which includes a vehicle attribute information acquisition module, a vehicle agent creation module, a node definition module, an edge definition module and a simulation space graph update module.

[0082] The vehicle attribute information acquisition module is used to obtain the attribute information of all vehicles on the microscopic simulation road. The vehicle attribute information includes vehicle number, vehicle performance information and vehicle driving information.

[0083] The vehicle agent creation module is used to establish corresponding vehicle agents for all vehicles. Each vehicle agent has corresponding vehicle attribute information, vehicle following decision-making capabilities and vehicle lane changing decision-making capabilities.

[0084] The node definition module is used to construct a simulation space graph. Each vehicle agent corresponds to a node in the simulation space graph, completing the node definition of the simulation space graph.

[0085] The edge definition module is used to determine the connection correspondence between nodes based on the vehicle's intelligent microscopic following and lane changing relationship, and complete the edge definition of the simulation space graph.

[0086] The simulation space graph update module is used to combine the vehicle attribute information, vehicle following decision-making ability and vehicle lane changing decision-making ability of each vehicle agent, and use the depth-first algorithm to update the state of the vehicle agent corresponding to each node on the simulation space graph. Then, based on the position of the vehicle agent after the state update, the node corresponding to the connection edge of each node on the simulation space graph is updated to realize the data update of the simulation space graph until the simulation time ends.

[0087] Through the multi-agent traffic simulation data storage and update device of the second embodiment of the present invention, the transmission object is determined by establishing the data inclusion relationship of the entire application, so as to achieve the goal of multi-agent traffic simulation data storage and update. The storage and update device provided by the embodiment of the present invention can execute the multi-agent traffic simulation data storage and update method provided by any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method.

[0088] Embodiment 3

[0089] An embodiment of the present application provides an electronic device, including a processor, a memory, an input device, and an output device; the number of processors in the electronic device can be one or more; the processor, memory, input device, and output device in the electronic device can be connected via a bus or other means.

[0090] The memory, as a computer-readable storage medium, can be used to store software programs, computer executable programs and modules, such as program instructions / modules corresponding to the detection method in the embodiment of the present invention. The processor executes various functional applications and data processing of the electronic device by running the software programs, instructions and modules stored in the memory, that is, the multi-agent traffic simulation data storage and update method provided in the embodiment of the present invention is realized.

[0091] The memory may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system and an application required for at least one function; the data storage area may store data created according to the use of the terminal, etc. In addition, the memory may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other non-volatile solid-state storage device. In some instances, the memory may further include a memory remotely arranged relative to the processor, and these remote memories may be connected to the electronic device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0092] The input device can be used to receive input digital or character information and generate key signal input related to user settings and function control of the electronic device, and can include a keyboard, a mouse, etc. The output device can include a display device such as a display screen.

[0093] Embodiment 4

[0094] An embodiment of the present application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the multi-agent traffic simulation data storage and update method as described above.

[0095] Of course, the storage medium containing computer executable instructions provided in an embodiment of the present invention is not limited to the method operations described above, and can also execute related operations in the multi-agent traffic simulation data storage and update method provided in any embodiment of the present invention.

[0096] The above are only preferred embodiments of the present invention, and the protection scope of the present invention is not limited to the above embodiments. All technical solutions under the concept of the present invention belong to the protection scope of the present invention. It should be pointed out that for ordinary technicians in this technical field, some improvements and modifications without departing from the principle of the present invention should be regarded as the protection scope of the present invention.

Claims

1. A method for storing and updating multi-agent traffic simulation data, characterized in that: The method comprises: S1, obtaining attribute information of all vehicles on the microscopic simulation road, the vehicle attribute information includes vehicle number, vehicle performance information and vehicle driving information; S2, establish corresponding vehicle agents for all vehicles, each of which has corresponding vehicle attribute information, vehicle following decision-making capabilities and vehicle lane changing decision-making capabilities; S3, construct a simulation space graph, each vehicle agent corresponds to a node in the simulation space graph, and complete the node definition of the simulation space graph; S4, based on the intelligent microscopic lane-changing relationship of vehicles, determine the connection correspondence between nodes and complete the edge definition of the simulation space graph; S5, combining the vehicle attribute information, vehicle following decision-making ability and vehicle lane changing decision-making ability of each vehicle agent, using the depth-first algorithm to update the state of the vehicle agent corresponding to each node on the simulation space graph, and then updating the node corresponding to each node connection edge on the simulation space graph based on the vehicle agent position after the state update, to achieve data update of the simulation space graph until the simulation time ends; In step S2, the vehicle following decision-making capability refers to integrating the microscopic following information of the surrounding vehicle agents fed back by the connected nodes, obtaining the current lane neighboring vehicle information required for the following decision-making, and completing the update of its own microscopic following information through the IDM following model; In step S2, the vehicle lane-changing decision-making capability refers to integrating the microscopic following information of surrounding vehicle agents fed back by the connected nodes, obtaining the information of neighboring vehicles in adjacent lanes required for following decision-making; and making its own microscopic lane-changing decision through the utility selection model to determine whether to change lanes; In step S5, the process of updating the state of the vehicle agent corresponding to each node on the simulation space graph using the depth-first algorithm includes: The driving state of the vehicle agent is determined by using the vehicle agent microscopic following information from the vehicle agent connection node; the expected driving state of the vehicle agent is calculated by the IDM following model; the lane changing demand of the vehicle agent is calculated by the utility selection lane changing model; the vehicle agent state is updated based on the lane changing demand and the expected driving state; In step S5, the process of updating the nodes corresponding to the edges connecting each node on the simulation space graph based on the vehicle agent position after the state update to update the data of the simulation space graph includes: Compare the relative sizes of the vehicle positions of the current node's vehicle agent and the vehicle agent of the node to which the current node is connected, and determine whether the connected node needs to be changed; For the node that needs to be changed, read the node it is connected to to determine the new node that needs to be connected; Establish an edge between the new node and the current node, and update the node corresponding to the edge connecting each node on the graph.

2. The method for storing and updating multi-agent traffic simulation data according to claim 1, characterized in that: In step S1, the vehicle number refers to the sequence number of the vehicle agents entering the simulation road section; The vehicle performance information includes vehicle length, maximum acceleration and maximum deceleration; The vehicle driving information includes the vehicle position, the vehicle current speed and the vehicle current acceleration; wherein the vehicle position refers to the relative starting position of the vehicle body along the driving direction of the simulated road section and the lane number in which it is located.

3. The method for storing and updating multi-agent traffic simulation data according to claim 1, characterized in that: In step S4, based on the intelligent microscopic lane-changing relationship of the vehicle, the connection correspondence between the nodes is determined, and the process of completing the edge definition of the simulation space graph includes: The vehicle agent represented by any node is regarded as a decision-making agent, and the corresponding information of the front vehicle in the current lane, the rear vehicle in the current lane, the front vehicle in the left lane, the rear vehicle in the left lane, the front vehicle in the right lane, and the rear vehicle in the right lane are obtained; Among them, the front vehicle information of the current lane represents the vehicle intelligent entity information that is in the same lane as the decision-making intelligent entity, whose vehicle position is larger than the decision-making intelligent entity and is the nearest vehicle intelligent entity information; the rear vehicle information of the current lane represents the vehicle intelligent entity information that is in the same lane as the decision-making intelligent entity, whose vehicle position is smaller than the decision-making intelligent entity and is the nearest vehicle intelligent entity information; the front vehicle information of the left lane represents the vehicle intelligent entity information that is located in the left lane of the decision-making intelligent entity, whose vehicle position is larger than the decision-making intelligent entity and is the nearest vehicle intelligent entity information; the rear vehicle information of the left lane represents the vehicle intelligent entity information that is located in the left lane of the decision-making intelligent entity, whose vehicle position is smaller than the decision-making intelligent entity and is the nearest vehicle intelligent entity information; the front vehicle information of the right lane represents the vehicle intelligent entity information that is located in the right lane of the decision-making intelligent entity, whose vehicle position is larger than the decision-making intelligent entity and is the nearest vehicle intelligent entity information; the rear vehicle information of the right lane represents the vehicle intelligent entity information that is located in the right lane of the decision-making intelligent entity, whose vehicle position is smaller than the decision-making intelligent entity and is the nearest vehicle intelligent entity information.

4. A multi-agent traffic simulation data storage and update device based on the method described in any one of claims 1 to 3, characterized in that: The device comprises: The vehicle attribute information acquisition module is used to acquire the attribute information of all vehicles on the microscopic simulation road, and the vehicle attribute information includes vehicle number, vehicle performance information and vehicle driving information; The vehicle agent creation module is used to establish corresponding vehicle agents for all vehicles. Each vehicle agent has corresponding vehicle attribute information, vehicle following decision-making capabilities, and vehicle lane changing decision-making capabilities. The node definition module is used to construct a simulation space graph. Each vehicle agent corresponds to a node in the simulation space graph, completing the node definition of the simulation space graph. The edge definition module is used to determine the connection correspondence between nodes based on the intelligent microscopic lane-changing relationship of the vehicle, and complete the edge definition of the simulation space graph; The simulation space graph update module is used to combine the vehicle attribute information, vehicle following decision-making ability and vehicle lane changing decision-making ability of each vehicle agent, and use the depth-first algorithm to update the state of the vehicle agent corresponding to each node on the simulation space graph. Then, based on the position of the vehicle agent after the state update, the node corresponding to the connection edge of each node on the simulation space graph is updated to realize the data update of the simulation space graph until the simulation time ends.

5. An electronic device, characterized in that: include: one or more processors; A storage device for storing one or more programs. When the one or more programs are executed by the one or more processors, the one or more processors implement the multi-agent traffic simulation data storage and update method as described in any one of claims 1-3.

6. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the multi-agent traffic simulation data storage and updating method as described in any one of claims 1 to 3 is implemented.

Citation Information

Patent Citations

  • Vehicle driving control method, terminal and computer readable storage medium

    CN112436960A

  • Urban traffic complex self-adaptive network parallel simulation system and method based on multi-scale integration

    CN103593535A

  • Adjacent vehicle query method based on microscopic traffic simulation vehicle data structure

    CN110457352A