WO2022143057A1 - 自动驾驶算法测试方法及相关设备 - Google Patents

自动驾驶算法测试方法及相关设备 Download PDF

Info

Publication number
WO2022143057A1
WO2022143057A1 PCT/CN2021/136414 CN2021136414W WO2022143057A1 WO 2022143057 A1 WO2022143057 A1 WO 2022143057A1 CN 2021136414 W CN2021136414 W CN 2021136414W WO 2022143057 A1 WO2022143057 A1 WO 2022143057A1
Authority
WO
WIPO (PCT)
Prior art keywords
obstacle
obstacles
motion information
vehicle
position information
Prior art date
Application number
PCT/CN2021/136414
Other languages
English (en)
French (fr)
Inventor
张宝宽
张磊
王超
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to EP21913798.1A priority Critical patent/EP4261729A1/en
Publication of WO2022143057A1 publication Critical patent/WO2022143057A1/zh
Priority to US18/215,581 priority patent/US20230339513A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3684Test management for test design, e.g. generating new test cases
    • BPERFORMING OPERATIONS; TRANSPORTING
    • B60VEHICLES IN GENERAL
    • B60WCONJOINT CONTROL OF VEHICLE SUB-UNITS OF DIFFERENT TYPE OR DIFFERENT FUNCTION; CONTROL SYSTEMS SPECIALLY ADAPTED FOR HYBRID VEHICLES; ROAD VEHICLE DRIVE CONTROL SYSTEMS FOR PURPOSES NOT RELATED TO THE CONTROL OF A PARTICULAR SUB-UNIT
    • B60W60/00Drive control systems specially adapted for autonomous road vehicles
    • B60W60/001Planning or execution of driving tasks
    • B60W60/0027Planning or execution of driving tasks using trajectory prediction for other traffic participants
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/10Geometric CAD
    • G06F30/15Vehicle, aircraft or watercraft design
    • BPERFORMING OPERATIONS; TRANSPORTING
    • B60VEHICLES IN GENERAL
    • B60WCONJOINT CONTROL OF VEHICLE SUB-UNITS OF DIFFERENT TYPE OR DIFFERENT FUNCTION; CONTROL SYSTEMS SPECIALLY ADAPTED FOR HYBRID VEHICLES; ROAD VEHICLE DRIVE CONTROL SYSTEMS FOR PURPOSES NOT RELATED TO THE CONTROL OF A PARTICULAR SUB-UNIT
    • B60W60/00Drive control systems specially adapted for autonomous road vehicles
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2455Query execution
    • G06F16/24552Database cache management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/29Geographical information databases
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/20Design optimisation, verification or simulation
    • BPERFORMING OPERATIONS; TRANSPORTING
    • B60VEHICLES IN GENERAL
    • B60WCONJOINT CONTROL OF VEHICLE SUB-UNITS OF DIFFERENT TYPE OR DIFFERENT FUNCTION; CONTROL SYSTEMS SPECIALLY ADAPTED FOR HYBRID VEHICLES; ROAD VEHICLE DRIVE CONTROL SYSTEMS FOR PURPOSES NOT RELATED TO THE CONTROL OF A PARTICULAR SUB-UNIT
    • B60W2554/00Input parameters relating to objects
    • B60W2554/40Dynamic objects, e.g. animals, windblown objects

