CN-121982875-A - Vehicle state management method, device, equipment and product based on simulation environment
Abstract
The application discloses a vehicle state management method, device, equipment and product based on a simulation environment, and belongs to the technical field of simulation. The method comprises the steps of obtaining a traffic simulation environment, maintaining a plurality of vehicle queues connected front and back aiming at the target lane, wherein vehicles in each vehicle queue correspond to the same type of motion state, the motion states respectively corresponding to two adjacent vehicle queues are different, the motion states comprise a forward state and a stop state, determining target vehicles meeting updating conditions in the vehicle queues based on the traffic states corresponding to the target lane, and executing updating operation on the target vehicles, wherein the updating operation is used for updating at least one of the position, the speed and the motion states of the target vehicles, the stationary vehicles except the vehicles which can pass in the stop queue are skipped, the stop queue refers to the vehicle queue in the stop state, invalid calculation can be removed, and the vehicle state updating efficiency of a simulation frame is improved.
Inventors
- LIU LIN
- Huang Lanxiao
- Meng Mang
- TU YU
- LIU YINGHU
- LIN XIA
Assignees
- 腾讯科技(成都)有限公司
Dates
- Publication Date
- 20260505
- Application Date
- 20260327
Claims (18)
- 1. A vehicle state management method based on a simulation environment, the method comprising: Acquiring a traffic simulation environment, wherein the traffic simulation environment comprises a target lane; Maintaining a plurality of front-back connected vehicle queues aiming at the target lane, wherein vehicles in each vehicle queue correspond to the same type of motion state, and the motion states respectively corresponding to the front-back adjacent vehicle queues are different, and the motion states comprise a forward state and a stop state; determining target vehicles meeting updating conditions in the plurality of vehicle queues based on the traffic states corresponding to the target lanes; And performing an updating operation on the target vehicle, wherein the updating operation is used for updating at least one of the position, the speed and the motion state of the target vehicle, and the stationary vehicles except the passable vehicles in a stopping queue are skipped, and the stopping queue refers to a vehicle queue in the stopping state.
- 2. The method of claim 1, wherein the determining a target vehicle of the plurality of vehicle queues that meets an update condition based on a traffic state corresponding to the target lane comprises: Acquiring the phase type of a target signal lamp corresponding to the target lane; Determining the passing state corresponding to the target lane based on the phase type; And screening the target vehicles meeting the updating conditions according to the passing state and the arrangement sequence of the vehicle queues and the current motion state.
- 3. The method of claim 2, wherein the screening the target vehicles for compliance with the update condition based on the traffic state in combination with a ranking order of the vehicle queues and a current motion state comprises: under the condition that the target lane belongs to a passable state, acquiring a motion state of a first queue in the target lane, wherein the first queue is a1 st vehicle queue arranged in the target lane according to the arrangement sequence; The target vehicle meeting the update condition is determined based on the current motion state of the head queue.
- 4. A method according to claim 3, wherein said determining the target vehicle that meets the update condition based on the current motion state of the head queue comprises: Creating a traveling queue as a new head queue under the condition that the head queue belongs to the stop queue, wherein the traveling queue refers to a vehicle queue in the advancing state, and the new head queue comprises head vehicles in an original head queue; taking the vehicle queues except the new head queue as subsequent queues; Determining a subsequent target vehicle that meets the update condition based on the current motion state of the subsequent queue; and determining the vehicles in the new head queue and the subsequent target vehicles as the target vehicles.
- 5. A method according to claim 3, wherein said determining the target vehicle that meets the update condition based on the current motion state of the head queue comprises: taking the vehicle queues except the head queue as subsequent queues when the head queue belongs to the advancing queue, wherein the advancing queue refers to the vehicle queue in the advancing state; Determining a subsequent target vehicle that meets the update condition based on the current motion state of the subsequent queue; and determining the vehicles in the head queue and the subsequent target vehicles as the target vehicles.
- 6. The method of claim 2, wherein the screening the target vehicles for compliance with the update condition based on the traffic state in combination with a ranking order of the vehicle queues and a current motion state comprises: acquiring the current motion state of a first queue in the target lane when the target lane belongs to an unviewable state, wherein the first queue is a 1 st vehicle queue arranged in the target lane according to the arrangement sequence; determining the target vehicle meeting the update condition based on at least one of the current motion state of the head queue and a passable vehicle condition in the head queue.
- 7. The method of claim 6, wherein the determining the target vehicle that meets the update condition based on at least one of the current motion state of the head queue and a condition of vehicles available in the head queue comprises: skipping the head queue under the condition that the head queue belongs to the stop queue; Taking the remaining vehicle queues starting from the 2 nd vehicle queue after the first queue as subsequent queues; Determining a subsequent target vehicle that meets the update condition based on the current motion state of the subsequent queue; and determining the vehicles in the first and later 1 st vehicle queues and the subsequent target vehicles as the target vehicles.
- 8. The method of claim 6, wherein the determining the target vehicle that meets the update condition based on at least one of the current motion state of the head queue and a condition of vehicles available in the head queue comprises: under the condition that the head queue belongs to a traveling queue, acquiring the residual distance between a head vehicle and a stop line in the head queue; determining a passable vehicle condition in the head queue based on the remaining distance; the target vehicle meeting the update condition is determined based on the passable vehicle condition.
- 9. The method of claim 8, wherein the determining the target vehicle that meets the update condition based on the passable vehicle condition comprises: Under the condition that the passable vehicles exist in the first queue, taking the remaining vehicle queues starting from the 2 nd vehicle queue after the first queue as subsequent queues; Determining a subsequent target vehicle that meets the update condition based on the current motion state of the subsequent queue; and determining the vehicles in the first and later 1 st vehicle queues and the subsequent target vehicles as the target vehicles.
- 10. The method of claim 8, wherein the determining the target vehicle that meets the update condition based on the passable vehicle condition comprises: creating a stop queue as a new head queue when no passable vehicles exist in the head queue, wherein the new head queue comprises head vehicles in an original head queue; taking the remaining vehicle queues starting from the 2 nd vehicle queue after the new head queue as subsequent queues; Determining a subsequent target vehicle that meets the update condition based on the current motion state of the subsequent queue; and determining the vehicles in the first and later 1 st vehicle queues and the subsequent target vehicles as the target vehicles.
- 11. The method of claim 4, wherein the determining a subsequent target vehicle that meets the update condition based on the current motion state of the subsequent queue comprises: Determining the stop queue and the travel queue from the subsequent queues based on the current motion state; determining the passable vehicles in the stop queue in the subsequent queue; the passable vehicles in the stop queue and the full amount of vehicles in the travel queue are determined to be the subsequent target vehicles.
- 12. The method of claim 11, wherein the determining the navigable vehicles in the stop queue in the subsequent queue comprises: Acquiring a vehicle distance between a head vehicle in the stopping queue and a tail vehicle in a front vehicle queue; And under the condition that the vehicle distance meets the traffic condition, determining that the head vehicle is the traffic-capable vehicle, and moving the head vehicle to be the tail vehicle of the front vehicle queue until the vehicle distance corresponding to the head vehicle in the stop queue does not meet the traffic condition.
- 13. The method according to claim 1, wherein the method further comprises: Dividing each lane in the traffic simulation environment into a plurality of space lattices, wherein the space lattices are fixed areas with preset parking space capacity, and the space lattices correspond to vehicle information indexes which are used for indicating vehicles accommodated in the space lattices; updating the vehicle information index corresponding to the spatial grid based on the updating operation; When the lane change requirement corresponding to a first vehicle exists in the traffic simulation environment, determining adjacent space lattices conforming to adjacent detection conditions with the first vehicle; And determining the variable road condition of the first vehicle based on the vehicle information index corresponding to the adjacent space lattices.
- 14. The method of claim 1, wherein after the performing an update operation on the target vehicle, further comprising: Based on the updating operation, feeding back updated vehicle state information to a state sensing unit of the traffic simulation environment; and generating, by the state sensing unit, observation information for the traffic simulation environment, the observation information being used to provide perceptible traffic state data to a reinforcement learning agent, the reinforcement learning agent being used to learn traffic control decisions based on the traffic simulation environment.
- 15. A vehicle state management apparatus based on a simulation environment, the apparatus comprising: the acquisition module is used for acquiring the traffic simulation environment, the traffic simulation environment comprises a target lane; the management module is used for maintaining a plurality of front-back connected vehicle queues aiming at the target lane, wherein vehicles in each vehicle queue correspond to the same type of motion state, the motion states respectively corresponding to the front-back adjacent two vehicle queues are different, and the motion states comprise a forward state and a stop state; the determining module is used for determining target vehicles meeting updating conditions in the plurality of vehicle queues based on the traffic states corresponding to the target lanes; The management module is further configured to perform an update operation on the target vehicle, where the update operation is used to update at least one of a position, a speed, and the motion state of the target vehicle, and skip stationary vehicles except passable vehicles in a stop queue, where the stop queue refers to a vehicle queue in the stop state.
- 16. A computer device, characterized in that it comprises a processor and a memory, in which at least one section of a computer program is stored, which is loaded and executed by the processor to implement the simulation environment based vehicle state management method according to any of claims 1 to 14.
- 17. A computer readable storage medium, characterized in that at least one section of a computer program is stored in the storage medium, which is loaded and executed by a processor to implement the simulation environment based vehicle state management method according to any one of claims 1 to 14.
- 18. A computer program product comprising a computer program which, when executed by a processor, implements the simulation environment based vehicle state management method of any of claims 1 to 14.
Description
Vehicle state management method, device, equipment and product based on simulation environment Technical Field The present application relates to the field of simulation technologies, and in particular, to a vehicle state management method, device, equipment, and product based on a simulation environment. Background In the application of the reinforcement learning in the intelligent control field of urban traffic signal lamps, training and strategy iteration of an intelligent agent are required to be completed by depending on a traffic simulation environment, and the core of the traffic simulation environment is to update the vehicle state at high frequency and high efficiency so as to ensure the authenticity of simulation and the sample generation efficiency and provide accurate environment observation information for the reinforcement learning intelligent agent. In the related art, a traffic simulation environment updates the states of vehicles in a target lane in a vehicle-by-vehicle full-quantity scanning mode, and each simulation frame needs to perform checking and updating operations of states such as position, speed and the like on all vehicles in the lane one by one. However, in the above-mentioned traversal calculation method, the calculation cost of vehicle state update greatly increases with the increase of the number of simulated vehicles, so that the simulation efficiency is drastically reduced, and it is difficult to satisfy the requirement of reinforcement learning for high-frequency sample generation in the traffic simulation environment. Disclosure of Invention The embodiment of the application provides a vehicle state management method, device, equipment and product based on a simulation environment. The technical scheme comprises the following aspects. In one aspect, a vehicle state management method based on a simulation environment is provided, the method comprising: Acquiring a traffic simulation environment, wherein the traffic simulation environment comprises a target lane; Maintaining a plurality of front-back connected vehicle queues aiming at the target lane, wherein vehicles in each vehicle queue correspond to the same type of motion state, and the motion states respectively corresponding to the front-back adjacent vehicle queues are different, and the motion states comprise a forward state and a stop state; determining target vehicles meeting updating conditions in the plurality of vehicle queues based on the traffic states corresponding to the target lanes; And performing an updating operation on the target vehicle, wherein the updating operation is used for updating at least one of the position, the speed and the motion state of the target vehicle, and the stationary vehicles except the passable vehicles in a stopping queue are skipped, and the stopping queue refers to a vehicle queue in the stopping state. In another aspect, there is provided a vehicle state management apparatus based on a simulation environment, the apparatus including: the acquisition module is used for acquiring the traffic simulation environment, the traffic simulation environment comprises a target lane; the management module is used for maintaining a plurality of front-back connected vehicle queues aiming at the target lane, wherein vehicles in each vehicle queue correspond to the same type of motion state, the motion states respectively corresponding to the front-back adjacent two vehicle queues are different, and the motion states comprise a forward state and a stop state; the determining module is used for determining target vehicles meeting updating conditions in the plurality of vehicle queues based on the traffic states corresponding to the target lanes; The management module is further configured to perform an update operation on the target vehicle, where the update operation is used to update at least one of a position, a speed, and the motion state of the target vehicle, and skip stationary vehicles except passable vehicles in a stop queue, where the stop queue refers to a vehicle queue in the stop state. In some embodiments, the obtaining module is further configured to obtain a phase type of a target signal lamp corresponding to the target lane; the determining module is further configured to determine the traffic state corresponding to the target lane based on the phase type; the determining module is further configured to screen the target vehicle that meets the update condition based on the traffic state and in combination with the arrangement sequence of the vehicle queues and the current motion state. In some embodiments, the obtaining module is further configured to obtain, when the target lane belongs to a passable state, a movement state of a first queue in the target lane, where the first queue is a1 st vehicle queue arranged in the target lane according to the arrangement order; The determining module is further configured to determine, based on the current motion state of the head