Definitions

  • the present application relates to the field of automatic driving, and in particular, to an automatic driving algorithm testing method and related equipment.
  • Road testing is the core part of autonomous driving. Research shows that autonomous vehicles need to accumulate millions of kilometers of road tests to ensure the safety and reliability of autonomous driving perception, decision-making, and control of the entire link. There are problems such as high R&D costs, high potential safety risks, and low algorithm development efficiency through real-vehicle road tests. Therefore, simulation software is usually used in the industry to construct virtual scenarios for algorithm testing and verification.
  • a typical traffic scene is shown in Figure 1.
  • Vehicles, non-motor vehicles, pedestrians, and fences are complex scenes involving macro random traffic flow and micro scenes (vehicle changing lanes, braking, pedestrian crossing the road, etc.). Building similar complex and extreme scenarios in the driving simulation software to verify the automatic driving algorithm is extremely important for the rapid breakthrough of the automatic driving system.
  • the embodiments of the present application provide an automatic driving algorithm testing method and related equipment. By introducing an obstacle resource pool, efficient and unified management of obstacles is realized, which provides convenience for building complex test scenarios.
  • the present application provides an automatic driving algorithm testing method, including:
  • the N obstacles include the obstacles of the own vehicle and the surrounding obstacles of the obstacles of the own vehicle.
  • N is an integer greater than 0;
  • the ID and initial motion information of each obstacle in the obstacles are stored in the obstacle resource pool;
  • the motion information of the surrounding obstacles of the first obstacle is obtained from the obstacle resource pool according to the ID of the first obstacle, and according to the first obstacle.
  • the motion information of the surrounding obstacles of an obstacle controls the operation of the first obstacle, and obtains the motion information of the first obstacle; saves the motion information of each obstacle in the obstacle resource pool;
  • the n obstacles are obstacles of the ego vehicle, and n is less than or equal to N. According to the first motion information of the n obstacles, obtain the ego vehicle and n obstacles.
  • the interaction results of obstacles; the test results of the automatic driving algorithm are determined according to the interaction results.
  • the types of the N obstacles include some or all of refined trajectory obstacles, navigation-type obstacles, macroscopic traffic flow, and real road-test obstacles.
  • the road test obstacles are the obstacles collected by the vehicle during driving in the real environment.
  • the obstacle set includes the ID and configuration information of various obstacles, so N obstacles are obtained from the obstacle set
  • the ID and configuration information of N obstacles is implicitly obtained from the obstacle set, and no additional configuration of obstacles is required.
  • the configuration information of the obstacle includes initial motion information.
  • the obstacle resource pool By introducing the obstacle resource pool, the unified management of different types of obstacles in the test scene is realized, which also facilitates the construction of complex test scenes; the introduction of macro traffic flow and road test obstacles further facilitates the construction of complex test scenes Convenience is provided.
  • the obstacle resource pool includes a first buffer and a second buffer
  • the initial motion information includes initial position information
  • the method of the present application further includes:
  • the ID of the obstacle is stored in the obstacle resource pool with the location information as the index, so that when searching for obstacles in the obstacle field of view, the ID of the obstacle in the field of view of the obstacle can be quickly searched based on the position information, which improves the search efficiency.
  • the obstacle resource pool includes a first cache and a second cache, and initial motion information of obstacles around the first obstacle is obtained from the obstacle resource pool according to the ID of the first obstacle, including:
  • the initial motion information of the first obstacle is obtained from the first cache according to the ID hash value of the first obstacle, where the initial motion information includes initial position information, and the ID hash value of the first obstacle is for the first obstacle.
  • the IDs are obtained by hashing; the IDs of S obstacles are obtained from the second cache according to the initial position information of the first obstacles, where the S obstacles are obstacles located in the preset area of the first obstacle, and the first obstacle
  • the preset area of an obstacle is determined according to the initial position information of the first obstacle; the surrounding obstacles of the first obstacle are determined from the S obstacles according to the movement mode of the first obstacle; the surrounding obstacles of the first obstacle Among the S obstacles, when the first obstacle moves according to its movement mode, it has potential interaction with the first obstacle; according to the ID hash value of the surrounding obstacles of the first obstacle
  • the initial motion information of the surrounding obstacles is acquired, and the ID hash value of the surrounding obstacles of the first obstacle is obtained by hashing the IDs of the surrounding obstacles of the first obstacle.
  • the first motion information includes first position information
  • updating the initial motion information of the first obstacle in the obstacle resource pool to the first motion information includes:
  • the ID corresponding to the initial position information of the first obstacle is determined from the second cache according to the initial position information of the first obstacle. If the ID corresponding to the initial position information of the first obstacle is the ID of the first obstacle, then The initial position information of the first obstacle in the second cache is updated to the first position information of the first obstacle; the initial motion information of the first obstacle in the first cache is updated to the first obstacle according to the ID hash value of the first obstacle - Sports information.
  • the obstacles can obtain the motion information of obstacles with potential interaction with them, so that the interaction between obstacles is more reasonable.
  • the method of the present application further includes:
  • the initial motion information includes the initial position information of the newly added obstacle; Hash the ID of the newly added obstacle to obtain the ID hash value of the newly added obstacle, and save the initial motion information of the newly added obstacle to the ID hash value of the newly added obstacle in the first cache. and save the ID and initial motion information of the newly added obstacle in the second cache of the obstacle resource pool with the initial position information of the newly added obstacle as an index.
  • the relevant information of the newly added obstacle in the obstacle resource pool may be updated according to the above method.
  • the newly added obstacles include some or all of refined track obstacles, navigation-type track obstacles, macro traffic flow and road test obstacles.
  • the first motion information includes first position information
  • the first motion information of n obstacles is obtained from the obstacle resource pool according to the position information of the self-vehicle, including:
  • the IDs and the first position information of M obstacles are determined from the second cache according to the position information of the own vehicle.
  • the M obstacles are obstacles located within the preset range of the own vehicle; the preset range of the own vehicle is based on the self-vehicle. Determined by the position information of the vehicle, M is a positive integer less than or equal to N; n obstacles are determined from the M obstacles according to the preset interaction mode and the first position information of the M obstacles; the n obstacles are Obstacles potentially interacting with the ego vehicle; the first motion information of each obstacle in the n obstacles is determined from the first cache according to the ID hash value of each obstacle in the n obstacles.
  • the obstacles located within the preset range of the ego vehicle can be quickly determined from the second cache of the obstacle resource pool, which improves the search efficiency.
  • an embodiment of the present application also provides a simulation testing device, including:
  • the obtaining unit is used to obtain N obstacles from the obstacle set according to the test function of the automatic driving algorithm;
  • the N obstacles include the obstacles of the own vehicle and the surrounding obstacles of the obstacles of the own vehicle, and the types of the N obstacles Including some or all of refined trajectory obstacles, navigation obstacles, macro traffic flow and road test obstacles;
  • N is an integer greater than 0;
  • the storage unit is used to save the ID and initial motion information of each obstacle in the N obstacles to the obstacle resource pool;
  • the simulation test unit is used to obtain the motion information of the surrounding obstacles of the first obstacle from the obstacle resource pool according to the first obstacle ID, and control the operation of the first obstacle according to the motion information of the surrounding obstacles of the first obstacle , obtain the first motion information of each obstacle; update the initial motion information of the first obstacle in the obstacle resource pool to the first motion information of the first obstacle; obtain from the obstacle resource pool according to the position information of the own vehicle
  • the first motion information of n obstacles, the n obstacles are obstacles of the own vehicle, and n is less than or equal to N; according to the first motion information of the n obstacles, the interaction results between the own vehicle and the n obstacles are obtained;
  • the interactive results determine the test results of the autonomous driving algorithm.
  • the obstacle resource pool includes a first buffer and a second buffer
  • the initial motion information includes initial position information
  • the simulation testing device further includes:
  • the processing unit is used for hashing the ID of each obstacle in the N obstacles to obtain the ID hash value of each obstacle, and the ID hash value of each obstacle is used to indicate the ID of the obstacle.
  • the storage unit is specifically used for:
  • the obstacle resource pool includes a first cache and a second cache, in terms of acquiring initial motion information of obstacles surrounding the first obstacle from the obstacle resource pool according to the ID of the first obstacle , the simulation test unit is specifically used for:
  • the initial motion information of the first obstacle is obtained from the first cache according to the ID hash value of the first obstacle, where the initial motion information includes initial position information, and the ID hash value of the first obstacle is for the first obstacle.
  • the IDs are obtained by hashing;
  • the IDs of S obstacles are obtained from the second cache according to the initial position information of the first obstacles, where the S obstacles are obstacles located in the preset area of the first obstacle, and the first obstacle
  • the preset area of an obstacle is determined based on the initial position information of the first obstacle, and S is less than or equal to N;
  • the surrounding obstacles of the first obstacle are determined from the S obstacles according to the movement mode of the first obstacle,
  • the surrounding obstacles of the first obstacle are obstacles that potentially interact with the first obstacle when the first obstacle moves in a motion mode among the S obstacles; according to the ID hash value of the surrounding obstacles of the first obstacle
  • the initial motion information of the surrounding obstacles is obtained from the first cache, and the ID hash value of the surrounding obstacles of the first obstacle is obtained by hashing the
  • the first motion information includes first position information
  • the simulation test unit is specifically used for:
  • the ID corresponding to the initial position information of the first obstacle is determined from the second cache according to the initial position information of the first obstacle. If the ID corresponding to the initial position information of the first obstacle is the ID of the first obstacle, then The initial position information of the first obstacle in the second cache is updated to the first position information of the first obstacle; the initial motion information of the first obstacle in the first cache is updated to the first obstacle according to the ID hash value of the first obstacle - Sports information.
  • the first motion information includes first position information.
  • the simulation test unit is specifically used for :
  • the IDs and the first position information of M obstacles are determined from the second cache according to the position information of the own vehicle.
  • the M obstacles are obstacles located within the preset range of the own vehicle; the preset range of the own vehicle is based on the self-vehicle. Determined by the position information of the vehicle, M is a positive integer less than or equal to N; n obstacles are determined from the M obstacles according to the preset interaction mode and the first position information of the M obstacles; The ego vehicle has potentially interacting obstacles; the first motion information of each obstacle among the n obstacles is determined from the first cache according to the ID hash value of each obstacle among the n obstacles.
  • an embodiment of the present application also provides a simulation testing device, including:
  • an embodiment of the present application provides a chip system, which is applied to an electronic device; the chip system includes one or more interface circuits and one or more processors; the interface circuit and the processor pass through line interconnection; the interface circuit is used to receive signals from the memory of the electronic device and send the signals to the processor, the signals include computer instructions stored in the memory; when the processor executes the When executing the computer instructions, the electronic device executes part or all of the method described in the first aspect.
  • an embodiment of the present application provides a computer-readable storage medium, where the computer storage medium stores a computer program, the computer program includes program instructions, and the program instructions, when executed by a processor, cause the processor to execute Part or all of the method as described in the first aspect.
  • an embodiment of the present application provides a computer program product, which is characterized by comprising computer instructions, which, when the computer instructions are executed on an electronic device, cause the electronic device to execute part of the method described in the first aspect or all.
  • Figure 1 is a schematic diagram of a traffic scene at an intersection
  • FIG. 2 is a schematic flowchart of a method for testing an automatic driving algorithm provided by an embodiment of the present application
  • Figure 3a is a schematic diagram of an obstacle field of view
  • Figure 3b is a schematic diagram of the self-vehicle field of view and the obstacle field of view;
  • Figure 4 is a schematic diagram of interaction between obstacles
  • Figure 5 is a schematic diagram of the interaction between the self-vehicle and the obstacle
  • FIG. 6 is a schematic diagram of a data channel
  • Fig. 7 is a kind of test scene schematic diagram
  • FIG. 8 is a schematic view of a navigation type obstacle
  • Fig. 9 is the visual field schematic diagram of navigation type obstacle
  • FIG. 11 is a schematic structural diagram of a simulation testing device provided by an embodiment of the application.
  • FIG. 12 is a schematic structural diagram of another simulation testing device provided by an embodiment of the application.
  • FIG. 13 is a schematic structural diagram of another simulation testing apparatus provided by an embodiment of the present application.
  • Refinement track obstacles including but not limited to obstacles with attributes such as the type of obstacle, speed, starting point coordinates, track point coordinates, and ending point coordinates. In the test, such obstacles move from the starting point to the end point strictly according to the preset speed and trajectory point.
  • the types of refined trajectory obstacles include but are not limited to people, cars, trucks, bicycles, and electric vehicles.
  • this type of obstacle Compared with refined trajectory obstacles, the attributes of this type of obstacle include type, speed, starting point and ending point. In the test scene, this type of obstacle only needs to move from the starting point to the end point according to the preset speed limit. During this process, the speed and motion trajectory will be dynamically adjusted according to the interaction with other obstacles.
  • Macro traffic flow refers to the traffic flow formed by the continuous driving of cars on the road. In a broad sense, it also includes the traffic and people flow of other vehicles. For a certain period of time, on the road section not affected by the lateral intersection, the traffic flow is in a continuous flow state; when it encounters traffic light control, it is in an intermittent flow state. Attributes of macroscopic traffic flow include, but are not limited to, the number of obstacles, the type of obstacles, speed, starting point and ending point, etc.
  • Road Test Obstacles Obstacles obtained by the vehicle driving in the real road test environment, including nearby motor vehicles, pedestrians, non-motor vehicles, etc. during the driving process of the vehicle.
  • FIG. 2 is a schematic flowchart of an automatic driving algorithm testing method provided by an embodiment of the present application. As shown in Figure 2, the method includes:
  • the simulation test device acquires N obstacles from the obstacle set according to the test function of the automatic driving algorithm.
  • N obstacles include the obstacles of the own vehicle and the surrounding obstacles of the obstacles of the own vehicle.
  • the obstacle set After obtaining N obstacles from the obstacle set, assign an ID to each obstacle in the N obstacles, and configure each obstacle, thereby obtaining the ID and configuration information, and obtain the ID and configuration information of each obstacle in the N obstacles; or the obstacle set includes the ID and configuration information of various obstacles, so N obstacles are obtained from the obstacle set
  • the ID and configuration information of N obstacles is implicitly obtained from the obstacle set, and no additional configuration of obstacles is required.
  • the types of the above-mentioned plurality of first obstacles include some or all of refined trajectory obstacles, navigation-type obstacles, macroscopic traffic flow, and road-test obstacles.
  • the configuration information of the refined trajectory obstacle includes but is not limited to the subtype, speed, starting point coordinates, trajectory point coordinates and end point coordinates of the obstacle;
  • the configuration information of the navigation type obstacle includes but is not limited to the subtype of the obstacle. , speed, starting point coordinates and ending point coordinates, etc.;
  • the configuration information of macro traffic flow includes but not limited to the number of obstacles, subtypes of obstacles, speed, starting point coordinates and ending point coordinates, etc.;
  • the configuration information of road test obstacles includes but not limited to It is limited to the subtype of obstacles, the speed, heading angle and coordinates at each moment collected during the drive test.
  • sub-types of obstacles include but are not limited to pedestrians, animals, cars, buses, trucks, bicycles, and electric vehicles.
  • the macro traffic flow may be preset in the automatic driving algorithm simulation test device, or may be obtained by the simulation test device from other devices.
  • the simulation test device sends a macro traffic flow acquisition request to other devices, and the obtained The request includes the configuration information of the traffic flow.
  • Other devices generate the macroscopic traffic flow based on the configuration information of the macroscopic traffic flow, and send the macroscopic traffic flow to the simulation test device to respond to the above-mentioned macroscopic traffic flow acquisition request.
  • the automatic driving algorithm has multiple functions, such as parking to avoid obstacles, overtaking, changing lanes to the left, changing lanes to the right, following a car, etc.
  • a simulation test is performed.
  • the device can obtain the configuration file corresponding to the function, and the configuration file includes the IDs and configuration information of the above N obstacles, so as to obtain N obstacles from the obstacle set according to the test function of the automatic driving algorithm, and obtain the N obstacles. ID and configuration information of each obstacle in each obstacle.
  • the configuration file may be preset in the simulation test apparatus, or may be obtained by the simulation test apparatus from other devices.
  • simulation test device can be a part of the vehicle or a special test server; of course, this is just an example, not a limitation of this application, and the simulation test device can also be other equipment, which will not be omitted here. List them one by one.
  • the simulation test device saves the initial motion information of each obstacle in the N obstacles to the obstacle resource pool.
  • the initial motion information of the N obstacles is obtained according to the configuration information of the first obstacle, and the motion information of the obstacles includes but is not limited to the subtype of the obstacle, the coordinates of the starting point, the coordinates of the ending point, the current coordinates, the speed and the heading angle etc.
  • the configuration information of each obstacle in the N obstacles is parsed to obtain the initial motion information of the obstacle;
  • the ID of each obstacle in the obstacles is an index, and the ID of each obstacle and its initial motion information are stored in the obstacle resource pool, so that the N obstacles can be managed uniformly.
  • the obstacle resource pool includes a first cache and a second cache, and after acquiring the configuration information of the N obstacles, the configuration information of each obstacle in the N obstacles is parsed , in order to obtain the initial motion information of the obstacle, the initial motion information includes initial position information, the position information can be coordinates, of course, it can be other, which is not limited in this application;
  • the ID of an obstacle is hashed to obtain the ID hash value of the obstacle, the ID hash value is used to indicate the storage space in the first cache, or the ID hash value can be regarded as a storage address, the storage The storage space corresponding to the address is included in the first cache; the initial motion information of each first obstacle in the N obstacles is stored in the storage space indicated by the ID hash value of the first obstacle; then N
  • the initial position information of each obstacle among the obstacles is an index, and the ID and initial position information of each obstacle are stored in the second cache of the obstacle resource pool, so as to uniformly manage the N obstacles, and in the Subsequent searches for obstacles that interact with obstacles or
  • the simulation test device acquires initial motion information of obstacles around the first obstacle from the obstacle resource pool according to the ID of the first obstacle, and controls the first obstacle according to the initial motion information of the obstacles around the first obstacle to obtain the first motion result of the first obstacle, and update the initial position information of the first obstacle in the obstacle resource pool to the first motion result of the first obstacle.
  • the simple vehicle dynamics model and the dusbin curve are simulated and run; wherein, the simple vehicle dynamics model is as follows:
  • the origin of the car body is located in the center of the rear wheel of the vehicle, the x-axis is along the direction of the main axis of the vehicle, which is the same as the moving direction of the vehicle; the moving speed of the vehicle is u s , and the angle of the steering wheel is ⁇ , which is the same as the angle of the front wheel; The distance between the center of the wheel and the rear wheel is L, and the heading angle is ⁇ .
  • fine trajectory obstacles such as cars, buses, and trucks move in the above-mentioned manner.
  • the position indicated by the starting point coordinates of the navigational obstacle is used as the starting point, and the current position of the navigational obstacle to the end point is planned in real time according to the motion information of other obstacles in the test scene.
  • the navigation path between the positions indicated by the coordinates; then the navigation-type obstacle travels according to the path planned in real time.
  • the macro traffic flow takes the position indicated by the starting point coordinates and the position indicated by the end point coordinates in its motion information as the starting point and the end point respectively, and according to the speed in the motion information of the macro traffic flow. drive.
  • the motion information of the road test obstacles includes the speed, heading angle and coordinates at each moment during the road test process, in order to simulate the real driving environment, during the test process, according to the speed, Information such as heading angle and coordinates control the movement of obstacles in the drive test.
  • the movement of the obstacle when controlling the movement of the obstacle, can be controlled not only based on the movement information of the obstacle, but also based on the movement information and the action to be performed by the obstacle during the test, so as to construct a more detailed model. testing scenarios.
  • each obstacle in the N obstacles is processed as follows:
  • the initial motion information of the surrounding obstacles of the first obstacle is obtained from the obstacle resource pool according to the ID of the first obstacle, and the operation of the first obstacle is controlled according to the initial motion information of the surrounding obstacles of the first obstacle, and the first obstacle is obtained.
  • the first motion information of an obstacle updating the initial motion information of the first obstacle in the obstacle resource pool to the first motion information of the first obstacle; the first obstacle is any one of the N obstacles;
  • obtain initial motion information of obstacles around the first obstacle from the obstacle resource pool according to the ID of the first obstacle including:
  • the initial motion information of the first obstacle is obtained from the first cache of the obstacle resource pool according to the ID hash value of the first obstacle.
  • the ID hash value of the first obstacle is to hash the ID of the first obstacle.
  • the initial motion information of the first obstacle includes the initial position information of the first obstacle; according to the initial position information of the first obstacle, the IDs of the S obstacles are determined from the second cache of the obstacle resource pool.
  • the S obstacles are obstacles located in the preset range of the first obstacle, wherein the preset area of the first obstacle is the area with the position of the first obstacle as the center and the radius of R; of course, the first obstacle
  • the preset area of the first obstacle can also be a square area or a rectangular area centered on the position of the first obstacle, which is not limited here, and the preset area of
  • the position of the first obstacle is the position indicated by the initial position information of the first obstacle;
  • the S obstacles are obstacles whose distance between the position in the second cache and the position indicated by the initial position information of the first obstacle is less than a preset distance; determine the surrounding obstacles of the first obstacle in the object, and the surrounding obstacles of the first obstacle are obstacles that potentially interact with the first obstacle when the first obstacle moves according to its movement mode among the S obstacles;
  • the initial motion information of the surrounding obstacles is obtained from the first cache according to the ID hash value of the surrounding obstacles of the first obstacle, wherein the
  • the operation of the first obstacle is controlled according to the initial motion information of the surrounding obstacles of the first obstacle, and the first motion information of the first obstacle is obtained.
  • the area in the dotted frame is the preset area of obstacle A, and the obstacle located in the preset area of obstacle A Including Obstacle B, Obstacle C, and Obstacle D.
  • obstacle B is located in front of obstacle A, and obstacle C and obstacle D are located at the right rear and left rear of obstacle A, respectively;
  • obstacle D is determined according to the initial motion information of obstacle D Whether it is about to accelerate overtaking or keep the speed unchanged; if it is determined that obstacle D is about to accelerate overtaking, control obstacle A to keep the speed and direction unchanged to avoid collision with obstacle D when obstacle A changes lanes.
  • a motion information includes first position information.
  • the preset areas are the first area, the second area, the third area and the fourth area as shown in FIG. 4 , respectively.
  • all vehicles other than vehicle 1 in the first area can be regarded as obstacles in the field of view of vehicle 1, which can be determined from the second cache of the obstacle resource pool based on the position information of vehicle 1;
  • Vehicles on the left and in front of vehicle 1 (the vehicles with black lines and white background) in an area traveling in the same direction as vehicle 1 will have an impact on the driving of vehicle 1, while vehicles with gray and white background will not affect the driving of vehicle 1.
  • the vehicle with the black line and the white background is the target obstacle of the vehicle 1, so the vehicle with the black line and the white background in the first area is the surrounding obstacle of the vehicle 1;
  • vehicle 2 all vehicles in the second area except vehicle 2 can be regarded as obstacles in the field of view of vehicle 2, which can be determined from the second cache of the obstacle resource pool based on the position information of vehicle 2; the second Vehicles in the area running in the same direction as Vehicle 2 and located in the upper left corner and in front of Vehicle 2 (vehicles with black lines and white backgrounds) will affect the driving of Vehicle 2.
  • Vehicles with black lines and white backgrounds are obstacles around Vehicle 2 Therefore, the vehicle with black line and white background in the second area is the surrounding obstacle of vehicle 2;
  • all vehicles other than vehicle 3 in the third area can be regarded as obstacles in the field of view of vehicle 3, which can be determined from the second cache of the obstacle resource pool based on the position information of vehicle 3;
  • the third Vehicles located in the same lane as Vehicle 3 and in front of Vehicle 3 in the area will affect the driving of Vehicle 3, while vehicles with gray and white backgrounds will not affect the driving of Vehicle 3.
  • Black lines Vehicles with white background are obstacles around vehicle 3, so vehicles with black lines and white background in the third area are obstacles around vehicle 3;
  • all vehicles except vehicle 4 in the fourth area can be regarded as obstacles in the field of view of vehicle 4, which can be determined from the second cache of the obstacle resource pool based on the position information of vehicle 4; the fourth Vehicles in the area that are driving in the same direction as vehicle 4 and located in the upper left corner of vehicle 4 (vehicles with black lines and white backgrounds) will affect the driving of vehicle 4, while vehicles with gray and white backgrounds will not affect the driving of vehicle 4.
  • Vehicles with black lines and white backgrounds are obstacles around vehicle 4
  • vehicles with black lines and white backgrounds in the fourth area are obstacles around vehicle 4 .
  • the initial motion information of the first obstacle After acquiring the first motion information of the first obstacle, acquire the initial motion information of the first obstacle from the first cache of the obstacle resource pool according to the ID hash value of the first obstacle, where the initial motion information includes the initial position information, obtain the ID corresponding to the initial position information from the second cache of the obstacle resource pool according to the initial position information, if the ID is the ID of the first obstacle, update the position information corresponding to the ID in the second cache to The first position information; the initial motion information of the first obstacle in the first cache is updated to the first motion information of the first obstacle, so as to facilitate the management of the N obstacles based on the obstacle resource pool.
  • obstacle A is any one of N obstacles
  • the area in the dotted frame is the preset area of obstacle A
  • the obstacles located in the preset area of obstacle A include: Obstacle B, Obstacle C, and Obstacle D
  • Obstacle B, Obstacle C, and Obstacle D are obstacles within the field of view of Obstacle A.
  • obstacle B is located in front of obstacle A, and obstacle C and obstacle D are located at the right rear and left rear of obstacle A, respectively;
  • obstacle A is a navigational obstacle
  • the trajectory of the navigational obstacle is not fixed, so the movement mode of obstacle A can be to change lanes to the left, and the target obstacle of obstacle A is the above-mentioned obstacle D;
  • the motion information of D determines whether the obstacle D is about to accelerate overtaking or the speed remains unchanged; if it is determined that the obstacle D is about to accelerate and overtake, then control the obstacle A to keep the speed and direction unchanged, so as to avoid the obstacle A changing lanes with the same speed.
  • Obstacle D collides; if it is determined that the speed of obstacle D remains unchanged, control obstacle A to change lanes to the left to complete the left lane change operation; assuming that obstacle A is a precise trajectory obstacle, refine the trajectory of the obstacle.
  • the driving trajectory is fixed, so the movement mode can be following the car, and the target obstacle of obstacle A is the above-mentioned obstacle B; according to the motion information of obstacle B, determine whether obstacle B accelerates or decelerates; if it is determined that obstacle B accelerates When driving, control obstacle A to speed up; if it is determined that obstacle B slows down, control obstacle A to slow down to avoid rear-end collision with obstacle A; assuming that obstacle A and obstacle B are adjacent in the macro traffic flow Obstacle, for obstacle A, its preset interaction mode is following the car, and the third obstacle of obstacle A is the above-mentioned obstacle B; according to the motion information of obstacle B, determine whether obstacle B accelerates or decelerates; When the obstacle B accelerates, the obstacle A is controlled to accelerate; if it
  • the motion information of obstacle A is obtained, and the first motion information of obstacle A is updated to the motion information of obstacle A in the obstacle resource pool according to the above method.
  • the real driving scene can be simulated more realistically, which in turn makes the test results of the automatic driving algorithm more accurate.
  • the simulation test device obtains the first motion information of n obstacles from the obstacle resource pool according to the position information of the own vehicle, where the n first obstacles are obstacles of the own vehicle, and n is less than or equal to N.
  • the IDs and the first motion information of M obstacles are determined from the second cache of the obstacle resource pool according to the position information of the self-vehicle, where the M obstacles are obstacles within the preset range of the self-vehicle, and M less than or equal to N; n obstacles are determined from the M obstacles according to the preset interaction mode of the ego vehicle and the first position information of the M obstacles, and the n obstacles are obstacles that have potential interaction with the ego vehicle; The first motion information of each of the n obstacles is determined from the first cache according to the ID hash value of each of the n obstacles.
  • the preset area of the self-vehicle may be a circular area with a radius of r centered on the coordinate of the self-vehicle, or a square area, and of course other irregular shapes.
  • n obstacles are determined from the M obstacles, and the n obstacles are obstacles that have potential interaction with the ego vehicle.
  • the interaction mode is that when the self-vehicle is driving forward, the obstacle with potential interaction with the self-vehicle is the obstacle in front of the self-vehicle; for another example, when the preset interaction method is that the self-vehicle is about to change lanes to the right, the obstacle with the self-vehicle can interact with the self-vehicle. Obstacles with potential interaction are obstacles located on the right side and rear right side of the vehicle; for another example, when the preset interaction method is that the vehicle is about to change lanes to the left, the obstacles with potential interaction with the vehicle are located on the right side of the vehicle. Obstacles on the left and rear left of the ego vehicle; for another example, when the preset interaction mode is the ego car reversing, the obstacles that potentially interact with the ego car are the obstacles located behind the ego car.
  • the obstacles located in the preset area of obstacle A include obstacle B, obstacle C and obstacle D; Position information, it can be determined that obstacle B is located in front of obstacle A, and obstacle C and obstacle D are located at the right rear and left rear of obstacle A, respectively; assuming that obstacle A moves to the right, obstacle C There is potential interaction with obstacle A, so the surrounding obstacles of obstacle A are the above-mentioned obstacle C; according to the initial motion information of obstacle C, it is determined that obstacle C is driving at a constant speed, and obstacle A is controlled to change lanes to the right; For the self-vehicle, the obstacles within the preset range include obstacle A, obstacle B, and obstacle C. It is assumed that the preset interaction mode of the self-vehicle is to change lanes to the left, and the obstacles that have potential interaction with the self-vehicle include obstacles obstacle A and obstacle C; the above n obstacles include obstacle A and obstacle C.
  • the motion information of N obstacles in the obstacle resource pool is updated in real time, which is achieved in the following ways:
  • the second motion information includes second position information
  • the second position information is the real-time position information of the first obstacle
  • the second position information is the real-time position information of the first obstacle
  • the ID hash value of the first obstacle Determine the storage location of the motion information of the first obstacle from the first cache of the obstacle resource pool, and then obtain the historical motion information of the first obstacle, where the historical motion information includes historical position information; according to the historical position of the first obstacle
  • the information obtains the ID corresponding to the historical position information from the second cache. If the ID corresponding to the historical position information of the first obstacle is the ID of the obstacle, the second position information of the first obstacle in the second cache is updated. is the historical position information of the first obstacle, and the historical motion information of the first obstacle stored in the storage location indicated by the ID hash value of the first obstacle in the first cache is updated to the second motion information of the obstacle ;
  • the first obstacle is any one of the N obstacles;
  • the motion information of the N obstacles in the obstacle resource pool is updated.
  • obstacles can be added according to a preset method or the user's instruction; the preset method can be as follows: if the self-vehicle does not interact with the obstacle within a preset period of time, it will automatically increase Some obstacles that interact with the self-vehicle, such obstacles can be refined trajectory obstacles, navigational trajectory obstacles, macro traffic flow, road test obstacles or other obstacles; Obtain the ID and configuration information of the newly added obstacle, and analyze the configuration information of the newly added obstacle to obtain the initial motion information of the newly added obstacle, and the initial motion information includes the initial position information of the newly added obstacle; The ID of the obstacle is hashed to obtain the ID hash value of the newly added obstacle, and the initial motion information of the newly added obstacle is saved to the storage indicated by the ID hash value of the newly added obstacle in the first cache.
  • the relevant information of the newly added obstacle in the obstacle resource pool may be updated according to the above method.
  • the above-mentioned second obstacle is an obstacle that has potential interaction with the vehicle in the subsequent test process.
  • the specific method may be: obtaining the ID of the obstacle to be deleted; hashing the ID of the obstacle to be deleted to obtain the ID hash value of the obstacle to be deleted, based on the ID hash value of the obstacle to be deleted Obtain the motion information of the obstacle from the first cache of the obstacle resource pool, where the motion information includes position information, obtain the ID corresponding to the position information from the second cache based on the position information, and then obtain the ID and its corresponding position from the second cache.
  • the information is deleted from the second cache; optionally, because the update times of the position information of different obstacles in the second cache are inconsistent, there may be multiple obstacles with the same position information. For example, at time t1, the obstacles The position information of z1 and obstacle z2 are ad1 and ad2 respectively.
  • the position information of obstacle z1 is updated from ad1 to ad2, and the position information of obstacle z2 is not updated.
  • the obstacle in the second cache The position information of z1 is the same as that of the obstacle z2.
  • the IDs of the obstacles: z1 and z2 can be obtained from the second cache. Therefore, according to the ID of the obstacle to be deleted, the position information of the obstacle and the ID of the obstacle can be obtained.
  • the ID is deleted from the second cache, and the motion information of the obstacle to be deleted is deleted from the first cache according to the ID hash value of the obstacle to be deleted.
  • the specific method of deletion may be: obtaining the ID of the obstacle to be deleted; hashing the ID of the obstacle to be deleted to obtain the ID hash value of the obstacle to be deleted, based on the obstacle to be deleted.
  • the ID hash value of the object obtains the motion information of the obstacle to be deleted from the first cache of the obstacle resource pool, the motion information includes the position information, and the ID corresponding to the position information is obtained from the second cache based on the position information.
  • the storage accuracy of the same location information in the first cache and the second cache may be inconsistent, so that the ID corresponding to the location information cannot be determined from the second cache based on the location information obtained from the first cache.
  • One or more IDs are obtained from the second cache, and the absolute value of the difference between the position information corresponding to the one or more IDs and the position information obtained from the first cache is less than the preset distance, and then a Among the multiple IDs and their corresponding location information, the same ID as the ID of the obstacle to be deleted and its corresponding location information are deleted from the second cache.
  • the obstacle resource pool is introduced into the simulation test scene, which realizes the unified management of obstacles in the simulation test scene.
  • the obstacle X can be regarded as a function or model from the perspective of the simulation test device.
  • the function or model runs on the CPU of the simulation test device, and the obstacle resource pool is
  • the running memory includes a message queue; during the test process, the motion information of obstacle X needs to be sent to the obstacle resource pool in real time, and the preset area of obstacle X can also be obtained from the obstacle resource pool.
  • the third obstacle can also obtain the motion information of any obstacle from the obstacle resource pool; specifically, the CPU sends a report message to the running memory, and the report message carries the ID hash value of the obstacle X and the obstacle X
  • the running memory saves the report message in the message queue, and the CPU can also send a first acquisition request message to the running memory, and the first acquisition request message is used to request the acquisition of obstacles within the preset range of the obstacle X ID, and the first acquisition request message carries the ID hash value of the obstacle X; the running memory saves the first acquisition request message in the message queue; the CPU can also send a second acquisition request message to the running memory, the The second acquisition request message is used to request the acquisition of the motion information of the obstacle E, and the second acquisition request message carries the ID hash value of the obstacle E; the running memory can sequentially or in parallel read the messages from the message queue and execute the corresponding operation; for example, if the report message is read, the running memory root will save the ID hash value carried in the report message and the real
  • the report message does not require a response, so the report message can be regarded as an asynchronous request message; the first acquisition request message and the second acquisition request message need a response, so the first acquisition request message and the second acquisition request message can be regarded as synchronous request messages, As shown in Figure 6.
  • the running memory deletes the message from the message queue.
  • the above message queue can be regarded as a data channel between obstacles and obstacle resource pools.
  • the request message When it is determined that a request message related to the obstacle X needs to be sent, the request message includes information about the obstacle X, including but not limited to the ID hash value of the obstacle X, the location and the information of the obstacles within the field of view, The information of obstacle X is stored in the request cache of obstacle X, and it is packaged into a report message or request message. For the request message, after the CPU obtains the corresponding response message, the response message is saved in the response cache of obstacle X. As shown in Figure 6.
  • the first acquisition request message is used to request the acquisition of the ID of the obstacle in the field of view, or the motion information of the obstacle in the field of view; when the request to acquire is the motion information of the obstacle in the field of view. , after determining the target obstacle from the obstacles based on the ID in the field of view, it is necessary to send a request message for requesting to obtain the motion information of the target obstacle.
  • the interaction results include but are not limited to safe following, rear-end collision, safe overtaking, overtaking collision, obstacle avoidance failure and obstacle collision, obstacle avoidance success, etc.
  • the obstacles located in the preset area of obstacle A include obstacle B, obstacle C and obstacle D; Position information, it can be determined that obstacle B is located in front of obstacle A, and obstacle C and obstacle D are located at the right rear and left rear of obstacle A, respectively; assuming that obstacle A moves to the right, obstacle C There is potential interaction with obstacle A, so the surrounding obstacles of obstacle A are the above-mentioned obstacle C; according to the initial motion information of obstacle C, it is determined that obstacle C is driving at a constant speed, and obstacle A is controlled to change lanes to the right; For the self-vehicle, the obstacles within the preset range include obstacle A, obstacle B, and obstacle C.
  • the preset interaction mode of the self-vehicle is to change lanes to the left, and the obstacles that have potential interaction with the self-vehicle include obstacles obstacle A and obstacle C; according to the motion information of obstacle C, it is determined that the speed of obstacle C remains unchanged. If the ego vehicle changes lanes to the right, the interaction result between ego car and obstacle includes collision with obstacle A, and Obstacle C is a collision; if the ego vehicle keeps the speed and direction unchanged, the interaction result between ego car and obstacle includes no collision with obstacle A and obstacle C.
  • one or more of the first obstacles can be determined according to the coordinates of the ego vehicle and the coordinates of the plurality of first obstacles.
  • a plurality of second obstacles the second obstacle is an obstacle in front of the self-vehicle among the plurality of first obstacles; if the preset interaction action is to follow the car, the third obstacle is an obstacle located in the same lane as the self-vehicle As shown in Figure a in Figure 5, the third obstacle is obstacle 1; if it is determined that obstacle 1 is decelerating according to the motion information of obstacle 1, and the ego vehicle is accelerating or the speed remains unchanged at this time, then It is determined that the interaction result is a rear-end collision; if it is determined that the obstacle 1 is accelerating according to the motion information of the obstacle 1, and the ego vehicle is decelerating or the speed remains unchanged at this time, the interaction result is determined that the following vehicle fails.
  • the third obstacle is obstacle 2.
  • the motion information of obstacle 2 it is determined that obstacle 2 is about to be inserted into the lane.
  • the interaction result can be acceleration to pass safely, acceleration to overtake to collide, deceleration or parking to avoid success;
  • the preset interaction action is to change lanes to the right, and the third obstacle is the left rear and rear obstacles, such as the obstacle 3 shown in Figure c in Figure 5; the speed of the obstacle 3 is determined according to the motion information of the obstacle 3 Keep driving unchanged; at this time, you can change lanes to the left and accelerate, and the interaction result can be that the lane change to the left is successful.
  • the interaction result between the self-vehicle and the obstacle can be obtained.
  • the self-vehicle and the obstacles in the field of view of the self-vehicle are displayed in real time on the display interface of the simulation test device, or the self-vehicle and N obstacles are displayed in real time.
  • the interaction results can be analyzed from any one or a combination of dimensions of task completion, compliance with traffic rules, safety, vehicle comfort, and traffic efficiency, so as to determine the test result of the automatic driving algorithm, which is Test results include pass and fail tests.
  • the interaction results can be divided into safe driving and dangerous driving, respectively count the number of safe driving and the number of dangerous driving in the interactive result, and then calculate the proportion of safe driving according to the number of safe driving and the number of dangerous driving;
  • the automatic driving algorithm is determined to pass the test;
  • the automatic driving algorithm is determined to pass the test.
  • the interaction results can also be based on any dimension of the task completion of the automatic driving algorithm, whether it complies with traffic rules, vehicle comfort and traffic efficiency; of course, it can also be based on task completion, whether it conforms to traffic rules, vehicle comfort and traffic efficiency. Dimension analyzes the interaction results to determine whether the autonomous driving algorithm passes the test.
  • the specific steps include:
  • the configuration information of the refined trajectory obstacle is obtained, and the configuration information of the refined trajectory obstacle includes but is not limited to the subtype of the obstacle, the coordinates of the starting point, the coordinates of the end point, the coordinates of the driving track point, and the speed, wherein the subtype of the obstacle is Type is car.
  • the vehicle dynamics model and the dubins curve are used to control the refined trajectory obstacle operation.
  • the vehicle dynamics model reference may be made to the relevant descriptions of the above embodiments, which will not be described here.
  • the configuration information of the navigation-type obstacle is acquired, where the configuration information includes but is not limited to the subtype, speed, coordinates of the starting point, and coordinates of the ending point of the obstacle.
  • Plan a driving path for navigational obstacles based on the coordinates of the starting point and the ending point.
  • the navigational obstacles can avoid obstacles, change lanes, and interact with other obstacles.
  • Road which reflects the interaction between obstacles.
  • the area within the two yellow lines is the field of view of the navigation-type obstacle, and one of the two yellow lines is the trajectory line of the navigation-type obstacle.
  • the configuration information of the macro traffic flow is acquired, the configuration information including but not limited to the number of obstacles, the subtype of the obstacles, the speed, the coordinates of the starting point and the ending point, and the like.
  • the configuration information of macro traffic flow can be parsed from the imported configuration file, or input by the user; after obtaining the configuration information, send the configuration information to the connected third-party traffic flow software, and the third-party traffic
  • the flow software generates macro traffic flow based on the input configuration information, and inputs the generated macro traffic flow into the simulation test software.
  • the macro traffic flow has been deployed in the test scene.
  • the initial motion information of the fine trajectory obstacles, the initial motion information of the navigation obstacles, and the macroscopic traffic flow information are respectively parsed from the configuration information of the fine trajectory obstacles, the configuration information of the navigation obstacles, and the configuration information of the macro traffic flow.
  • the information is an index, and the location information and IDs of these obstacles are stored in the second cache of the obstacle resource pool.
  • step S203 the motion information of the obstacles in the test scene is changing.
  • each obstacle in the test scene is obtained in real time. and update the motion information of the obstacles in the obstacle resource pool.
  • new obstacles can be added to the test scene according to user instructions, and the ID and motion information of the newly added obstacles can be saved to the obstacle
  • the resource pool is convenient for management, and the specific implementation process can refer to the relevant description of step S203.
  • the newly added obstacles may be some or all of refined trajectory obstacles, navigational obstacles, macro traffic flow and road test obstacles.
  • these obstacles can be selected from the obstacle resource pool according to the IDs of these obstacles.
  • these obstacles can be some or all of the fine trajectory obstacles, navigation obstacles, macro traffic flow and road test obstacles.
  • the CPU sends an acquisition request message carrying the ID hash value of the navigation-type obstacle to the running memory, and the acquisition request message is used to request to acquire the obstacles within the field of view of the navigation-type obstacle;
  • the motion memory hashes the ID according to the obstacle.
  • the value obtains the motion information of the navigation-type obstacle from the first cache of the obstacle resource pool, and the motion information includes the position information;
  • the running memory obtains the navigation-type obstacle from the second cache of the obstacle resource pool according to the position information of the navigation-type obstacle.
  • the target obstacle of the navigational obstacle includes the obstacles in the field of view of the navigational obstacle that are located in front of or to the right of the vehicle; for example, when the navigational obstacle changes lanes to the left, the target obstacle of the navigational obstacle Including the obstacles located on the left or left rear of the vehicle in the obstacles
  • the navigation-type obstacle when the navigation-type obstacle is driving forward, the obstacle in front stops, and the navigation-type obstacle stops or changes lanes to avoid rear-end collision. As shown in Figure 9, there is a horizontal line in front of the navigation-type obstacle, indicating that the navigation-type obstacle parking.
  • the IDs and motion information of T second obstacles are obtained from the obstacle resource pool according to the position information of the own vehicle, where the T second obstacles are obstacles in the field of view of the own vehicle, and T is an integer greater than 0 ;
  • the area in the dotted frame is the field of view of the vehicle, and the obstacles in the field of view of the vehicle include parts of macro traffic flow, fine trajectory obstacles and navigation obstacles; according to the preset interaction of the vehicle
  • the method (such as changing lanes to the right) and the position information of the T second obstacles determine the obstacles of the ego vehicle from the T second obstacles, and obtain the motion information of the obstacles of the ego car.
  • the obstacles of the ego car are Navigation-type obstacle located at the right rear of the vehicle; the interaction result between the vehicle and the right-rear navigation-type obstacle is determined according to the motion information of the navigation-type obstacle in the front right and the motion information of the vehicle.
  • the interaction results include successful lane change and the ego vehicle is in front of the right rear obstacle after the lane change, successful lane change and the ego vehicle is behind the right rear obstacle after the lane change, or the ego vehicle collides with the right rear obstacle.
  • the automatic driving algorithm passes the test; if the interaction result is If the ego vehicle collides with an obstacle in the right rear, the automatic driving algorithm fails the test.
  • the unified management of obstacles in the test scene is realized; for adding, deleting and updating obstacles in the test scene, only the obstacle resource pool needs to be managed, and multiple nodes and multiple data are not required.
  • the channels transmit data to each other, which simplifies the complexity of data communication on the simulation platform and improves the simulation efficiency; adding obstacles in the test scene can realize the detailed simulation of the specified scene, which greatly improves the flexibility and intelligence of the simulation scene;
  • the obstacles within the field of view of the obstacle are determined in the second cache of the obstacle resource pool based on the location of the obstacle, and the location information is used as an index in the obstacle resource pool, and the second cache is searched through the location information. Obstacles within the field of view of the obstacles improve the query efficiency and efficiently realize the interaction between obstacles.
  • the specific steps include:
  • steps S1001-S1003 reference may be made to the relevant descriptions of steps S801-S803, which will not be described here.
  • the configuration information of the road test obstacle is obtained, the configuration information includes but not limited to the subtype of the road test obstacle, the initial position and speed of the road test obstacle in the real road test scene, and the like. So far, the test scenario shown in Figure 10 has been constructed.
  • the configuration information of the fine trajectory obstacles, the configuration information of the navigation-type obstacles, the configuration information of the macro traffic flow, and the configuration information of the road-test obstacles are respectively analyzed to obtain the initial motion information of the fine-track obstacles, the navigation-type obstacles
  • the initial motion information of obstacles, the initial motion information of macro traffic flow, and the initial motion information of road-tested obstacles; with the IDs of these obstacles as indexes, the motion information of these obstacles is saved in the obstacle resource pool.
  • the information is an index
  • the location information and IDs of these obstacles are stored in the second cache of the obstacle resource pool.
  • the ID of the obstacle is stored in the obstacle resource pool with the location information as the index, which can quickly search for the ID of the obstacle within the obstacle field of view, and then obtain the motion information of the obstacle based on the ID, which improves the search efficiency.
  • the obstacles in the field of vision of roadside obstacles determined according to the location of the road-tested obstacles include macro traffic flow and the self-vehicle driving behind the road-tested obstacles to the right; the road-tested obstacles are driving in the same direction Therefore, the target obstacle of the road test obstacle is the macro traffic flow traveling in the same direction; when the macro traffic flow decelerates or stops, in order to avoid the rear end of the road test obstacle, control the direction of the road test obstacle. Change lanes right.
  • the road test obstacles interact with the macro traffic flow, and the road test obstacles and the macro traffic flow constitute an enhanced HIL scene.
  • the IDs and motion information of T second obstacles are obtained from the obstacle resource pool according to the position information of the own vehicle, where the T second obstacles are obstacles in the field of view of the own vehicle, and T is an integer greater than 0 ;
  • the field of view of the self-vehicle is shown in the dashed box in Figure 10
  • the T second obstacles include obstacles located in the dashed box, according to the preset interaction mode, such as changing lanes to the right
  • the position information of the T second obstacles determines the obstacles of the ego vehicle from the T second obstacles, and the obstacles of the ego car include the navigation type obstacles located in the right rear of the ego car and the obstacles located in the front right of the ego car and facing the ego car.
  • the road test obstacle for lane change in the lane in which it is located obtain the motion information of the obstacle of the own vehicle; determine the interaction result between the own vehicle and the obstacle of the own vehicle according to the motion information of the obstacle of the own vehicle and the motion information of the own vehicle.
  • the interaction results include: the self-vehicle stops changing lanes to the right and collides with road-test obstacles; the self-vehicle stops changing lanes to the right and does not collide with road-test obstacles; The vehicle did not collide with a right rear navigation obstacle when it collided or changed lanes to the right.
  • the automatic driving algorithm fails the test; when the self-vehicle does not collide with the right rear obstacle or the road-tested obstacle, it is determined that the automatic driving algorithm passes the test .
  • an enhanced HIL scene is constructed, and the data collected by road test is effectively used, so that the obstacles in the real scene collected by road test have dynamic interaction and facilitates the deployment of complex scenarios.
  • FIG. 11 is a schematic structural diagram of a simulation testing apparatus provided by an embodiment of the present application.
  • the simulation test device 1100 includes: a refined trajectory obstacle generation module 1101 , a navigation obstacle generation module 1102 , a traffic flow module 1103 , a road test obstacle module 1104 , a resource pool module 1105 , and a simulation module 1106 and obstacle visualization module 1107;
  • the refined trajectory obstacle generation module 1101 is used to generate the refined trajectory obstacle according to the attribute of the refined obstacle, and then use the vehicle dynamics model and the Dubins curve to generate the refined trajectory obstacle according to the attribute of the refined obstacle; wherein , the attributes of the refined trajectory obstacle include but are not limited to the type of obstacle, speed, starting point coordinates, track point coordinates, end point coordinates, etc.;
  • the navigation type obstacle generation module 1102 is configured to generate a navigation type obstacle according to the attributes of the navigation type obstacle.
  • the attributes of the navigation type obstacle include but are not limited to the type, speed, starting point coordinates, and ending point coordinates of the obstacle. (The trajectory of the obstacle based on the coordinates of the starting point and the ending point through a high-precision map);
  • the traffic flow module 1103 is used to deploy a macro traffic flow in the test scene.
  • the attributes of the traffic flow include but are not limited to the number of obstacles in the traffic flow, the type of obstacles, the coordinates of the starting point and the ending point, etc.; according to the attributes of the traffic flow Generate traffic flow; optionally, generate traffic flow according to the attributes of the traffic flow through third-party traffic flow software; or send the attributes of the traffic flow to the third-party device, and the third-party device generates the traffic flow according to the attribute of the traffic flow through the third-party traffic flow software traffic flow, and generating the traffic flow to the traffic flow module 1103;
  • the road test obstacle module 1104 is used to deploy road test obstacles in the test scene, and the attributes of the road test obstacles include but are not limited to the subtype, coordinates, speed and heading angle of the road test obstacles. It should be pointed out that when the road test obstacles interact with other obstacles (such as fine trajectory obstacles, navigation obstacles or macro traffic flow), the road test obstacles and other obstacles constitute an enhanced HIL scene. .
  • the resource pool module 1105 is configured to store the motion information of the above-mentioned obstacles according to the IDs of the above-mentioned obstacles.
  • the obstacle resource pool includes a first cache and a second cache.
  • the ID of the obstacle is hashed to obtain the ID hash value of the obstacle, and the ID hash value is used as the storage address, and the motion of the obstacle is stored
  • the information is stored in the storage space indicated by the ID hash value in the first cache; and the position information of the obstacle is used as an index to save the ID and position information of the obstacle in the second cache.
  • the simulation module 1106 is used for, in the process of testing the automatic driving algorithm, for each obstacle in the test scene, obtain the motion information of the obstacle potentially interacting with the obstacle in real time, and control the above-mentioned motion information based on the motion information. Obstacle movement, to realize the interaction between obstacles and obstacles; for the self-vehicle based on the motion of the self-driving algorithm, obtain the movement information of obstacles that have potential interaction with the self-vehicle, and based on the movement information of the self-vehicle and these obstacles based on the interaction results, and determine whether the automatic driving algorithm passes the test based on the interaction results.
  • the obstacle visualization module 1107 is used to display the positional relationship between the above obstacles and the own vehicle in real time on the display interface.
  • FIG. 12 is a schematic structural diagram of a simulation testing apparatus provided by an embodiment of the present application. As shown in Figure 12, the simulation test device 1200 includes:
  • the obtaining unit 1201 is configured to obtain N obstacles from the obstacle set according to the test function of the automatic driving algorithm;
  • the N obstacles include obstacles of the own vehicle and obstacles around the obstacles of the own vehicle, and the N obstacles Types include some or all of refined trajectory obstacles, navigation obstacles, macro traffic flow and road test obstacles;
  • N is an integer greater than 0;
  • the storage unit 1202 is used to save the ID and initial motion information of each obstacle in the N obstacles to the obstacle resource pool;
  • the simulation test unit 1203 is used to obtain the motion information of the surrounding obstacles of the first obstacle from the obstacle resource pool according to the first obstacle ID, and control the first obstacle according to the motion information of the surrounding obstacles of the first obstacle run to obtain the first motion information of each obstacle; update the initial motion information of the first obstacle in the obstacle resource pool to the first motion information of the first obstacle; according to the position information of the vehicle from the obstacle resource pool Obtain the first motion information of n obstacles, the n obstacles are obstacles of the own vehicle, and n is less than or equal to N; obtain the interaction results between the own vehicle and n obstacles according to the first motion information of the n obstacles; Determine the test results of the autonomous driving algorithm based on the interactive results.
  • the obstacle resource pool includes a first buffer and a second buffer
  • the initial motion information includes initial position information
  • the simulation testing device 1200 further includes:
  • the processing unit 1204 is configured to perform hash processing on the ID of each obstacle in the N obstacles to obtain the ID hash value of each obstacle, and the ID hash value of each obstacle is used to indicate the obstacle The storage space of the motion information in the first cache;
  • the storage unit 1202 is specifically used for:
  • the obstacle resource pool includes a first cache and a second cache, in terms of acquiring initial motion information of obstacles surrounding the first obstacle from the obstacle resource pool according to the ID of the first obstacle , the simulation test unit 1203 is specifically used for:
  • the initial motion information of the first obstacle is obtained from the first cache according to the ID hash value of the first obstacle, where the initial motion information includes initial position information, and the ID hash value of the first obstacle is for the first obstacle.
  • the IDs are obtained by hashing;
  • the IDs of S obstacles are obtained from the second cache according to the initial position information of the first obstacles, where the S obstacles are obstacles located in the preset area of the first obstacle, and the first obstacle
  • the preset area of an obstacle is determined based on the initial position information of the first obstacle, and S is less than or equal to N;
  • the surrounding obstacles of the first obstacle are determined from the S obstacles according to the movement mode of the first obstacle,
  • the surrounding obstacles of the first obstacle are obstacles that potentially interact with the first obstacle when the first obstacle moves in a motion mode among the S obstacles; according to the ID hash value of the surrounding obstacles of the first obstacle
  • the initial motion information of the surrounding obstacles is obtained from the first cache, and the ID hash value of the surrounding obstacles of the first obstacle is obtained by hashing the
  • the first motion information includes first position information, and in terms of updating the initial motion information of the first obstacle in the obstacle resource pool to the first motion information, the simulation testing unit 1203 is specifically used for:
  • the ID corresponding to the initial position information of the first obstacle is determined from the second cache according to the initial position information of the first obstacle. If the ID corresponding to the initial position information of the first obstacle is the ID of the first obstacle, then The initial position information of the first obstacle in the second cache is updated to the first position information of the first obstacle; the initial motion information of the first obstacle in the first cache is updated to the first obstacle according to the ID hash value of the first obstacle - Sports information.
  • the first motion information includes first position information.
  • the simulation testing unit 1203 specifically uses At:
  • the IDs and the first position information of M obstacles are determined from the second cache according to the position information of the own vehicle.
  • the M obstacles are obstacles located within the preset range of the own vehicle; the preset range of the own vehicle is based on the self-vehicle. Determined by the position information of the vehicle, M is a positive integer less than or equal to N; n obstacles are determined from the M obstacles according to the preset interaction mode and the first position information of the M obstacles; The ego vehicle has potentially interacting obstacles; the first motion information of each obstacle among the n obstacles is determined from the first cache according to the ID hash value of each obstacle among the n obstacles.
  • the above units are used to execute the relevant content of steps S201 to S205 of the above method.
  • the acquisition unit 1201 is used to execute the relevant content of step S201
  • the storage unit 1202 is used to execute the relevant content of step S202
  • the simulation test unit is used to execute the relevant content of steps S203-S205.
  • the simulation testing apparatus 1200 is presented in the form of a unit.
  • a "unit” here may refer to an application-specific integrated circuit (ASIC), a processor and memory executing one or more software or firmware programs, an integrated logic circuit, and/or other devices that can provide the above-described functions .
  • ASIC application-specific integrated circuit
  • the above acquisition unit 1201 , storage unit 1202 , simulation testing unit 1203 and processing unit 1204 may be implemented by the processor 1301 of the simulation testing apparatus shown in FIG. 13 .
  • the simulation testing apparatus 1300 can be implemented with the structure shown in FIG. 13 .
  • the simulation testing apparatus 1300 includes at least one processor 1301 , at least one memory 1302 and at least one communication interface 1303 .
  • the processor 1301, the memory 1302 and the communication interface 1303 are connected through the communication bus and complete the communication with each other.
  • the processor 1301 may be a general-purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits used to control the execution of the above programs.
  • CPU central processing unit
  • ASIC application-specific integrated circuit
  • the communication interface 1303 is used to communicate with other devices or communication networks, such as Ethernet, radio access network (RAN), wireless local area network (Wireless Local Area Networks, WLAN).
  • RAN radio access network
  • WLAN Wireless Local Area Networks
  • Memory 1302 may be read-only memory (ROM) or other type of static storage device that can store static information and instructions, random access memory (RAM), or other type of static storage device that can store information and instructions It can also be an electrically erasable programmable read-only memory (Electrically Erasable Programmable Read-Only Memory, EEPROM), a compact disc read-only memory (CD-ROM) or other optical disk storage, optical disk storage (including compact discs, laser discs, optical discs, digital versatile discs, Blu-ray discs, etc.), magnetic disk storage media or other magnetic storage devices, or capable of carrying or storing desired program code in the form of instructions or data structures and capable of being executed by a computer Access any other medium without limitation.
  • the memory can exist independently and be connected to the processor through a bus.
  • the memory can also be integrated with the processor.
  • the memory 1302 is used to store the application code for executing the above solutions, and the execution is controlled by the processor 1301 .
  • the processor 1301 is used for executing the application code stored in the memory 1302 .
  • the code stored in the memory 1302 can execute any test method for the automatic driving algorithm provided above, for example: according to the test function of the automatic driving algorithm, N obstacles are obtained from the set of obstacles, and the N obstacles include the obstacles of the own vehicle N is an integer greater than 0; save the ID and initial motion information of each obstacle in the N obstacles to the obstacle resource pool; ID obtains the motion information of the surrounding obstacles of the first obstacle from the obstacle resource pool, and controls the operation of the first obstacle according to the motion information of the surrounding obstacles of the first obstacle, and obtains the motion information of the first obstacle;
  • the motion information of each obstacle is stored in the obstacle resource pool;
  • the first motion information of n obstacles is obtained from the obstacle resource pool according to the position information of the self-vehicle, and the n obstacles are the obstacles of the self-vehicle , n is less than or equal to N, and the interaction results between the ego vehicle and the n obstacles are obtained according to the first motion information of the n obstacles;
  • the test results of the automatic driving algorithm are determined according
  • Embodiments of the present application further provide a computer storage medium, wherein the computer storage medium may store a program, and when the program is executed, the program includes part or all of the steps of any automatic driving algorithm testing method described in the above method embodiments.
  • the disclosed apparatus may be implemented in other manners.
  • the apparatus embodiments described above are only illustrative, for example, the division of the units is only a logical function division, and there may be other division methods in actual implementation, for example, multiple units or components may be combined or Integration into another system, or some features can be ignored, or not implemented.
  • the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or units, and may be in electrical or other forms.
  • the units described as separate components may or may not be physically separated, and components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.
  • each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit.
  • the above-mentioned integrated units may be implemented in the form of hardware, or may be implemented in the form of software functional units.
  • the integrated unit if implemented as a software functional unit and sold or used as a stand-alone product, may be stored in a computer-readable memory.
  • the technical solution of the present application can be embodied in the form of a software product in essence, or the part that contributes to the prior art, or all or part of the technical solution, and the computer software product is stored in a memory.
  • a computer device which may be a personal computer, a server, or a network device, etc.
  • the aforementioned memory includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disk or optical disk and other media that can store program codes.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Geometry (AREA)
  • Databases & Information Systems (AREA)
  • Evolutionary Computation (AREA)
  • Automation & Control Theory (AREA)
  • Transportation (AREA)
  • Human Computer Interaction (AREA)
  • Mechanical Engineering (AREA)
  • Quality & Reliability (AREA)
  • Data Mining & Analysis (AREA)
  • Aviation & Aerospace Engineering (AREA)
  • Pure & Applied Mathematics (AREA)
  • Mathematical Optimization (AREA)
  • Computational Linguistics (AREA)
  • Mathematical Analysis (AREA)
  • Remote Sensing (AREA)
  • Computational Mathematics (AREA)
  • Traffic Control Systems (AREA)

Abstract

本申请涉及自动驾驶领域,具体公开了一种自动驾驶算法测试方法及装置。该方法包括:按照自动驾驶算法的测试功能从障碍物集合中获取N个障碍物,将N个障碍物中每个障碍物的ID及初始运动信息保存至障碍物资源池中;根据第一障碍物的ID从障碍物资源池中获取第一障碍物的周围障碍物的运动信息,并根据第一障碍物的周围障碍物的运动信息控制第一障碍物运行,得到第一障碍物的运动信息;将该运动信息保存至障碍物资源池中;根据自车的位置信息及障碍物资源池中获取自车与n个障碍物的交互结果;根据交互结果确定自动驾驶算法的测试结果。通过引入障碍物资源池,实现了测试场景中的障碍物进行统一管理,为构建复杂的测试场景提供了便利。

Description

自动驾驶算法测试方法及相关设备
本申请要求于2020年12月31日提交中国国家知识产权局、申请号为202011645222.0、发明名称为“自动驾驶算法测试方法及相关设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及自动驾驶领域,尤其涉及一种自动驾驶算法测试方法及相关设备。
背景技术
路测是自动驾驶落地的核心环节。研究显示,自动驾驶汽车需要积累上百万公里的道路测试,才能保证自动驾驶感知、决策、控制整个链路的安全性和可靠性。通过实车路测验证算法存在研发成本高、潜在安全风险大、算法开发效率低等问题,因此业界通常采用仿真软件构造虚拟场景进行算法测试和验证。
但是,目前大部分自动驾驶仿真软件构建仿真场景单一,面临着复杂场景验证效率低下的关键问题:复杂场景构建难度大,无法还原真实路况的不确定性,自动驾驶系统无法精准应对真实路况的突发情况,自动驾驶难以实现进一步突破。
自动驾驶仿真软件构建复杂场景存在许多难题,比如:(1)如何构建典型的微观仿真场景,给出不同类型障碍物的微观行为,如车辆避让、换道、跟车、抢行、突然加速、刹车等场景、行人过马路、闯红灯等微观行为及静止障碍物;(2)如何构建宏观交通流仿真场景,模拟随机交通流、交通拥堵等场景;(3)如何有效利用道路测试采集的数据,使得路测采集的真实场景内的障碍物具有动态交互性、增加场景复杂性也是亟待解决的问题;(4)如何对上述不同来源的障碍物进行高效的统一管理,实现仿真平台中所有障碍物之间的交互,增加仿真真实性是当前需要解决的业界难题。
典型交通场景为图1所示,车辆、非机动车、行人、围栏,是一个涉及宏观随机交通流、微观场景(车辆变道、刹车,行人过马路等行为)的复杂场景,如果能在自动驾驶仿真软件中构建类似复杂、极端的场景来验证自动驾驶算法,对于自动驾驶系统得以快速突破有着极其重要的帮助。
发明内容
本申请实施例提供一种自动驾驶算法测试方法及相关设备,通过引入障碍物资源池,实现了对障碍物进行高效地统一管理,为构建复杂的测试场景提供了便利。
第一方面,本申请提供一种自动驾驶算法测试方法,包括:
按照自动驾驶算法的测试功能从障碍物集合中获取N个障碍物,N个障碍物包括自车的障碍物和该自车的障碍物的周围障碍物,N为大于0的整数;将N个障碍物中每个障碍物的ID及初始运动信息保存至障碍物资源池中;根据第一障碍物的ID从障碍物资源池中获取第一障碍物的周围障碍物的运动信息,并根据第一障碍物的周围障碍物的运动信息控制第一障碍物运行,得到第一障碍物的运动信息;将每个障碍物的运动信息保存至障碍物资源池中;根据自车的位置信息从障碍物资源池中获取n个障碍物的第一运功信息,该n个障碍物为自 车的障碍物,n小于或等于N,根据n个障碍物的第一运动信息获取自车与n个障碍物的交互结果;根据交互结果确定自动驾驶算法的测试结果。
其中,N个障碍物的类型包括精细化轨迹障碍物、导航型障碍物、宏观交通流和真实路测障碍物中的部分或者全部。路测障碍物为车辆在真实环境行驶过程中采集得到的障碍物。
可选地,在从障碍物集合中获取N个障碍物之后,为该N个障碍物中的每个障碍物分配ID,并对每个障碍物进行配置,从而得到每个障碍物的ID及配置信息,并获取N个障碍物中每个障碍物的ID及其配置信息;或者障碍物集合中包括各类障碍物的ID及其配置信息,因此在从障碍物集合中获取N个障碍物时,隐含了从障碍物集合中获取N个障碍物的ID及配置信息,不需要对障碍物进行额外的配置。其中,障碍物的配置信息包括初始运动信息。
通过引入障碍物资源池,实现了对测试场景中的不同类型的障碍物进行统一管理,也为构建复杂测试场景提供了便利;通过引入宏观交通流和路测障碍物,进一步为构建复杂测试场景提供了便利。
在一个可行的实施例中,障碍物资源池包括第一缓存和第二缓存,初始运动信息包括初始位置信息,本申请的方法还包括:
对N个障碍物中的每个障碍物的ID进行哈希处理,得到每个障碍物的ID哈希值;每个障碍物的ID哈希值用于指示该障碍物的运动信息在第一缓存中的存储空间;
将N个障碍物中每个障碍物的ID及初始运动信息保存至障碍物资源池中,包括:
将N个障碍物中每个障碍物的初始运动信息保存至第一缓存中该障碍物的ID哈希值所指示的存储空间中;以N个障碍物中的每个障碍物的初始位置信息为索引,将该障碍物的ID及初始位置信息保存至第二缓存中。
在障碍物资源池中以位置信息为索引存储障碍物的ID,使得在后续搜索障碍物视野内的障碍物时,可以基于位置信息快速搜素到障碍物视野内的障碍物的ID,提高了搜索效率。
在一个可行的实施例中,障碍物资源池包括第一缓存和第二缓存,根据第一障碍物的ID从障碍物资源池中获取第一障碍物的周围障碍物的初始运动信息,包括:
根据第一障碍物的ID哈希值从第一缓存中获取第一障碍物的初始运动信息,该初始运动信息包括初始位置信息,第一障碍物的ID哈希值是对第一障碍物的ID进行哈希处理得到的;根据第一障碍物的初始位置信息从第二缓存中获取S个障碍物的ID,该S障碍物为位于第一障碍物的预设区域内的障碍物,第一障碍物的预设区域是根据第一障碍物的初始位置信息确定的;根据第一障碍物的运动方式从S个障碍物确定第一障碍物的周围障碍物;第一障碍物的周围障碍物为S个障碍物中,在第一障碍物按照其运动方式运动时与第一障碍物有潜在交互的障碍物;根据第一障碍物的周围障碍物的ID哈希值从第一缓存中获取周围障碍物的初始运动信息,第一障碍物的周围障碍物的ID哈希值是对第一障碍物的周围障碍物的ID进行哈希处理得到的。
在障碍物之间进行交互时,通过引入障碍物的预设区域(该区域可以看成障碍物的视野),避免了在障碍物资源池的范围内查找与有潜在交互的障碍物,高效实现了障碍物之间的交互。并且通过此方式实现了路测障碍物与其他障碍物之间的交互,使得路测障碍物与其进行交互的其他障碍物构成了硬件在环(hardware in the loop,HIL)场景,为构建复杂测试场景提供了便利,同时有效利用路测障碍物。
在一个可行的实施例中,第一运动信息包括第一位置信息,将障碍物资源池中第一障碍物的初始运动信息更新为第一运动信息,包括:
根据第一障碍物的初始位置信息从第二缓存中确定第一障碍物的初始位置信息对应的 ID,若第一障碍物的初始位置信息对应的ID为该第一障碍物的ID,则将第二缓存中第一障碍物的初始位置信息更新为第一障碍物的第一位置信息;根据第一障碍物的ID哈希值将第一缓存中第一障碍物的初始运动信息更新为第一运动信息。
通过实时更新障碍物的运动信息,使得在后续障碍物之间的交互时,障碍物能够获取与其有潜在交互的障碍物的运动信息,从而障碍物之间交互更加合理。
在一个可行的实施例中,本申请的方法还包括:
根据用户指令获取新增障碍物的ID及配置信息,并对新增障碍物的配置信息进行解析,得到新增障碍物的初始运动信息;该初始运动信息包括新增障碍物的初始位置信息;对新增障碍物的ID进行哈希处理,以得到新增障碍物的ID哈希值,并将新增障碍物的初始运动信息保存至第一缓存中新增障碍物的ID哈希值所示的存储空间中;并以新增障碍物的初始位置信息为索引,将新增障碍物的ID和初始运动信息保存至障碍物资源池的第二缓存中。同时在后续过程中,可以按照上述方式更新障碍物资源池中新增障碍物的相关信息。
其中,新增障碍物包括精细化轨迹障碍物、导航型轨迹障碍物、宏观交通流和路测障碍物中的部分或者全部。
通过随机在测试场景中插入宏观交通车流、导航型障碍物、精细轨迹障碍物等多类型障碍物,可以实现指定场景的细节仿真,极大的提高了仿真场景灵活性和智能性。
在一个可行的实施例中,第一运动信息包括第一位置信息,根据自车的位置信息从障碍物资源池中获取n个障碍物的第一运动信息,包括:
根据自车的位置信息从第二缓存中确定M个障碍物的ID及第一位置信息,M个障碍物为位于自车的预设范围内的障碍物;自车的预设范围是基于自车的位置信息确定的,M为小于或等于N的正整数;根据预设交互方式和M个障碍物的第一位置信息从M个障碍物中确定n个障碍物;该n个障碍物为与自车存在潜在交互的障碍物;根据n个障碍物中每个障碍物的ID哈希值从第一缓存中确定n个障碍物中每个障碍物的第一运动信息。
通过引入自车的预设范围,可以快速从障碍物资源池的第二缓存中确定出位于自车的预设范围内的障碍物,提高了搜索效率。
第二方面,本申请实施例还提供一种仿真测试装置,包括:
获取单元,用于按照自动驾驶算法的测试功能从障碍物集合中获取N个障碍物;该N个障碍物包括自车的障碍物和自车障碍物的周围障碍物,N个障碍物的类型包括精细化轨迹障碍物、导航型障碍物、宏观交通流和路测障碍物中的部分或者全部;N为大于0的整数;
存储单元,用于将N个障碍物中每个障碍物的ID及初始运动信息保存至障碍物资源池;
仿真测试单元,用于根据第一障碍物ID从障碍物资源池中获取第一障碍物的周围障碍物的运动信息,并根据第一障碍物的周围障碍物的运动信息控制第一障碍物运行,得到每个障碍物的第一运动信息;将障碍物资源池中第一障碍物的初始运动信息更新为第一障碍物的第一运动信息;根据自车的位置信息从障碍物资源池获取n个障碍物的第一运动信息,n个障碍物为自车的障碍物,n小于或等于N;根据n个障碍物的第一运动信息获取自车与n个障碍物的交互结果;根据交互结果确定自动驾驶算法的测试结果。
在一个可行的实施例中,障碍物资源池包括第一缓存和第二缓存,初始运动信息包括初始位置信息,仿真测试装置还包括:
处理单元,用于对N个障碍物中的每个障碍物的ID进行哈希处理,得到每个障碍物的ID哈希值,每个障碍物的ID哈希值用于指示该障碍物的运动信息在第一缓存中的存储空间;
存储单元具体用于:
将N个障碍物中每个障碍物的初始运动信息保存至第一缓存中该障碍物的ID哈希值所指示的存储空间中;以N个障碍物中的每个障碍物的初始位置信息为索引,将每个障碍物的ID及初始位置信息保存至第二缓存中。
在一个可行的实施例中,障碍物资源池包括第一缓存和第二缓存,在根据第一障碍物的ID从障碍物资源池中获取第一障碍物的周围障碍物的初始运动信息的方面,仿真测试单元具体用于:
根据第一障碍物的ID哈希值从第一缓存中获取第一障碍物的初始运动信息,该初始运动信息包括初始位置信息,第一障碍物的ID哈希值是对第一障碍物的ID进行哈希处理得到的;根据第一障碍物的初始位置信息从第二缓存中获取S个障碍物的ID,S个障碍物为位于第一障碍物的预设区域内的障碍物,第一障碍物的预设区域是基于第一障碍物的初始位置信息确定的,S小于或等于N;根据第一障碍物的运动方式从S个障碍物中确定第一障碍物的周围障碍物,第一障碍物的周围障碍物为S个障碍物中在第一障碍物按照运动方式运动时与第一障碍物有潜在交互的障碍物;根据第一障碍物的周围障碍物的ID哈希值从第一缓存中获取周围障碍物的初始运动信息,第一障碍物的周围障碍物的ID哈希值是对第一障碍物的周围障碍物的ID进行哈希处理得到的。
在一个可行的实施例中,第一运动信息包括第一位置信息,在将障碍物资源池中第一障碍物的初始运动信息更新为第一运动信息的方面,仿真测试单元具体用于:
根据第一障碍物的初始位置信息从第二缓存中确定第一障碍物的初始位置信息对应的ID,若第一障碍物的初始位置信息对应的ID为该第一障碍物的ID,则将第二缓存中第一障碍物的初始位置信息更新为第一障碍物的第一位置信息;根据第一障碍物的ID哈希值将第一缓存中第一障碍物的初始运动信息更新为第一运动信息。
在一个可行的实施例中,第一运动信息包括第一位置信息,在根据自车的位置信息从障碍物资源池中获取n个障碍物的第一运动信息的方面,仿真测试单元具体用于:
根据自车的位置信息从第二缓存中确定M个障碍物的ID及第一位置信息,M个障碍物为位于自车的预设范围内的障碍物;自车的预设范围是基于自车的位置信息确定的,M为小于或等于N的正整数;根据预设交互方式和M个障碍物的第一位置信息从M个障碍物中确定n个障碍物;n个障碍物为与自车存在潜在交互的障碍物;根据n个障碍物中每个障碍物的ID哈希值从第一缓存中确定n个障碍物中每个障碍物的第一运动信息。
第三方面,本申请实施例还提供一种仿真测试装置,包括:
存储器和与该存储器耦合的处理器,其中,存储器中存储有指令,当处理器执行该指令时,执行如第一方面中的部分或者全部。
第四方面,本申请实施例提供一种芯片系统,该芯片系统应用于电子设备;芯片系统包括一个或多个接口电路,以及一个或多个处理器;所述接口电路和所述处理器通过线路互联;所述接口电路用于从所述电子设备的存储器接收信号,并向所述处理器发送所述信号,所述信号包括所述存储器中存储的计算机指令;当所述处理器执行所述计算机指令时,所述电子设备执行如第一方面所述方法的部分或全部。
第五方面,本申请实施例提供一种计算机可读存储介质,该计算机存储介质存储有计算机程序,所述计算机程序包括程序指令,所述程序指令当被处理器执行时使所述处理器执行如第一方面所述方法的部分或全部。
第六方面,本申请实施例提供一种计算机程序产品,其特征在于,包括计算机指令,当所述计算机指令在电子设备上运行时,使得所述电子设备执行如第一方面所述方法的部分或 全部。
本申请的这些方面或其他方面在以下实施例的描述中会更加简明易懂。
附图说明
为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1为十字路口交通场景示意图;
图2为本申请实施例提供的一种自动驾驶算法测试方法的流程示意图;
图3a为障碍物视野的示意图;
图3b为自车视野和障碍物视野的示意图;
图4为障碍物之间交互示意图;
图5为自车与障碍物之间交互示意图;
图6为数据通道的示意图;
图7为一种测试场景示意图;
图8为导航型障碍物的视野示意图;
图9为导航型障碍物的视野示意图;
图10为另一种测试场景示意图;
图11为本申请实施例提供的一种仿真测试装置的结构示意图;
图12为本申请实施例提供的另一种仿真测试装置的结构示意图;
图13为本申请实施例提供的另一种仿真测试装置的结构示意图。
具体实施方式
下面结合附图对本申请的实施例进行描述。
首先对本申请中的关键术语进行解释。
精细化轨迹障碍物:包括但不限于障碍物的类型,速度、起始点坐标、轨迹点坐标及终点坐标等属性的障碍物。在测试中,该类障碍物严格按照预先设定的速度和轨迹点从起始点运动到终点。其中,精细化轨迹障碍物的类型包括但不限于人、轿车、卡车、自行车、电动车。
导航型障碍物:相比于精细化轨迹障碍物,该类障碍物的属性包括类型、速度、起始点和终点。在测试场景中,该类障碍物只需按照预先设定的速度上限从起始点运动到终点,在此过程中会根据与其他障碍物的交互动态调整速度和运动轨迹。
宏观交通流:指汽车在道路上连续行驶形成的车流。广义上还包括其他车辆的车流和人流。在某段时间内,在不受横向交叉影响的路段上,交通流呈连续流状态;在遇到路口信号灯管制时,呈断续流状态。宏观交通流的属性包括但不限于障碍物的数量、障碍物的类型、速度、起始点和终点等。
路测障碍物:车辆在真实路测环境中行驶测量得到的障碍物,该障碍物包括车辆行驶过程中附近的机动车辆、行人、非机动车辆等。
参见图2,图2为本申请实施例提供的一种自动驾驶算法测试方法的流程示意图。如图2所示,该方法包括:
S201、仿真测试装置根据自动驾驶算法的测试功能从障碍物集合中获取N个障碍物。
其中,上述N个障碍物包括自车的障碍物和该自车的障碍物的周围障碍物。
可选地,在从障碍物集合中获取N个障碍物之后,为该N个障碍物中的每个障碍物分配ID,并对每个障碍物进行配置,从而得到每个障碍物的ID及配置信息,并获取N个障碍物中每个障碍物的ID及其配置信息;或者障碍物集合中包括各类障碍物的ID及其配置信息,因此在从障碍物集合中获取N个障碍物时,隐含了从障碍物集合中获取N个障碍物的ID及配置信息,不需要对障碍物进行额外的配置。
其中,上述多个第一障碍物的类型包括精细化轨迹障碍物、导航型障碍物、宏观交通流和路测障碍物中的部分或者全部。
其中,比如在需要测试基于自动驾驶算法行驶的自车是否具有正常换道、超车、过路口或者路边停车等功能时,在测试场景中需要引入导航型障碍物;再比如在需要测试基于自动驾驶算法行驶的自车在障碍物超车抢道(cut in),或者被障碍物cut out自车、挤压自车、横穿路口、非法逆行或闯红灯的情况下,自车能否正常合规行驶时,在测试场景中需要引入精细化轨迹障碍物;再比如在需要测试基于自动驾驶算法行驶的自车在交通拥堵的情况下能否正常合规行驶时,在测试场景中需要引入宏观交通流,以模拟交通拥堵;再比如在需要测试基于自动驾驶算法行驶行驶的自车在真实环境中能否正常合规行驶时,在测试场景中引入基于路测过程中得到的路测障碍物,以增加测试场景的真实性和随机性。
进一步地,精细化轨迹障碍物的配置信息包括但不限于障碍物的子类型、速度、起点坐标、轨迹点坐标和终点坐标等;导航型障碍物的配置信息包括但不限于障碍物的子类型、速度、起点坐标和终点坐标等;宏观交通流的配置信息包括但不限于障碍物的数量、障碍物的子类型、速度、起点坐标和终点坐标等;路测障碍物的配置信息包括但不限于障碍物的子类型、在路测过程中采集到的每个时刻的速度、航向角和坐标等。
在此需要指出的是,障碍物的子类型包括但不限于行人、动物、轿车、公交车、卡车、自行车和电动车等。
可选地,宏观交通流可以是预置于自动驾驶算法仿真测试装置中的,也可以是仿真测试装置从其他设备中获取的,比如仿真测试装置向其他设备发送宏观交通流获取请求,该获取请求中包括交通流的配置信息,其他设备基于宏观交通流的配置信息生成该宏观交通流,并将该宏观交通流发送至仿真测试装置,以响应上述宏观交通流获取请求。
在一个可行的实施例中,自动驾驶算法的功能有多个,比如停车避障、超车、向左变道、向右变道、跟车等,对于测试自动驾驶算法某一功能时,仿真测试装置可以获取该功能对应的配置文件,该配置文件中包括上述N个障碍物的ID及配置信息,从而实现根据自动驾驶算法的测试功能从障碍物集合中获取N个障碍物,并获取该N个障碍物中每个障碍物的ID及配置信息。
可选地,配置文件可以预置于仿真测试装置中,也可以是仿真测试装置从其他设备中获取的。
在此需要指出的是,仿真测试装置可以为自车的一部分,也可以为专门的测试服务器;当然这只是一个示例,不是对本申请的限定,仿真测试装置还可以为其他设备,在此不再一一列举。
S202、仿真测试装置将N个障碍物中的每个障碍物的初始运动信息保存至障碍物资源池。
其中,N个障碍物的初始运动信息是根据该第一障碍物的配置信息得到的,障碍物的运动信息包括但不限于障碍物的子类型、起点坐标、终点坐标、当前坐标、速度和航向角等。
在一个可选地实施例中,在获取N个障碍物的配置信息后,对该N个障碍物中的每个障碍物的配置信息进行解析,以得到该障碍物的初始运动信息;以N个障碍物中每个障碍物的ID为索引,将每个障碍物的ID及其初始运动信息保存至障碍物资源池中,以便对N个障碍物进行统一管理。
在一个可选地实施例中,障碍物资源池包括第一缓存和第二缓存,在获取N个障碍物的配置信息后,对该N个障碍物中的每个障碍物的配置信息进行解析,以得到该障碍物的初始运动信息,该初始运动信息包括初始位置信息,该位置信息可以是坐标,当然还可以是其他,在本申请中不做限定;对N个障碍物中每个第一障碍物的ID进行哈希处理,以得到该障碍物的ID哈希值,该ID哈希值用于指示第一缓存中的存储空间,或者ID哈希值可以看成存储地址,该存储地址所对应的存储空间包含于第一缓存;将N个障碍物中每个第一障碍物的初始运动信息保存至该第一障碍物的ID哈希值所指示的存储空间中;然后以N个障碍物中每个障碍物的初始位置信息为索引,将每个障碍物的ID及初始位置信息保存至障碍物资源池的第二缓存中,以便对N个障碍物进行统一管理,并且在后续查找与障碍物或者自车有交互的障碍物时,一般是基于位置信息来查找,因此在第二缓存中,基于位置信息可以快速找到所需的障碍物的ID,然后基于障碍物的ID从第一缓存中这些障碍物的运动信息,提高了搜索效率。
S203、仿真测试装置根据第一障碍物的ID从障碍物资源池中获取第一障碍物的周围障碍物的初始运动信息,并根据第一障碍物的周围障碍物的初始运动信息控制第一障碍物运行,得到第一障碍物的第一运动结果,将障碍物资源池中第一障碍物的初始位置信息更新为第一障碍物的第一运动结果。
在一个示例中,对于精细化轨迹障碍物,在测试过程中,按照简单车辆动力学模型和dusbin曲线模拟运行;其中,简单车辆动力学模型如下:
Figure PCTCN2021136414-appb-000001
其中,车体的原点位于车辆后轮的中心,x轴沿着车辆主轴方向,与车辆运动方向相同;车辆的运动速度为u s,方向盘的转角为φ,它与前轮的转角相同;前轮和后轮中心的距离为L,航向偏角为θ。比如轿车、公交车及卡车等精细化轨迹障碍物,均是按照上述方式运动的。
对于导航型障碍物,在测试过程中,以导航型障碍物的起点坐标所指示的位置为起点,根据测试场景中的其他障碍物的运动信息,实时规划出导航性障碍物的当前位置到终点坐标所指示的位置之间的导航路径;然后导航型障碍物按照实时规划出的路径行驶。
对于宏观交通流,在测试过程中,宏观交通流以按照其运动信息中起点坐标所指示的位置和终点坐标所指示的位置分别为起点和终点,并按照宏观交通流的运动信息中的速度来行驶。
由于路测障碍物的运动信息包括在路测过程中每个时刻的速度、航向角及坐标,因此为了模拟真实的行驶环境,在测试过程中,按照路测障碍物的运动信息中的速度、航向角和坐标等信息控制路测障碍物运动。
可选地,在控制障碍物运动时,可以不仅仅基于障碍物的运动信息,还可以基于运动信息和障碍物在测试过程中所要执行的动作来控制障碍物的运动,从而构建更加具有细节的测试场景。
在一个可行的实施例中,对于N个障碍物中的每个障碍物按照如下方式进行处理:
根据第一障碍物的ID从障碍物资源池中获取第一障碍物的周围障碍物的初始运动信息,并根据第一障碍物的周围障碍物的初始运动信息控制第一障碍物运行,得到第一障碍物的第一运动信息,将障碍物资源池中第一障碍物的初始运动信息更新为第一障碍物的第一运动信息;第一障碍物为N个障碍物中的任一个;
按照上述方式,可实现对障碍物资源池中N个障碍物的每个障碍物的运动信息的更新。
可选地,根据第一障碍物的ID从障碍物资源池中获取第一障碍物的周围障碍物的初始运动信息,包括:
根据第一障碍物的ID哈希值从障碍物资源池的第一缓存中获取第一障碍物的初始运动信息,第一障碍物的ID哈希值是对第一障碍物的ID进行哈希处理得到的,第一障碍物的初始运动信息包括第一障碍物的初始位置信息;根据第一障碍物的初始位置信息从障碍物资源池的第二缓存中确定S个障碍物的ID,该S个障碍物为位于第一障碍物的预设范围的障碍物,其中,第一障碍物的预设区域为以第一障碍物的位置为中心,半径为R的区域;当然第一障碍物的预设区域还可以为以第一障碍物的位置为中心的方形区域或者矩形区域,在此不做限定,第一障碍物的预设区域可以称为第一障碍物的视野;应理解,当根据第一障碍物的初始位置信息从障碍物资源池的第二缓存中确定S个障碍物时,上述第一障碍物的位置为该第一障碍物的初始位置信息所指示的位置;可选地,S个障碍物为第二缓存中位置与第一障碍物的初始位置信息所指示位置之间的距离小于的预设距离的障碍物;根据第一障碍物的运动方式从S个障碍物中确定第一障碍物的周围障碍物,该第一障碍物的周围障碍物为S个障碍物中在第一障碍物按照其运动方式运动时与第一障碍物有潜在交互的障碍物;根据第一障碍物的周围障碍物的ID哈希值从第一缓存中获取周围障碍物的初始运动信息,其中,第一障碍物的周围障碍物的ID哈希值是根据第一障碍物的周围障碍物的ID进行哈希处理得到的。
在获取第一障碍物的周围障碍物的初始运动信息后,根据第一障碍物的周围障碍物的初始运动信息控制第一障碍物运行,得到第一障碍物的第一运动信息。
举例说明,如图3a所示,以N个障碍物中的任一障碍物A为例,虚线框内的区域为障碍物A的预设区域,位于障碍物A的预设区域内的障碍物包括障碍物B、障碍物C和障碍物D。根据障碍物A、B、C和D中每个障碍物的位置信息,可以确定障碍物B位于障碍物A的前方,障碍物C和障碍物D分别位于障碍物A的右后方和左后方;假设障碍物A的运动方式为往左变道,障碍物D与障碍物A有潜在交互,因此障碍物A的周围障碍物为上述障碍物D;根据障碍物D的初始运动信息确定障碍物D是即将加速超车还是速度保持不变;若确定障碍物D是即将加速超车,则控制障碍物A保持速度和方向不变行驶,以避免障碍物A变道时与障碍物D发生碰撞,若确定障碍物D速度保持不变,则控制障碍物A向左变道,以完成向左变道操作;并获取障碍物A在此过程中的运动信息,该运动信息为第一运动信息,该第一运动信息包括第一位置信息。
再举例说明,如图4所示,对于车辆1、车辆2、车辆3和车辆4,其预设区域分别为如图4所示的第一区域、第二区域、第三区域和第四区域;对于车辆1,第一区域内的除了车辆1之外的车辆均可看成车辆1视野内的障碍物,可以基于车辆1的位置信息从障碍物资源池的第二缓存中确定的;第一区域内与车辆1同向行驶的且位于车辆1的左侧和前方的车辆 (黑线白底的车辆)对车辆1的行驶会产生影响,灰色白底的车辆对车辆1的行驶不会产生影响,黑线白底的车辆即为车辆1的目标障碍物,因此第一区域内黑线白底的车辆为车辆1的周围障碍物;
对于车辆2,第二区域内的除了车辆2之外的车辆均可看成车辆2视野内的障碍物,可以基于车辆2的位置信息从障碍物资源池的第二缓存中确定的;第二区域内与车辆2同向行驶的且位于车辆2的左上角和前方的车辆(黑线白底的车辆)对车辆2的行驶会产生影响,黑线白底的车辆即为车辆2的周围障碍物,因此第二区域内黑线白底的车辆为车辆2的周围障碍物;
对于车辆3,第三区域内的除了车辆3之外的车辆均可看成车辆3视野内的障碍物,可以基于车辆3的位置信息从障碍物资源池的第二缓存中确定的;第三区域内与车辆3位于同一车道且位于车辆3的前方的车辆(黑线白底的车辆)对车辆3的行驶会产生影响,灰色白底的车辆对车辆3的行驶不会产生影响,黑线白底的车辆即为车辆3的周围障碍物,因此第三区域内黑线白底的车辆为车辆3的周围障碍物;
对于车辆4,第四区域内的除了车辆4之外的车辆均可看成车辆4视野内的障碍物,可以基于车辆4的位置信息从障碍物资源池的第二缓存中确定的;第四区域内与车辆4同向行驶的且位于车辆4的左上角的车辆(黑线白底的车辆)对车辆4的行驶会产生影响,灰色白底的车辆对车辆4的行驶不会产生影响,黑线白底的车辆即为车辆4的周围障碍物,因此第四区域内黑线白底的车辆为车辆4的周围障碍物。
按照上述方法获取车辆1、车辆2、车辆3和车辆4的周围障碍物后,根据车辆1、车辆2、车辆3和车辆4的周围障碍物的ID从障碍物资源池中获取这些车辆的周围障碍物的第一运动信息。
在获取第一障碍物的第一运动信息后,根据第一障碍物的ID哈希值从障碍物资源池的第一缓存中获取第一障碍物的初始运动信息,该初始运动信息包括初始位置信息,根据初始位置信息从障碍物资源池的第二缓存中获取该初始位置信息对应的ID,若该ID为第一障碍物的ID,则将第二缓存中该ID对应的位置信息更新为第一位置信息;将第一缓存中第一障碍物的初始运动信息更新为第一障碍物的第一运动信息,以便于基于障碍物资源池对N个障碍物的管理。
再举例说明,如图3a所示,障碍物A为N个障碍物中的任一个,虚线框内的区域为障碍物A的预设区域,位于障碍物A的预设区域内的障碍物包括障碍物B、障碍物C和障碍物D,障碍物B、障碍物C和障碍物D为障碍物A视野内的障碍物。根据障碍物A、B、C和D中每个障碍物的位置信息,可以确定障碍物B位于障碍物A的前方,障碍物C和障碍物D分别位于障碍物A的右后方和左后方;假设障碍物A为导航型障碍物,导航型障碍物的轨迹不是固定的,因此障碍物A的运动方式可以为往左变道,障碍物A的目标障碍物为上述障碍物D;根据障碍物D的运动信息确定障碍物D是即将加速超车还是速度保持不变;若确定障碍物D是即将加速超车,则控制障碍物A保持速度和方向不变行驶,以避免障碍物A变道时与障碍物D发生碰撞;若确定障碍物D速度保持不变,则控制障碍物A向左变道,以完成向左变道操作;假设障碍物A为精确轨迹障碍物,精细化轨迹障碍物的行驶轨迹是固定的,因此运动方式可以为跟车,障碍物A的目标障碍物为上述障碍物B;根据障碍物B的运动信息确定障碍物B加速行驶还是减速行驶;若确定障碍物B加速行驶,则控制障碍物A加速行驶;若确定障碍物B减速行驶,则控制障碍物A减速行驶,以避免与障碍物A追尾;假设障碍物A和障碍物B为宏观交通流中的相邻障碍物,对于障碍物A,其预设交互方式为跟车, 障碍物A的第三障碍物为上述障碍物B;根据障碍物B的运动信息确定障碍物B加速行驶还是减速行驶;若确定障碍物B加速行驶,则控制障碍物A加速行驶;若确定障碍物B减速行驶,则控制障碍物A减速行驶。
按照上述方式控制障碍物A运行后,获取障碍物A的运动信息,并按照上述方法将障碍物A的第一运动信息更新障碍物资源池中障碍物A的运动信息。
通过引入障碍物之间的交互,能够更加真实地模拟现实驾驶场景,进而使得自动驾驶算法的测试结果更加准确。
S204、仿真测试装置根据自车的位置信息从障碍物资源池中获取n个障碍物的第一运动信息,n个第一障碍物为自车的障碍物,n小于或等于N。
具体地,根据自车的位置信息从障碍物资源池的第二缓存中确定M个障碍物的ID及第一运动信息,该M个障碍物为自车的预设范围内的障碍物,M小于或等于N;根据自车的预设交互方式和M个障碍物的第一位置信息从M个障碍物中确定n个障碍物,n个障碍物为与自车存在潜在交互的障碍物;根据n个障碍物中每个障碍物的ID哈希值从第一缓存中确定n个障碍物中每个障碍物的第一运动信息。
可选地,自车的预设区域可以为以自车坐标为中心,半径为r的圆形区域内,或者方形区域内,当然还可以是其他不规则形状。根据自车的预设交互方式和M个障碍物的第一位置信息从M个障碍物中确定n个障碍物,该n个障碍物为与自车有潜在交互的障碍物,比如当预设交互方式为自车向前行驶时,与自车有潜在交互的障碍物为位于自车前方的障碍物;再比如,当预设交互方式为自车即将向右侧变道时,与自车有潜在交互的障碍物为位于自车右侧及右后侧的障碍物;再比如,当预设交互方式为自车即将向左侧变道时,与自车有潜在交互的障碍物为位于自车左侧及左后侧的障碍物;再比如,当预设交互方式为自车倒车时,与自车有潜在交互的障碍物为位于自车后方内的障碍物。
举例说明,如图3b所示,位于障碍物A的预设区域内的障碍物包括障碍物B、障碍物C和障碍物D;根据障碍物A、B、C和D中每个障碍物的位置信息,可以确定障碍物B位于障碍物A的前方,障碍物C和障碍物D分别位于障碍物A的右后方和左后方;假设障碍物A的运动方式为往右变道,障碍物C与障碍物A有潜在交互,因此障碍物A的周围障碍物为上述障碍物C;根据障碍物C的初始运动信息确定障碍物C是速度保持不变行驶,控制障碍物A向右变道;对于自车,其预设范围内的障碍物包括障碍物A、障碍物B和障碍物C,假设自车的预设交互方式为向左变道,与自车有潜在交互的障碍物包括障碍物A和障碍物C;上述n个障碍物包括障碍物A和障碍物C。
在此需要指出的是,在对自动驾驶算法进行测试的过程中,N个障碍物和自车的运动信息都是在发生变化的,为了基于障碍物资源池更好地管理障碍物,实时更新障碍物资源池中的N个障碍物的运动信息。
在测试过程中实时更新障碍物资源池中N个障碍物的运动信息,具体通过以下方式实现:
实时获取第一障碍物的第二运动信息,该第二运动信息包括第二位置信息,该第二位置信息是第一障碍物的实时位置信息;然后根据第一障碍物的ID哈希值,从障碍物资源池的第一缓存中确定第一障碍物的运动信息的存储位置,进而获取第一障碍物的历史运动信息,该历史运动信息包括历史位置信息;根据第一障碍物的历史位置信息从第二缓存中获取该历史位置信息对应的ID,若第一障碍物的历史位置信息对应的ID为该障碍物的ID,则将第二缓存中第一障碍物的第二位置信息更新为第一障碍物的历史位置信息,并将第一缓存中第一障碍物的ID哈希值所指示的存储位置存储的第一障碍物的历史运动信息更新为该障碍物的第 二运动信息;第一障碍物为N个障碍物中的任一个;
按照对障碍物资源池中第一障碍物的运动信息的更新方式,对障碍物资源池中的N个障碍物中的每个障碍物进行运动信息的更新。
为了增加测试场景的丰富性和随机性,可以根据预设的方式或者用户的指令增加障碍物;其中预设的方式可以为:在预设时长内自车未与障碍物发生交互,则自动增加一些与自车有交互的障碍物,该障碍物可以为精细化轨迹障碍物、导航型轨迹障碍物、宏观交通流、路测障碍物或者其他障碍物;在根据预设的方式或者用户的指令获取新增障碍物的ID及配置信息,并对新增障碍物的配置信息进行解析,得到新增障碍物的初始运动信息,该初始运动信息包括新增障碍物的初始位置信息;对新增障碍物的ID进行哈希处理,以得到新增障碍物的ID哈希值,并将新增障碍物的初始运动信息保存至第一缓存中新增障碍物的ID哈希值所示的存储空间中;并以新增障碍物的初始位置信息为索引,将新增障碍物的ID和初始运动信息保存至障碍物资源池的第二缓存中。同时在后续过程中,可以按照上述方式更新障碍物资源池中新增障碍物的相关信息。
在一个可行的实施例中,在测试过程中,障碍物资源池中会存在一些在后续测试过程中与自车没有交互的障碍物,或者存在一些与第二障碍物没有交互的障碍物,其中,上述第二障碍物为在后续测试过程中与自车有潜在交互的障碍物,为了降低对障碍物资源池的管理开销,需要将障碍物资源池中这些障碍物的相关信息删除,删除的具体方式可以为:获取需要删除的障碍物的ID;对需要删除的障碍物的ID进行哈希处理,得到需要删除的障碍物的ID哈希值,基于需要删除的障碍物的ID哈希值从障碍物资源池的第一缓存中获取该障碍物的运动信息,该运动信息包括位置信息,基于位置信息从第二缓存中获取该位置信息对应的ID,然后将该ID及其对应的位置信息从第二缓存中删除;可选地,由于第二缓存中不同障碍物的位置信息的更新时间不一致,会导致具有相同位置信息的障碍物可能有多个,比如在时刻t1时,障碍物z1和障碍物z2的位置信息分别为ad1和ad2,在时刻t2时,障碍物z1的位置信息从ad1更新为ad2,障碍物z2的位置信息没更新,此时,在第二缓存中障碍物z1的位置信息与障碍物z2的位置信息相同,基于位置信息ad2可从第二缓存中获取障碍物的ID:z1和z2,因此根据需要删除的障碍物的ID将该障碍物的位置信息及ID从第二缓存中删除,根据需要删除的障碍物的ID哈希值从第一缓存中将需要删除的障碍物的运动信息删除。
可选地,删除的具体方式可以为:获取需要删除的障碍物的ID;对需要删除的障碍物的ID进行哈希处理,得到需要删除的障碍物的ID哈希值,基于需要删除的障碍物的ID哈希值从障碍物资源池的第一缓存中获取需要删除的障碍物的运动信息,该运动信息包括位置信息,基于位置信息从第二缓存中获取该位置信息对应的ID,由于同一位置信息在第一缓存和第二缓存中存储精度可能不一致,导致基于从第一缓存中获取的位置信息无法从第二缓存中确定该位置信息对应的ID,因此基于从第一缓存中获取的位置信息从第二缓存中获取一个或多个ID,该一个或多个ID对应的位置信息与从第一缓存中获取的位置信息之间差值的绝对值小于预设距离,然后将一个或多个ID及其对应的位置信息中与需要删除障碍物的ID相同的ID及其对应的位置信息从第二缓存中删除。
在仿真测试场景中引入障碍物资源池,实现了对仿真测试场景中的障碍物的统一管理。
需要指出的是,对于测试场景中的任一障碍物X,从仿真测试装置角度可以将障碍物X看成一个函数或者模型,该函数或者模型运行于仿真测试装置的CPU上,障碍物资源池保存运行内存上,运行内存中包括一个消息队列;在测试过程中需要实时向障碍物资源池发送障碍物X的运动信息,并且还可以从障碍物资源池中获取障碍物X的预设区域内的第三障碍物, 还可以从障碍物资源池中获取任一障碍物的运动信息;具体是CPU向运行内存发送上报消息,该上报消息携带有障碍物X的ID哈希值及障碍物X的实时运动信息,运行内存将上报消息保存在消息队列中,CPU还可以向运行内存发送第一获取请求消息,该第一获取请求消息用于请求获取障碍物X的预设范围内的障碍物的ID,且该第一获取请求消息携带有障碍物X的ID哈希值;运行内存将该第一获取请求消息保存在消息队列中;CPU还可以向运行内存发送第二获取请求消息,该第二获取请求消息用于请求获取障碍物E的运动信息,该第二获取请求消息携带有障碍物E的ID哈希值;运行内存可以从消息队列中依次或者并行读取消息并执行相应的操作;比如若读取的是上报消息,则运行内存根将上报消息中携带的ID哈希值将携带的实时运动信息保存至障碍物资源池中;若读取的是第一获取请求消息,运行内存根据障碍物X的ID哈希值从障碍物资源池的第一缓存中获取障碍物X的运动信息,该运动信息包括位置信息,再根据障碍物X的位置信息从第二缓存中获取位于障碍物X的预设范围内的障碍物的ID;运行内存在获取障碍物X的预设范围内的障碍物的ID后,将向CPU发送响应消息,该响应消息携带有障碍物X的预设范围内的障碍物的ID;若读取的是第二获取请求消息,运行内存根据障碍物E的ID哈希值从障碍物资源池中的第一缓存中获取障碍物E的运动信息,并向CPU发送携带障碍物E的运动信息的第二响应消息。其中上报消息不需要响应,因此上报消息可以看成异步请求消息;第一获取请求消息和第二获取请求消息需要响应,因此第一获取请求消息和第二获取请求消息可以看成同步请求消息,如图6所示。在运行内存针对任一消息执行完对应的操作后,运行内存将该消息从消息队列中删除。上述消息队列可以看成障碍物与障碍物资源池之间的数据通道。通过对多个上报消息或者多个请求消息的并行处理,确保了资源池与障碍物之间数据通道通信的高效低时延。
在确定需要发送与障碍物X相关的请求消息时,其中,请求消息中包括障碍物X的信息,包括但不限于障碍物X的ID哈希值、位置以及视野范围内障碍物的信息,将障碍物X的信息保存至障碍物X的请求缓存中,打包成上报消息或者请求消息,对于请求消息,CPU在得到对应的响应消息后,将该响应消息保存至障碍物X的响应缓存中,如图6所示。
可选地,第一获取请求消息用于请求获取的可以是视野内的障碍物的ID,也可以是视野内的障碍物的运动信息;在请求获取的是视野内的障碍物的运动信息时,在基于视野内的ID从障碍物中确定目标障碍物后,需要再发送用于请求获取目标障碍物的运动信息的请求消息。
按照上述方式,可以实现多个障碍物,比如包括精确轨迹障碍物、导航型障碍物、宏观交通流和路测障碍物之间的交互,更加真实地模拟现实驾驶环境,提高了自动驾驶算法测试结果的准确性。
S205、根据n个障碍物的第一运动信息获取与自车与n个第一障碍物的交互结果,并根据该交互结果确定自动驾驶算法的测试结果。
其中,交互结果包括但不限于安全跟车、追尾、安全超车、超车发生碰撞、避障失败与障碍物发生碰撞、避障成功等。
举例说明,如图3b所示,位于障碍物A的预设区域内的障碍物包括障碍物B、障碍物C和障碍物D;根据障碍物A、B、C和D中每个障碍物的位置信息,可以确定障碍物B位于障碍物A的前方,障碍物C和障碍物D分别位于障碍物A的右后方和左后方;假设障碍物A的运动方式为往右变道,障碍物C与障碍物A有潜在交互,因此障碍物A的周围障碍物为上述障碍物C;根据障碍物C的初始运动信息确定障碍物C是速度保持不变行驶,控制障碍物A向右变道;对于自车,其预设范围内的障碍物包括障碍物A、障碍物B和障碍物C,假设自车的预设交互方式为向左变道,与自车有潜在交互的障碍物包括障碍物A和障碍物C; 按照障碍物C的运动信息确定障碍物C速度保持不变行驶,若自车向右变道,则自车与障碍物的交互结果包括与障碍物A发生碰撞,与障碍物C为发生碰撞;若自车保持速度和方向不变行驶,则自车与障碍物的交互结果包括与障碍物A和障碍物C均未发生碰撞。
再举例说明,自车向前行驶,上述第二障碍物位于自车前方的障碍物,可以根据自车的坐标及上述多个第一障碍物的坐标从多个第一障碍物中确定一个或多个第二障碍物,第二障碍物为多个第一障碍物中位于自车前方的障碍物;假设预设交互动作为跟车,则第三障碍物为与自车位于同一车道的障碍物,如图5中的a图所示,第三障碍物为障碍物1;假设根据障碍物1的运动信息确定障碍物1是减速,且自车此时是加速或者速度保持不变,则确定交互结果是追尾;假设根据障碍物1的运动信息确定障碍物1是加速,且自车此时是减速或者速度保持不变,则确定交互结果是跟车失败。
假设预设交互动作为自车向前行驶,如图5中b图所示,第三障碍物为障碍物2,根据障碍物2的运动信息确定障碍物2即将插入本车道,此时可以控制自车可以加速超车、或者减速避让,或者停车避让;交互结果可以为加速安全通过、加速超车发生碰撞、减速或停车避让成功;
假设预设交互动作为向右变道,第三障碍物为左后方及后方的障碍物,如图5中的c图所示的障碍物3;根据障碍物3的运动信息确定障碍物3速度保持不变行驶;此时可以自车向左变道并加速,交互结果可以为向左变道成功。
按照上述方式,可以得到自车与障碍物的交互结果。
在一个可选的实施例中,在仿真测试装置的显示界面上实时显示自车及自车视野内障碍物,或者实时显示自车与N个障碍物。
在一个示例中,可以从任务完成度、是否符合交通规则、安全、车辆舒适性和通行效率中的任一维度或者多个维度组合对交互结果进行分析,进而确定自动驾驶算法的测试结果,该测试结果包括通过测试和未通过测试。
可选地,交互结果可以分为安全驾驶和危险驾驶,分别统计交互结果中安全驾驶的次数和危险驾驶的次数,然后根据安全驾驶的次数和危险驾驶的次数计算安全驾驶的比例;当安全驾驶的比例高于预设比例时,则确定自动驾驶算法通过测试;当安全驾驶的比例不高于预设比例时,则确定自动驾驶算法通过测试。
当然,交互结果还可以基于自动驾驶算法任务完成度、是否符合交通规则、车辆舒适性和通行效率任一维度;当然还可以基于任务完成度、是否符合交通规则、车辆舒适性和通行效率多个维度对交互结果进行分析,进而确定自动驾驶算法是否通过测试。
在一个具体的示例中,以在宏观交通流背景中测试自车对导航型障碍物进行超车抢道的功能,具体步骤包括:
S801、在测试场景中部署精细化轨迹障碍物。
具体地,获取精细化轨迹障碍物的配置信息,精细化轨迹障碍物的配置信息包括但不限于障碍物的子类型、起点坐标,终点坐标、行驶轨迹点坐标和速度,其中,障碍物的子类型为汽车。在测试过程中,根据配置信息,按照车辆动力学模型及dubins曲线控制精细化轨迹障碍物运行。车辆动力学模型可参见上述实施例的相关描述,在此不再叙述。
S802、在测试场景中部署导航型障碍物。
具体地,获取导航型障碍物的配置信息,该配置信息包括但不限于障碍物的子类型、速度、起点坐标和终点坐标。基于起点坐标和终点坐标为导航型障碍物规划行驶路径。在测试过程中,导航型障碍物可进行避障、变道、与其他障碍物进行交互,比如导航型障碍物在行 驶过程中,发现前方有障碍物影响行驶,则导航型障碍物停车或者变道,体现了障碍物之间的交互。如图8所示,两条黄线内的区域为导航型障碍物的视野,两条黄线内的一条线为导航型障碍物的轨迹线。
S803、在测试场景中部署宏观交通流。
具体地,获取宏观交通流的配置信息,该配置信息包括但不限于障碍物的数量、障碍物的子类型、速度、起点坐标和终点坐标等。宏观交通流的配置信息可以是导入的配置文件中解析得到的,也可以是用户输入的;在得到该配置信息后,将该配置信息发送至接入的第三方交通流软件中,第三方交通流软件基于输入的配置信息生成宏观交通流,并将生成的宏观交通流输入至仿真测试软件中,已完成在测试场景中部署宏观交通流。
S804、构建障碍物资源池与障碍物进行数据交互的数据通道。
在此需要说明的是,数据通道的相关描述可看见针对上述图6的描述,在此不再叙述。
通过对多个上报消息或者多个请求消息的并行处理,确保了资源池与障碍物之间通信的高效低时延。
S805、以障碍物ID作为关键信息,利用哈希算法对障碍物信息进行存储。
具体地,精细化轨迹障碍物的配置信息、导航型障碍物的配置信息和宏观交通流的配置信息中分别解析出精细化轨迹障碍物的初始运动信息、导航型障碍物的初始运动信息和宏观交通流的初始运动信息;以这些障碍物的ID为索引,将这些障碍物的运动信息保存至障碍物资源池中。
可选地,分别对精细化轨迹障碍物ID、导航型障碍物ID和宏观交通流的ID进行哈希处理,以得到精细化轨迹障碍物ID哈希值、导航型障碍物ID哈希值和宏观交通流的ID哈希值;将上述障碍物的初始运动信息保存至障碍物资源池的第一缓存中上述障碍物的ID哈希值所指示的存储空间中并以这些障碍物的初始位置信息为索引,将这些障碍物的位置信息及ID保存至障碍物资源池的第二缓存中。通过引入障碍物资源池,实现了对测试场景中的障碍物进行统一管理。
在一个可行的实施例中,在测试过程中,测试场景内的障碍物的运动信息是在发生变化的,为了便于障碍物资源池管理测试场景中的障碍物,实时获取测试场景内各障碍物的运动信息,并更新障碍物资源池中障碍物的运动信息,具体实现过程可参见步骤S203的相关描述。
在一个可行的实施例中,在测试过程中,为了增加测试场景的复杂性,可以根据用户指令向测试场景中增加新的障碍物,并将新增障碍物的ID及运动信息保存至障碍物资源池,以便于管理,具体实现过程可参见步骤S203的相关描述。其中,新增的障碍物可以为精细化轨迹障碍物、导航型障碍物、宏观交通流和路测障碍物中的部分或者全部。
在一个可行的实施例中,在测试过程中,测试场景中会存在对自车行驶没影响的障碍物,对于这些障碍物,可以根据这些障碍物的ID,从障碍物资源池将这些障碍物的运动信息删除,具体实现过程可参见步骤S203的相关描述,从而实现将这些障碍物从测试场景中删除。其中,这些障碍物可以为精细化轨迹障碍物、导航型障碍物、宏观交通流和路测障碍物中的部分或者全部。
S806、根据导航型障碍物的ID,从障碍物资源池中获取导航型障碍物的视野内的障碍物及其运动信息;再根据导航型障碍物的运动方式从导航型障碍物视野内的障碍物确定出目标障碍物及其运动信息,并根据目标障碍物的运动信息控制导航型障碍物运行。
具体地,CPU向运行内存发送携带导航型障碍物的ID哈希值的获取请求消息,该获取请求消息用于请求获取导航型障碍物视野范围内的障碍物;运动内存根据障碍物ID哈希值从 障碍物资源池的第一缓存中获取导航型障碍物的运动信息,该运动信息包括位置信息;运行内存根据导航型障碍物的位置信息从障碍物资源池的第二缓存中获取位于导航型障碍物的视野内的障碍物的位置及ID;或者直接根据获取请求消息中携带的导航型障碍物的位置,及障碍物资源池中各障碍物的位置,获取位于导航型障碍物的视野内的障碍物;其中,导航型障碍物的视野为以导航型障碍物为中心的圆形区域或者方形区域,如图9所示,当然还可以是其他形状;向CPU发送携带导航型障碍物的视野内的障碍物的ID及运动信息的响应消息;CPU根据导航型障碍物的运动方式从导航型障碍物视野内的障碍物中获取目标障碍物,比如导航型障碍物向前行驶时,导航型障碍物的目标障碍物包括导航型障碍物视野内的障碍物中位于自车前方或者右前方的障碍物;再比如导航型障碍物向左变道时,导航型障碍物的目标障碍物包括导航型障碍物视野内的障碍物中位于自车左侧或者左后方的障碍物;最后根据目标障碍物的运动信息预测目标障碍物的运动方式,根据目标障碍物的运动方式控制导航型障碍物运动,从而实现障碍物之间的交互。比如导航型障碍物向前行驶时,前方障碍物停止不动,导航型障碍物停车或者变道以免追尾,如图9所示,导航型障碍物的前方有一条横线,表示导航型障碍物停车。
在此需要说明的是,障碍物与资源池之间的数据通道的具体描述可参见图6的相关描述,在此不再叙述。
S807、在自车向右变道时获取自车与自车的障碍物的交互结果。
具体地,根据自车的位置信息从障碍物资源池中获取T个第二障碍物的ID和运动信息,该T个第二障碍物为自车视野内的障碍物,T为大于0的整数;如图7所示,虚线框内的区域为自车的视野,自车视野内的障碍物包括宏观交通流的部分、精细化轨迹障碍物和导航型障碍物;根据自车预设的交互方式(比如向右变道)和T个第二障碍物的位置信息从T个第二障碍物中确定自车的障碍物,并获取自车的障碍物的运动信息,自车的障碍物为位于自车右后方的导航型障碍物;根据右前方的导航型障碍物的运动信息及自车的运动信息确定自车与右后方导航型障碍物的交互结果。交互结果包括变道成功且变道后自车位于右后方障碍物的前方、变道成功且变道后自车位于右后方障碍物的后方或者自车与右后方障碍物发生碰撞。
S808、根据交互结果确定自动驾驶算法的测试结果。
比如,若交互结果为变道成功且变道后自车位于右后方障碍物的前方或者变道成功且变道后自车位于右后方障碍物的后方,自动驾驶算法通过测试;若交互结果为自车与右后方障碍物发生碰撞,则自动驾驶算法未通过测试。
通过引入障碍物资源池,实现了对测试场景中的障碍物进行统一管理;对测试场景中障碍物的增加、删除和更新,也只需要对障碍物资源池进行管理,不需要多节点多数据通道互相传递数据,简化了仿真平台数据通信的复杂度,提高了仿真效率;在测试场景中增加障碍物,可实现对指定场景的细节仿真,极大提高了仿真场景的灵活性和智能性;通过基于障碍物的位置在障碍物资源池的第二缓存中确定该障碍物的视野内的障碍物,在障碍物资源池中是以位置信息为索引的,通过位置信息在第二缓存中搜索障碍物的视野内的障碍物,提高了查询效率,高效地实现了障碍物之间的交互。
在另一个具体的示例中,以在路测障碍物与其他障碍物构成的HIL场景下测试路测障碍物对自车向右变道策略的影响,具体步骤包括:
S1001、在测试场景中部署精细化轨迹障碍物。
S1002、在测试场景中部署导航型障碍物。
S1003、在测试场景中部署宏观交通流。
在此需要说明的是,步骤S1001-S1003的具体实现过程可参见步骤S801-S803的相关描述,在此不再叙述。
S1004、在测试场景中配置路测障碍物。
具体地,获取路测障碍物的配置信息,该配置信息包括但不限于路测障碍物的子类型,路测障碍物在真实路测场景中的初始位置和速度等。至此构建出如图10所示的测试场景。
S1005、构建障碍物资源池与障碍物进行数据交互的数据通道。
在此需要说明的是,数据通道的相关描述可看见针对上述图6的描述,在此不再叙述。
通过对多个上报消息或者多个请求消息的并行处理,确保了资源池与障碍物之间通信的高效低时延。
S1006、以障碍物ID作为关键信息,利用哈希算法对障碍物信息进行存储。
具体地,精细化轨迹障碍物的配置信息、导航型障碍物的配置信息、宏观交通流的配置信息和路测障碍物的配置信息中分别解析出精细化轨迹障碍物的初始运动信息、导航型障碍物的初始运动信息、宏观交通流的初始运动信息和路测障碍物的的初始运动信息;以这些障碍物的ID为索引,将这些障碍物的运动信息保存至障碍物资源池中。
可选地,分别对精细化轨迹障碍物ID、导航型障碍物ID和宏观交通流的ID进行哈希处理,以得到精细化轨迹障碍物ID哈希值、导航型障碍物ID哈希值和宏观交通流的ID哈希值;将上述障碍物的初始运动信息保存至障碍物资源池的第一缓存中上述障碍物的ID哈希值所指示的存储空间中并以这些障碍物的初始位置信息为索引,将这些障碍物的位置信息及ID保存至障碍物资源池的第二缓存中。通过引入障碍物资源池,实现了对测试场景中的障碍物进行统一管理。并且在障碍物资源池中以位置信息为索引存储障碍物的ID,可以快速搜素到障碍物视野内的障碍物的ID,进而基于ID获取障碍物的运动信息,提高了搜索效率。
S1007、根据路测障碍物的ID,从障碍物资源池中获取路测障碍物的视野内的障碍物及其运动信息;再根据路测障碍物的运动方式从路测障碍物视野内的障碍物中确定目标障碍物及其运动信息,并根据目标障碍物的运动信息控制路测障碍物运行。
如图10所示,根据路测障碍物位置确定的路侧障碍物视野内的障碍物包括宏观交通流、在路测障碍物右后方行驶的自车;路测障碍物跟在与其同向行驶的宏观交通流后行驶,因此路测障碍物的目标障碍物为其同向行驶的宏观交通流;当该宏观交通流减速或者停车时,为了避免路测障碍物追尾,控制路测障碍物向右变道。路测障碍物与宏观交通流进行交互,路测障碍物与该宏观交通流构成一种增强型HIL场景。
S1008、在自车向右变道时获取自车与自车的障碍物的交互结果。
具体地,根据自车的位置信息从障碍物资源池中获取T个第二障碍物的ID和运动信息,该T个第二障碍物为自车视野内的障碍物,T为大于0的整数;如图10所示,自车的视野如图10中的虚线框所示,T个个第二障碍物包括位于虚线框内的障碍物,根据预设交互方式,比如向右变道,及T个第二障碍物的位置信息从T个第二障碍物中确定自车的障碍物,自车的障碍物包括位于自车右后方的导航型障碍物和位于自车右前方且向自车所在车道进行变道的路测障碍物;获取自车的障碍物的运动信息;根据自车的障碍物的运动信息及自车的运动信息确定自车与自车的障碍物的交互结果。交互结果包括自车停止向右变道且与路测障碍物发生碰撞、自车停止向右变道且未与路测障碍物发生碰撞、自车向右变道时与右后方导航型障碍物发生碰撞或者自车向右变道时未与右后方导航型障碍物发生碰撞。
S1009、根据交互结果确定自动驾驶算法的测试结果。
具体地,自车与右后方障碍物或者路测障碍物发生碰撞时,确定自动驾驶算法未通过测试;自车与右后方障碍物或者路测障碍物未发生碰撞时,确定自动驾驶算法通过测试。
通过引入路测障碍物,并且利用路测障碍物与其他障碍物的交互,构建了增强型HIL场景,有效的利用道路测试采集的数据,使得路测采集的真实场景内的障碍物具有动态交互性,并为复杂场景的部署提供了便利。
参见图11,图11为本申请实施例提供的一种仿真测试装置的结构示意图。如图11所示,该仿真测试装置1100包括:精细化轨迹障碍物生成模块1101、导航型障碍物生成模块1102、交通流模块1103、路测障碍物模块1104、资源池模块1105、仿真模块1106和障碍物可视化模块1107;
精细化轨迹障碍物生成模块1101,用于根据精细化障碍物的属性生成精细化轨迹障碍物,再采用车辆动力学模型及Dubins曲线,根据精细化障碍物的属性生成精细化轨迹障碍物;其中,该精细化轨迹障碍物的属性包括但不限于障碍物的类型、速度、起点坐标、轨迹点坐标、终点坐标等;
导航型障碍物生成模块1102,用于根据导航型障碍物的属性生成导航型障碍物,导航型障碍物的属性包括但不限于障碍物的类型、速度、起点坐标、终点坐标。(通过高精度地图基于起点坐标和终点坐标该障碍物的轨迹);
交通流模块1103,用于在测试场景中部署宏观交通流,该交通流的属性,包括但不限于交通流中障碍物的数量、障碍物类型、起点坐标和终点坐标等;根据交通流的属性生成交通流;可选地,通过第三方交通流软件根据交通流的属性生成交通流;或者将交通流的属性发送至第三方设备,第三方设备通过第三方交通流软件根据交通流的属性生成交通流,并将该交通流发生至交通流模块1103;
路测障碍物模块1104,用于在测试场景中部署路测障碍物,路测障碍物的属性包括但不限于路测障碍物的子类型、坐标、速度和航向角的。需要指出的是,路测障碍物在与其他障碍物(比如精细化轨迹障碍物、导航型障碍物或者宏观交通流)进行交互时,路测障碍物与其他障碍物构成一种增强型HIL场景。
资源池模块1105,用于根据上述各障碍物的ID存储上述各障碍物的运动信息。具体地,障碍物资源池包括第一缓存和第二缓存,对于障碍物的ID进行哈希处理,得到障碍物的ID哈希值,并以ID哈希值为存储地址,将障碍物的运动信息存储至第一缓存中ID哈希值所指示的存储空间中;并以障碍物的位置信息为索引,将障碍物的ID和位置信息保存至第二缓存中。
仿真模块1106,用于在对自动驾驶算法进行测试的过程中,对测试场景中的每个障碍物,实时获取与该障碍物有潜在交互的障碍物的运动信息,并基于这些运动信息控制上述障碍物运动,实现障碍物与障碍物之间的交互;对于基于自动驾驶算法运动的自车,获取与自车有潜在交互的障碍物的运动信息,并基于自车的运动信息和这些障碍物的运动获取交互结果,并基于交互结果判断自动驾驶算法是否通过测试。
在此需要指出的是,仿真模块1106的功能实现过程具体参见步骤S203-S205、S805-S807及S1006-S1009的相关描述,在此不再叙述。
障碍物可视化模块1107,用于在显示界面上实时显示上述各障碍物及自车之间的位置关系。
参见图12,图12为本申请实施例提供的一种仿真测试装置的结构示意图。如图12所示,该仿真测试装置1200包括:
获取单元1201,用于按照自动驾驶算法的测试功能从障碍物集合中获取N个障碍物;该N个障碍物包括自车的障碍物和自车障碍物的周围障碍物,N个障碍物的类型包括精细化轨迹障碍物、导航型障碍物、宏观交通流和路测障碍物中的部分或者全部;N为大于0的整数;
存储单元1202,用于将N个障碍物中每个障碍物的ID及初始运动信息保存至障碍物资源池;
仿真测试单元1203,用于根据第一障碍物ID从障碍物资源池中获取第一障碍物的周围障碍物的运动信息,并根据第一障碍物的周围障碍物的运动信息控制第一障碍物运行,得到每个障碍物的第一运动信息;将障碍物资源池中第一障碍物的初始运动信息更新为第一障碍物的第一运动信息;根据自车的位置信息从障碍物资源池获取n个障碍物的第一运动信息,n个障碍物为自车的障碍物,n小于或等于N;根据n个障碍物的第一运动信息获取自车与n个障碍物的交互结果;根据交互结果确定自动驾驶算法的测试结果。
在一个可行的实施例中,障碍物资源池包括第一缓存和第二缓存,初始运动信息包括初始位置信息,仿真测试装置1200还包括:
处理单元1204,用于对N个障碍物中的每个障碍物的ID进行哈希处理,得到每个障碍物的ID哈希值,每个障碍物的ID哈希值用于指示该障碍物的运动信息在第一缓存中的存储空间;
存储单元1202具体用于:
将N个障碍物中每个障碍物的初始运动信息保存至第一缓存中该障碍物的ID哈希值所指示的存储空间中;以N个障碍物中的每个障碍物的初始位置信息为索引,将每个障碍物的ID及初始位置信息保存至第二缓存中。
在一个可行的实施例中,障碍物资源池包括第一缓存和第二缓存,在根据第一障碍物的ID从障碍物资源池中获取第一障碍物的周围障碍物的初始运动信息的方面,仿真测试单元1203具体用于:
根据第一障碍物的ID哈希值从第一缓存中获取第一障碍物的初始运动信息,该初始运动信息包括初始位置信息,第一障碍物的ID哈希值是对第一障碍物的ID进行哈希处理得到的;根据第一障碍物的初始位置信息从第二缓存中获取S个障碍物的ID,S个障碍物为位于第一障碍物的预设区域内的障碍物,第一障碍物的预设区域是基于第一障碍物的初始位置信息确定的,S小于或等于N;根据第一障碍物的运动方式从S个障碍物中确定第一障碍物的周围障碍物,第一障碍物的周围障碍物为S个障碍物中在第一障碍物按照运动方式运动时与第一障碍物有潜在交互的障碍物;根据第一障碍物的周围障碍物的ID哈希值从第一缓存中获取周围障碍物的初始运动信息,第一障碍物的周围障碍物的ID哈希值是对第一障碍物的周围障碍物的ID进行哈希处理得到的。
在一个可行的实施例中,第一运动信息包括第一位置信息,在将障碍物资源池中第一障碍物的初始运动信息更新为第一运动信息的方面,仿真测试单元1203具体用于:
根据第一障碍物的初始位置信息从第二缓存中确定第一障碍物的初始位置信息对应的ID,若第一障碍物的初始位置信息对应的ID为该第一障碍物的ID,则将第二缓存中第一障碍物的初始位置信息更新为第一障碍物的第一位置信息;根据第一障碍物的ID哈希值将第一缓存中第一障碍物的初始运动信息更新为第一运动信息。
在一个可行的实施例中,第一运动信息包括第一位置信息,在根据自车的位置信息从障 碍物资源池中获取n个障碍物的第一运动信息的方面,仿真测试单元1203具体用于:
根据自车的位置信息从第二缓存中确定M个障碍物的ID及第一位置信息,M个障碍物为位于自车的预设范围内的障碍物;自车的预设范围是基于自车的位置信息确定的,M为小于或等于N的正整数;根据预设交互方式和M个障碍物的第一位置信息从M个障碍物中确定n个障碍物;n个障碍物为与自车存在潜在交互的障碍物;根据n个障碍物中每个障碍物的ID哈希值从第一缓存中确定n个障碍物中每个障碍物的第一运动信息。
需要说明的是,上述各单元(获取单元1201、存储单元1202、仿真测试单元1203和处理单元1204)用于执行上述方法的步骤S201-S205的相关内容。其中,获取单元1201用于执行步骤S201的相关内容,存储单元1202用于执行步骤S202的相关内容,仿真测试单元用于执行步骤S203-S205的相关内容。
在本实施例中,仿真测试装置1200是以单元的形式来呈现。这里的“单元”可以指特定应用集成电路(application-specific integrated circuit,ASIC),执行一个或多个软件或固件程序的处理器和存储器,集成逻辑电路,和/或其他可以提供上述功能的器件。此外,以上获取单元1201、存储单元1202、仿真测试单元1203和处理单元1204可通过图13所示的仿真测试装置的处理器1301来实现。
如图13所示仿真测试装置1300可以以图13中的结构来实现,该仿真测试装置1300包括至少一个处理器1301,至少一个存储器1302以及至少一个通信接口1303。所述处理器1301、所述存储器1302和所述通信接口1303通过所述通信总线连接并完成相互间的通信。
处理器1301可以是通用中央处理器(CPU),微处理器,特定应用集成电路(application-specific integrated circuit,ASIC),或一个或多个用于控制以上方案程序执行的集成电路。
通信接口1303,用于与其他设备或通信网络通信,如以太网,无线接入网(RAN),无线局域网(Wireless Local Area Networks,WLAN)等。
存储器1302可以是只读存储器(read-only memory,ROM)或可存储静态信息和指令的其他类型的静态存储设备,随机存取存储器(random access memory,RAM)或者可存储信息和指令的其他类型的动态存储设备,也可以是电可擦可编程只读存储器(Electrically Erasable Programmable Read-Only Memory,EEPROM)、只读光盘(Compact Disc Read-Only Memory,CD-ROM)或其他光盘存储、光碟存储(包括压缩光碟、激光碟、光碟、数字通用光碟、蓝光光碟等)、磁盘存储介质或者其他磁存储设备、或者能够用于携带或存储具有指令或数据结构形式的期望的程序代码并能够由计算机存取的任何其他介质,但不限于此。存储器可以是独立存在,通过总线与处理器相连接。存储器也可以和处理器集成在一起。
其中,所述存储器1302用于存储执行以上方案的应用程序代码,并由处理器1301来控制执行。所述处理器1301用于执行所述存储器1302中存储的应用程序代码。
存储器1302存储的代码可执行以上提供的任一种自动驾驶算法的测试方法,比如:按照自动驾驶算法的测试功能从障碍物集合中获取N个障碍物,N个障碍物包括自车的的障碍物和该自车的障碍物的周围障碍物,N为大于0的整数;将N个障碍物中每个障碍物的ID及初始运动信息保存至障碍物资源池中;根据第一障碍物的ID从障碍物资源池中获取第一障碍物的周围障碍物的运动信息,并根据第一障碍物的周围障碍物的运动信息控制第一障碍物运行,得到第一障碍物的运动信息;将每个障碍物的运动信息保存至障碍物资源池中;根据自车的位置信息从障碍物资源池中获取n个障碍物的第一运功信息,该n个障碍物为自车的障 碍物,n小于或等于N,根据n个障碍物的第一运动信息获取自车与n个障碍物的交互结果;根据交互结果确定自动驾驶算法的测试结果。
本申请实施例还提供一种计算机存储介质,其中,该计算机存储介质可存储有程序,该程序执行时包括上述方法实施例中记载的任何一种自动驾驶算法的测试方法的部分或全部步骤。
需要说明的是,对于前述的各方法实施例,为了简单描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本申请并不受所描述的动作顺序的限制,因为依据本申请,某些步骤可以采用其他顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于优选实施例,所涉及的动作和模块并不一定是本申请所必须的。
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其他实施例的相关描述。
在本申请所提供的几个实施例中,应该理解到,所揭露的装置,可通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性或其它的形式。
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。
所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储器中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储器中,包括若干指令用以使得一台计算机设备(可为个人计算机、服务器或者网络设备等)执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储器包括:U盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、移动硬盘、磁碟或者光盘等各种可以存储程序代码的介质。
本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是可以通过程序来指令相关的硬件来完成,该程序可以存储于一计算机可读存储器中,存储器可以包括:闪存盘、只读存储器(英文:Read-Only Memory,简称:ROM)、随机存取器(英文:Random Access Memory,简称:RAM)、磁盘或光盘等。
以上对本申请实施例进行了详细介绍,本文中应用了具体个例对本申请的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本申请的方法及其核心思想;同时,对于本领域的一般技术人员,依据本申请的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本申请的限制。

Claims (14)

  1. 一种自动驾驶算法的测试方法,其特征在于,包括:
    按照所述自动驾驶算法的测试功能从障碍物集合中获取N个障碍物;所述N个障碍物包括自车的障碍物和所述自车的障碍物的周围障碍物,所述N个障碍物的类型包括精细化轨迹障碍物、导航型障碍物、宏观交通流和真实路测障碍物中的部分或者全部;所述N为大于0的整数;
    将所述N个障碍物中每个障碍物的ID及初始运动信息保存至障碍物资源池中;
    根据第一障碍物的ID从所述障碍物资源池中获取所述第一障碍物的周围障碍物的初始运动信息,并根据所述第一障碍物的周围障碍物的初始运动信息控制所述第一障碍物运行,得到所述第一障碍物的第一运动信息;将所述障碍物资源池所述第一障碍物的初始运动信息更新为所述第一运动信息,所述第一障碍物为所述N个障碍物中的任意一个;
    根据自车的位置信息从所述障碍物资源池中获取n个障碍物的第一运动信息;所述n个障碍物为所述自车的障碍物,n小于或等于N;
    根据所述n个障碍物的第一运动信息获取所述自车与所述n个障碍物的交互结果;
    根据所述交互结果确定所述自动驾驶算法的测试结果。
  2. 根据权利要求1所述的方法,其特征在于,所述障碍物资源池包括第一缓存和第二缓存,所述初始运动信息包括初始位置信息,所述方法还包括:
    对所述N个障碍物中的每个障碍物的ID进行哈希处理,得到所述每个障碍物的ID哈希值,
    所述将所述N个障碍物中每个障碍物的ID及初始运动信息保存至障碍物资源池中,包括:
    将所述N个障碍物中每个障碍物的初始运动信息保存至所述第一缓存中该障碍物的ID哈希值所指示的存储空间中;
    以所述N个障碍物中的每个障碍物的初始位置信息为索引,将该障碍物的ID及初始位置信息保存至所述第二缓存中。
  3. 根据权利要求1或2所述的方法,其特征在于,所述障碍物资源池包括第一缓存和第二缓存,所述根据第一障碍物的ID从所述障碍物资源池中获取所述第一障碍物的周围障碍物的初始运动信息,包括:
    根据所述第一障碍物的ID哈希值从所述第一缓存中获取所述第一障碍物的初始运动信息,所述初始运动信息包括初始位置信息,所述第一障碍物的ID哈希值是对所述第一障碍物的ID进行哈希处理得到的;
    根据所述第一障碍物的初始位置信息从第二缓存获取S个障碍物的ID,所述S个障碍物为位于所述第一障碍物的预设区域内的障碍物;所述第一障碍物的预设区域是基于所述第一障碍物的初始位置信息确定的,所述S小于或者等于N;
    根据所述第一障碍物的运动方式从所述S个障碍物确定所述第一障碍物的周围障碍物;所述第一障碍物的周围障碍物为所述S个障碍物中,在所述第一障碍物按照所述运动方式运动时与所述第一障碍物有潜在交互的障碍物;
    根据所述第一障碍物的周围障碍物的ID哈希值从所述第一缓存中获取所述周围障碍物的初始运动信息,所述第一障碍物的周围障碍物的ID哈希值是对所述周围障碍物的ID进行 哈希处理得到的。
  4. 根据权利要求3所述的方法,其特征在于,所述第一运动信息包括第一位置信息,所述将所述障碍物资源池所述第一障碍物的初始运动信息更新为所述第一运动信息,包括:
    根据所述第一障碍物的初始位置信息从所述第二缓存中确定所述第一障碍物的初始位置信息对应的ID,若所述第一障碍物的初始位置信息对应的ID为该第一障碍物的ID,则将所述第二缓存中所述第一障碍物的初始位置信息更新为所述第一障碍物的第一位置信息;
    根据所述第一障碍物的ID哈希值将所述第一缓存中所述第一障碍物的初始运动信息更新为所述第一运动信息。
  5. 根据权利要求2-4任一项所述的方法,其特征在于,所述第一运动信息包括第一位置信息,所述根据自车的位置信息从所述障碍物资源池中获取n个障碍物的第一运动信息,包括:
    根据所述自车的位置信息从所述第二缓存中确定M个障碍物的ID及第一位置信息,所述M个障碍物为位于所述自车的预设范围内的障碍物;所述自车的预设范围是基于所述自车的位置信息确定的,所述M为小于或等于N的正整数;
    根据预设交互方式和所述M个障碍物的第一位置信息从所述M个障碍物中确定n个障碍物;所述n个障碍物为与所述自车存在潜在交互的障碍物;
    根据所述n个障碍物中每个障碍物的ID哈希值从所述第一缓存中确定所述n个障碍物中每个障碍物的第一运动信息。
  6. 一种仿真测试装置,其特征在于,包括:
    获取单元,用于按照所述自动驾驶算法的测试功能从障碍物集合中获取N个障碍物;所述N个障碍物包括自车的障碍物和所述自车障碍物的周围障碍物,所述N个障碍物的类型包括精细化轨迹障碍物、导航型障碍物、宏观交通流和真实路测障碍物中的部分或者全部;所述N为大于0的整数;
    存储单元,用于将所述N个障碍物中每个障碍物的ID及初始运动信息保存至障碍物资源池中;
    仿真测试单元,用于根据第一障碍物的ID从所述障碍物资源池中获取所述第一障碍物的周围障碍物的运动信息,并根据所述第一障碍物的周围障碍物的运动信息控制所述第一障碍物运行,得到所述第一障碍物的第一运动信息;将所述障碍物资源池中所述第一障碍物的初始运动信息更新为所述第一运动信息;根据自车的位置信息从所述障碍物资源池获取n个障碍物的第一运动信息,所述n个障碍物为所述自车的障碍物,n小于或等于N;根据所述n个障碍物的第一运动信息获取所述自车与所述n个障碍物的交互结果;根据所述交互结果确定所述自动驾驶算法的测试结果。
  7. 根据权利要求6所述的装置,其特征在于,所述障碍物资源池包括第一缓存和第二缓存,所述初始运动信息包括初始位置信息,所述装置还包括:
    处理单元,用于对所述N个障碍物中的每个障碍物的ID进行哈希处理,得到所述每个障碍物的ID哈希值,
    所述存储单元具体用于:
    将所述N个障碍物中每个障碍物的初始运动信息保存至所述第一缓存中该障碍物的ID哈希值所指示的存储空间中;
    以所述N个障碍物中的每个障碍物的初始位置信息为索引,将所述每个障碍物的ID及初始位置信息保存至所述第二缓存中。
  8. 根据权利要求6或7所述的装置,其特征在于,所述障碍物资源池包括第一缓存和第二缓存,在所述根据第一障碍物的ID从所述障碍物资源池中获取所述第一障碍物的周围障碍物的初始运动信息的方面,所述仿真测试单元具体用于:
    根据所述第一障碍物的ID哈希值从所述第一缓存中获取所述第一障碍物的初始运动信息,所述初始运动信息包括初始位置信息,所述第一障碍物的ID哈希值是对所述第一障碍物的ID进行哈希处理得到的;
    根据所述第一障碍物的初始位置信息从所述第二缓存中获取S个障碍物的ID,所述S个障碍物为位于所述第一障碍物的预设区域内的障碍物,所述第一障碍物的预设区域是基于所述第一障碍物的初始位置信息确定的,所述S小于或等于N;
    根据所述第一障碍物的运动方式从所述S个障碍物中确定所述第一障碍物的周围障碍物,所述第一障碍物的周围障碍物为S个障碍物中在所述第一障碍物按照所述运动方式运动时与所述第一障碍物有潜在交互的障碍物;
    根据所述第一障碍物的周围障碍物的ID哈希值从所述第一缓存中获取所述周围障碍物的初始运动信息,所述第一障碍物的周围障碍物的ID哈希值是对所述周围障碍物的ID进行哈希处理得到的。
  9. 根据权利要求8所述的装置,其特征在于,所述第一运动信息包括第一位置信息,在所述将所述障碍物资源池中所述第一障碍物的初始运动信息更新为所述第一运动信息的方面,所述仿真测试单元具体用于:
    根据所述第一障碍物的初始位置信息从所述第二缓存中确定所述第一障碍物的初始位置信息对应的ID,若所述第一障碍物的初始位置信息对应的ID为该第一障碍物的ID,则将所述第二缓存中所述第一障碍物的初始位置信息更新为所述第一障碍物的第一位置信息;
    根据所述第一障碍物的ID哈希值将所述第一缓存中所述第一障碍物的初始运动信息更新为所述第一运动信息。
  10. 根据权利要求7-9任一项所述的装置,其特征在于,所述第一运动信息包括第一位置信息,在所述根据自车的位置信息从所述障碍物资源池中获取n个障碍物的第一运动信息的方面,所述仿真测试单元具体用于:
    根据所述自车的位置信息从所述第二缓存中确定M个障碍物的ID及第一位置信息,所述M个障碍物为位于所述自车的预设范围内的障碍物;所述自车的预设范围是基于所述自车的位置信息确定的,所述M为小于或等于N的正整数;
    根据预设交互方式和所述M个障碍物的第一位置信息从所述M个障碍物中确定n个障碍物;所述n个障碍物为与所述自车存在潜在交互的障碍物;
    根据所述n个障碍物中每个障碍物的ID哈希值从所述第一缓存中确定所述n个障碍物中每个障碍物的第一运动信息。
  11. 一种仿真测试装置,其特征在于,包括:
    存储器,用于存储指令;以及
    处理器,与所述存储器耦合;
    其中,当所述处理器执行所述指令时,执行如权利要求1-5任一项所述的方法。
  12. 一种芯片系统,其特征在于,所述芯片系统应用于电子设备;所述芯片系统包括一个或多个接口电路,以及一个或多个处理器;所述接口电路和所述处理器通过线路互联;所述接口电路用于从所述电子设备的存储器接收信号,并向所述处理器发送所述信号,所述信号包括所述存储器中存储的计算机指令;当所述处理器执行所述计算机指令时,所述电子设备执行如权利要求1-5中任意一项所述方法。
  13. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质存储有计算机程序,所述计算机程序包括程序指令,所述程序指令当被处理器执行时使所述处理器执行如权利要求1-5任一项所述的方法。
  14. 一种计算机程序产品,其特征在于,包括计算机指令,当所述计算机指令在电子设备上运行时,使得所述电子设备执行如权利要求1-5任一项所述的方法。
PCT/CN2021/136414 2020-12-31 2021-12-08 自动驾驶算法测试方法及相关设备 WO2022143057A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP21913798.1A EP4261729A1 (en) 2020-12-31 2021-12-08 Self-driving algorithm testing method and related device
US18/215,581 US20230339513A1 (en) 2020-12-31 2023-06-28 Method for testing autonomous-driving algorithm, and related device

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202011645222.0 2020-12-31
CN202011645222.0A CN114692289A (zh) 2020-12-31 2020-12-31 自动驾驶算法测试方法及相关设备

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US18/215,581 Continuation US20230339513A1 (en) 2020-12-31 2023-06-28 Method for testing autonomous-driving algorithm, and related device

Publications (1)

Publication Number Publication Date
WO2022143057A1 true WO2022143057A1 (zh) 2022-07-07

Family

ID=82136503

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/136414 WO2022143057A1 (zh) 2020-12-31 2021-12-08 自动驾驶算法测试方法及相关设备

Country Status (4)

Country Link
US (1) US20230339513A1 (zh)
EP (1) EP4261729A1 (zh)
CN (1) CN114692289A (zh)
WO (1) WO2022143057A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115879323A (zh) * 2023-02-02 2023-03-31 西安深信科创信息技术有限公司 自动驾驶仿真测试方法、电子设备及计算机可读存储介质

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108875998A (zh) * 2018-04-20 2018-11-23 北京智行者科技有限公司 一种自动驾驶车辆规划方法和系统
CN109885066A (zh) * 2019-03-26 2019-06-14 北京经纬恒润科技有限公司 一种运动轨迹预测方法及装置
US20190317511A1 (en) * 2018-04-17 2019-10-17 Baidu Usa Llc Method for generating prediction trajectories of obstacles for autonomous driving vehicles
CN111123732A (zh) * 2018-10-31 2020-05-08 百度在线网络技术(北京)有限公司 自动驾驶车辆仿真的方法、装置、存储介质和终端设备
CN111625950A (zh) * 2020-05-20 2020-09-04 北京百度网讯科技有限公司 自动驾驶仿真场景重建方法、装置、设备和介质

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20190317511A1 (en) * 2018-04-17 2019-10-17 Baidu Usa Llc Method for generating prediction trajectories of obstacles for autonomous driving vehicles
CN108875998A (zh) * 2018-04-20 2018-11-23 北京智行者科技有限公司 一种自动驾驶车辆规划方法和系统
CN111123732A (zh) * 2018-10-31 2020-05-08 百度在线网络技术(北京)有限公司 自动驾驶车辆仿真的方法、装置、存储介质和终端设备
CN109885066A (zh) * 2019-03-26 2019-06-14 北京经纬恒润科技有限公司 一种运动轨迹预测方法及装置
CN111625950A (zh) * 2020-05-20 2020-09-04 北京百度网讯科技有限公司 自动驾驶仿真场景重建方法、装置、设备和介质

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115879323A (zh) * 2023-02-02 2023-03-31 西安深信科创信息技术有限公司 自动驾驶仿真测试方法、电子设备及计算机可读存储介质

Also Published As

Publication number Publication date
US20230339513A1 (en) 2023-10-26
CN114692289A (zh) 2022-07-01
EP4261729A1 (en) 2023-10-18

Similar Documents

Publication Publication Date Title
US10137896B2 (en) Method and system for operating autonomous driving vehicles using graph-based lane change guide
CN110427021B (zh) 用于生成自动驾驶车辆交叉路口导航指令的系统和方法
CN113071520B (zh) 车辆行驶控制方法及装置
CN110825093B (zh) 自动驾驶策略生成方法、装置、设备及存储介质
CN109697875B (zh) 规划行驶轨迹的方法及装置
JP2019194071A5 (zh)
JP2021113049A (ja) 自動運転車両計画方法、装置、電子機器及び記憶媒体
JP7341187B2 (ja) シミュレーション車両を制御するための方法、装置、電子機器及び記憶媒体
EP4063792A2 (en) Method and apparatus for generating a simulation scene, electronic device and storage medium
WO2022037085A1 (zh) 车辆的仿真测试场景的构建方法和装置
CN113212454A (zh) 车辆行驶状态的调整方法、装置、计算机设备和存储介质
CN111753425A (zh) 仿真方法、装置、电子设备及存储介质
US20230339513A1 (en) Method for testing autonomous-driving algorithm, and related device
CN111477030A (zh) 车辆协同避险方法、车端平台、云端平台及存储介质
CN115203969A (zh) 自动驾驶仿真场景的控制方法、装置、设备和存储介质
Gómez-Huélamo et al. Train here, drive there: ROS based end-to-end autonomous-driving pipeline validation in CARLA simulator using the NHTSA typology
CN113221359A (zh) 一种仿真场景生成方法、装置、设备及存储介质
US11673577B2 (en) System and methods of adaptive relevancy prediction for autonomous driving
CN112904843B (zh) 一种自动驾驶场景确定方法、装置、电子设备及存储介质
EP4353560A1 (en) Vehicle control method and apparatus
US20230195958A1 (en) Generating simulations based on real-world scenarios
US20230192104A1 (en) Hybrid scenario closed course testing for autonomous vehicles
US20240010233A1 (en) Camera calibration for underexposed cameras using traffic signal targets
WO2021159357A1 (zh) 行驶场景信息处理方法、装置、电子设备和可读存储介质
US20230192144A1 (en) Uncertainty prediction for a predicted path of an object that avoids infeasible paths

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21913798

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 2021913798

Country of ref document: EP

Effective date: 20230714

NENP Non-entry into the national phase

Ref country code: DE