CN116383041A - Lane line fitting method and device for automatic driving simulation test - Google Patents

Lane line fitting method and device for automatic driving simulation test Download PDF

Info

Publication number
CN116383041A
CN116383041A CN202310202189.1A CN202310202189A CN116383041A CN 116383041 A CN116383041 A CN 116383041A CN 202310202189 A CN202310202189 A CN 202310202189A CN 116383041 A CN116383041 A CN 116383041A
Authority
CN
China
Prior art keywords
lane
lane line
fitting
coordinates
coordinate
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
CN202310202189.1A
Other languages
Chinese (zh)
Inventor
史宏涛
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Inceptio Star Intelligent Technology Shanghai Co Ltd
Original Assignee
Inceptio Star Intelligent Technology Shanghai Co Ltd
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 Inceptio Star Intelligent Technology Shanghai Co Ltd filed Critical Inceptio Star Intelligent Technology Shanghai Co Ltd
Priority to CN202310202189.1A priority Critical patent/CN116383041A/en
Publication of CN116383041A publication Critical patent/CN116383041A/en
Pending legal-status Critical Current

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
    • 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

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Traffic Control Systems (AREA)

Abstract

The invention relates to the technical field of automatic driving, and provides a lane line fitting method and device for automatic driving simulation test, wherein the method comprises the following steps: converting a first coordinate of the host vehicle under a world coordinate system into a second coordinate under a lane coordinate system based on a map corresponding to the simulation scene; acquiring second coordinates of a plurality of sampling points on a lane line of each lane in the advancing direction of the main vehicle based on the second coordinates of the main vehicle under a lane coordinate system; converting the second coordinates of each sampling point on each lane line into the first coordinates of each sampling point under the world coordinate system; and determining fitting coordinates of each sampling point according to the first coordinates of each sampling point, and fitting all the sampling points on each lane line based on the fitting coordinates to obtain a lane line model. According to the method, the lane lines on the high-precision map corresponding to the simulation scene are directly fitted, and decoupling with simulation software is achieved.

Description

Lane line fitting method and device for automatic driving simulation test
Technical Field
The invention relates to the technical field of automatic driving, in particular to a lane line fitting method and device for automatic driving simulation test.
Background
Autopilot is commercially landed and requires extensive testing. Compared with closed field test and open road test, the simulation test has lower cost and extremely high test efficiency, greatly accelerates the system test process and becomes an important link for commercialized landing of automatic driving.
In recent years, related simulation software is rapidly developed, and a plurality of commercial and open-source simulation test tools, represented by VTD (Virtual Test Drive) and Carla, mainly based on a physical rendering engine, are used for constructing various sensor models. Although the fidelity of the picture is continuously improved under the addition of the technology such as a physical engine, the confidence of the sensor model is still to be verified due to the complexity of the real world. The data generated by the sensor model still cannot satisfy the verification of the perception algorithm.
In order to solve the problem of insufficient accuracy of a sensor model, at present, the current common practice in the industry is to perform short-circuit sensing in a simulation test link, directly inject a result after sensing fusion into an automatic driving system, so as to verify subsequent modules such as planning, decision making, control and the like, and perform the test of the sensing module in other modes. In this case, the simulation software, although providing multiple sensor models, often lacks a lane line model, and requires complex secondary development according to a high-precision map associated with a test scene when building a closed-loop simulation system, such as: only the vehicle line ball detection sensor is provided in the Carla simulation engine. Because the simulation software lacks a lane line model, the incomplete lane line information acquisition interface and even the lack of interfaces of the simulation software and the diversity among different simulation software interfaces, secondary development is required to be carried out on different platforms and racks in the multi-platform and multi-rack simulation test process, and the development cost and the system maintenance cost of the simulation test are obviously increased. Therefore, how to perform lane line fitting to form a lane line model during an automatic driving simulation test is a technical problem to be solved urgently at present.
Disclosure of Invention
The invention provides a lane line fitting method and device for automatic driving simulation test, which are used for solving the technical problems in the prior art.
The invention provides a lane line fitting method for automatic driving simulation test, which comprises the following steps:
converting a first coordinate of the host vehicle under a world coordinate system into a second coordinate under a lane coordinate system based on a map corresponding to the simulation scene;
acquiring second coordinates of a plurality of sampling points on a lane line of each lane in the advancing direction of the main vehicle based on the second coordinates of the main vehicle under a lane coordinate system;
converting the second coordinates of each sampling point on each lane line into the first coordinates of each sampling point under the world coordinate system;
and determining fitting coordinates of each sampling point according to the first coordinates of each sampling point, and fitting all the sampling points on each lane line based on the fitting coordinates to obtain a lane line model.
According to the lane line fitting method for the automatic driving simulation test provided by the invention, based on the second coordinates of the main vehicle under a lane coordinate system, the second coordinates of a plurality of sampling points are acquired on the lane line of each lane in the advancing direction of the main vehicle, and the lane line fitting method comprises the following steps:
Acquiring all lanes in the forward direction of a main vehicle;
setting a virtual starting point on the lane central line of each lane, and making the distance from the origin of the lane coordinate system in the second coordinate of the virtual starting point equal to the distance from the origin of the lane coordinate system in the second coordinate of the host vehicle under the lane coordinate system;
for each lane, determining a plurality of virtual points forwards along the center line of the lane according to the step length set in a preset step length strategy by taking the virtual starting point as a reference, and collecting second coordinates of the plurality of virtual points;
and for each lane, determining sampling points on the lane lines at two sides of the virtual point according to the second coordinates of each virtual point and the lane width so as to obtain the second coordinates of a plurality of sampling points on each lane line.
According to the lane line fitting method for the automatic driving simulation test provided by the invention, the preset step strategy comprises the following steps: equal step size strategy, segmentation equal step size strategy or equal difference increment step size strategy;
the equal step strategy is: the step size of each forward movement is equal;
the segmentation equal-step strategy is as follows: dividing the total length of a lane line to be sampled into a plurality of fixed intervals, wherein the step length in each fixed interval is equal, and the shorter the fixed interval is from the virtual starting point, the smaller the corresponding step length is;
The arithmetic increment step strategy is as follows: the step length of the movement from the virtual starting point is in an arithmetic progression relation.
According to the lane line fitting method for the automatic driving simulation test, provided by the invention, the fitting coordinates of each sampling point are determined according to the first coordinates of each sampling point, and fitting is carried out on all sampling points on each lane line based on the fitting coordinates to obtain a lane line model, and the lane line fitting method comprises the following steps:
determining the first coordinate of each sampling point as the fitting coordinate;
fitting the fitting coordinates of all the sampling points on each lane line through a unitary fitting function to obtain a lane line model.
According to the lane line fitting method for the automatic driving simulation test, provided by the invention, the fitting coordinates of each sampling point are determined according to the first coordinates of each sampling point, and fitting is carried out on all sampling points on each lane line based on the fitting coordinates to obtain a lane line model, and the lane line fitting method comprises the following steps:
converting the first coordinate of each sampling point to a third coordinate under a main vehicle coordinate system, and determining the third coordinate of each sampling point as the fitting coordinate;
Fitting the fitting coordinates of all the sampling points on each lane line through a unitary fitting function to obtain a lane line model.
The lane line fitting method for the automatic driving simulation test provided by the invention further comprises the following steps:
and sending the lane line model or the lane line model together with the fitting coordinates of all sampling points on each lane line to an automatic driving system.
According to the lane line fitting method for the automatic driving simulation test provided by the invention, after fitting the fitting coordinates of all sampling points on each lane line to obtain a lane line model, the lane line fitting method further comprises the following steps:
and adding noise to the lane line model to obtain the lane line model added with the noise.
The lane line fitting method for the automatic driving simulation test provided by the invention further comprises the following steps:
the method comprises the steps of bringing x coordinate values of fitting coordinates of sampling points into a lane line model added with noise, calculating y coordinate values of the fitting coordinates of a plurality of sampling points to obtain new coordinates of the sampling points, or generating n x coordinate values of n new sampling points in a section of [0, L ] according to the length L of the lane line and the number n of coordinate points required by an automatic driving system, bringing the n x coordinate values into the lane line model added with noise, and calculating n y coordinate values of n new sampling points to obtain new coordinates of the new sampling points;
And sending the lane line model added with noise or the lane line model added with noise together with the new coordinates to an automatic driving system.
The invention also provides a lane line fitting device for automatic driving simulation test, which comprises:
the first coordinate conversion module is used for converting a first coordinate of the host vehicle under a world coordinate system into a second coordinate under a lane coordinate system based on a map corresponding to the simulation scene;
the lane line sampling module is used for acquiring second coordinates of a plurality of sampling points on the lane line of each lane in the advancing direction of the main vehicle based on the second coordinates of the main vehicle under the lane coordinate system;
the second coordinate conversion module is used for converting the second coordinate of each sampling point on each lane line into the first coordinate of each sampling point under the world coordinate system;
and the lane line fitting module is used for determining the fitting coordinates of each sampling point according to the first coordinates of each sampling point, and fitting all the sampling points on each lane line based on the fitting coordinates so as to obtain a lane line model.
The invention also provides electronic equipment, which comprises a memory, a processor and a computer program stored on the memory and capable of running on the processor, wherein the processor realizes the lane line fitting method for the automatic driving simulation test when executing the program.
The invention also provides a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements a lane line fitting method for automated driving simulation testing as described in any of the above.
According to the lane line fitting method and device for the automatic driving simulation test, the first coordinates of the main vehicle under the world coordinate system are converted into the second coordinates under the lane coordinate system based on the map corresponding to the simulation scene; acquiring second coordinates of a plurality of sampling points on a lane line of each lane in the advancing direction of the main vehicle based on the second coordinates of the main vehicle under a lane coordinate system; converting the second coordinates of each sampling point on each lane line into the first coordinates of each sampling point under the world coordinate system; and determining fitting coordinates of each sampling point according to the first coordinates of each sampling point, and fitting all the sampling points on each lane line based on the fitting coordinates to obtain a lane line model. The invention takes the second coordinate of the host vehicle under the lane coordinate system as the reference to collect the sampling points on the lane line of the map, converts the sampling points into the first coordinate of the world coordinate system, determines the fitting coordinate of each sampling point according to the first coordinate, and fits all the sampling points on each lane line based on the fitting coordinate to obtain the lane line model, thereby realizing the fitting of the lane line of the automatic driving simulation test.
Drawings
In order to more clearly illustrate the invention or the technical solutions of the prior art, the following description will briefly explain the drawings used in the embodiments or the description of the prior art, and it is obvious that the drawings in the following description are some embodiments of the invention, and other drawings can be obtained according to the drawings without inventive effort for a person skilled in the art.
FIG. 1 is a diagram of three coordinate system relationship diagram intents in an OpenDRIVE format map;
FIG. 2 is a schematic diagram of a reference line coordinate system in an OpenDRIVE format map;
FIG. 3 is a flow chart of a lane line fitting method for automated driving simulation testing provided by the present invention;
FIG. 4 is a schematic illustration of lane lines fitted by the lane line fitting method for automated driving simulation testing provided by the present invention;
FIG. 5 is a schematic diagram of the conversion of the world coordinate system to the host vehicle coordinate system in the lane line fitting method for the automated driving simulation test provided by the present invention;
FIG. 6 is a schematic diagram of a lane line fitting apparatus for automated driving simulation testing according to the present invention;
fig. 7 is a schematic structural diagram of an electronic device provided by the present invention.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the present invention more apparent, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings, and it is apparent that the described embodiments are some embodiments of the present invention, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
Currently, high-precision maps used by simulation test systems are distinguished from those used internally by automatic driving controllers (ADUs). Simulation test systems typically use an OpenDRIVE format map that describes road network structures and road elements using XML, maintained by the german automation and measurement system standards association (ASAM) organization. As shown in fig. 1, there are three coordinate systems in OpenDRIVE: the world coordinate system xyz (also called inertial coordinate system), the local coordinate system uvz and the reference line coordinate system sth (also called road coordinate system) are typically used to describe the road related elements in the map. As shown in fig. 2, in the reference line coordinate system, s represents a distance from a road start point at a certain point along a road reference line, t represents a distance from the road reference line in a normal direction of the road reference line at the certain point, t is positive at the left side t of the road reference line, t is negative at the right side t, and h represents an elevation of the certain point. Specifically, openDRIVE uses a lane line (white solid line or broken line on a road) describing the shape and the traveling direction of the road as a basic element of map description, and in the OpenDRIVE standard, a road Reference line (Reference line) is the most basic and essential element of the shape description of the road, and all features on the road can be constructed along the road Reference line based on a Reference line coordinate system. The road reference line may be a straight line, an arc line or a spiral line. In OpenDRIVE, the road is separated from the driving direction by a central lane (i.e. a road separation line, corresponding to a yellow line or a double yellow line in the middle of an actual road), the number is 0, the width is 0, the other lanes take the central lane as a reference, the lane numbers are in descending order right and ascending order left, and the road reference line can be understood as the central lane. When judging the position relation between the map element and the lane, a lane coordinate system is adopted, namely the lane center line is equivalent to a road reference line, and the offset from the lane center line is used for replacing the value on the t axis.
The embodiment of the invention is illustrated by taking the OpenDRIVE format map as an example, the fitting lane lines are irrelevant to elevation data, and the following reference is made to each coordinate system without considering elevation coordinates. As shown in fig. 3, a lane line fitting method for an automatic driving simulation test according to an embodiment of the present invention includes:
step S310, converting a first coordinate of the host vehicle under a world coordinate system into a second coordinate under a lane coordinate system based on a map corresponding to the simulation scene. The first coordinates of the host vehicle in the world coordinate system in the simulation scene are generally provided by a vehicle dynamics model, and in the whole simulation test system, the vehicle dynamics model provides not only the first coordinates (x, y, z) of the host vehicle in the world coordinate system, but also the host vehicle posture, wherein the host vehicle posture can be described as (yaw, pitch, roll) representing the course angle of the host vehicle, pitch representing the pitch angle of the host vehicle, and roll representing the yaw angle of the host vehicle. Since the fitted lane lines are independent of elevation and pitch and yaw angles of the host vehicle, the first coordinates of the host vehicle can be abbreviated as (x, y) and the host vehicle pose is described as yaw only. In this step, firstly, elements of the OpenDRIVE map file described in XML are loaded into a memory, that is, the OpenDRIVE map file is obtained, and then, mutual conversion from the world coordinate system to points under the reference line coordinate system is achieved, specifically, in some embodiments, the mutual conversion is achieved by using codes of the RoadManager module in the open source item esmini, for any point under the world coordinate system, a corresponding point should be found in the reference line coordinate system and the lane coordinate system, that is, a point (x, y) under the world coordinate system is converted into a point (roadId, s, t) under the reference line coordinate system, and then, according to lane information contained in the roadId, the point is further converted into a lane coordinate system of a lane where a host vehicle is located, the lane is (roadId, laneId, s, offset), where roadId represents a lane ID on a road, s represents a distance along a road reference line, and offset represents a distance between the coordinate point and a center line in a lane center line direction, and the lane can be translated by a certain width (e.g. 2/w) of a lane, and the like, and the lane can be translated by a certain width (e.g. 2/w). For example: the point (x, y) of the host vehicle under the world coordinate system is converted into (roadId, s, t) under the reference line coordinate system, wherein t is-10 meters, 3 lanes are arranged in the right direction, each lane is 3.5 meters wide, then the width of each lane is required to be added from-1 to-3, the width of each lane is found to be-10 in the interval of-7 to-10.5, so that the laneId of the lane where the host vehicle is located can be-3, the distance between the lane center line of the lane and the road reference line is- (3.5+3.5+1.75), and the offset can be-10- [ - (3.5+3.5+1.75) ] = -1.25 meters.
It should be noted that: in OpenDRIVE, the isolation belt and the road shoulder belong to non-driving lanes, and have corresponding lane IDs, that is, laneId, and if the type of the lane in the RoadManger module is the non-driving lane, the laneId will deviate to the nearest driving lane.
Step 320, based on the second coordinates of the host vehicle in the lane coordinate system, collecting the second coordinates of a plurality of sampling points on the lane line of each lane in the advancing direction of the host vehicle. Since the lane lines are to be fitted, it is necessary to collect sampling points of the host vehicle on each lane line in the lane coordinate system.
Step S330, the second coordinates of each sampling point on each lane line are converted into the first coordinates of each sampling point in the world coordinate system. In this step, the conversion of the second coordinate into the first coordinate may be performed inversely based on the conversion in step S310.
And step 340, determining fitting coordinates of each sampling point according to the first coordinates of each sampling point, and fitting all the sampling points on each lane line based on the fitting coordinates to obtain a lane line model.
According to the lane line fitting method for the automatic driving simulation test, the second coordinates of the host vehicle under the lane coordinate system are taken as the reference to collect sampling points on the lane line of the map, the sampling points are converted into the first coordinates of the world coordinate system, the fitting coordinates of each sampling point are determined according to the first coordinates, and fitting is carried out on all the sampling points on each lane line based on the fitting coordinates, so that a lane line model is obtained, the lane line fitting of the automatic driving simulation test is realized, the lane line fitting on the high-precision map corresponding to the simulation scene is carried out, the decoupling with simulation software is realized independently of the simulation software, the defects of incomplete lane line information acquisition interfaces and even interface defects of different simulation software interfaces of the simulation software are avoided, the development cost and the system maintenance cost of the simulation test are reduced in the process of the multi-platform and multi-rack simulation test. For example: in practical application, a map in an OpenDRIVE format is adopted in a certain type of simulation software, and the simulation software is adopted to perform an automatic driving simulation test in combination with an automatic driving system, so that road information on a map corresponding to a simulation scene (the map format is the same as that in the simulation software) and position coordinates of a host vehicle under a world coordinate system output by a vehicle dynamics model can be processed through the steps S310-S340 of the embodiment, and the lane line model is obtained and is sent to the automatic driving system without secondary development aiming at the simulation software, so that the simulation software is applicable to all simulation software based on the map in the OpenDRIVE format.
In some embodiments, step S320 includes:
all lanes in the forward direction of the host vehicle are acquired, the coordinates of the host vehicle after the first coordinates of the host vehicle in the world coordinate system are converted into the lane coordinate system are P (roaded_0, laneid_0, s_0 and offset), then all lanes in the forward direction of the host vehicle are marked as laneid_j, and the laneid_j can be acquired through the roaded_0, and the positive and negative signs of the laneid_j and the laneid_0 are the same, so that the selected lane is the lane consistent with the forward direction of the host vehicle.
And setting a virtual starting point on the lane center line of each lane, and enabling the distance from the origin of the lane coordinate system in the second coordinate of the virtual starting point to be equal to the distance from the origin of the lane coordinate system in the second coordinate of the host vehicle under the lane coordinate system, namely, keeping s_0 unchanged. Specifically, the virtual start point is p_0 (roadid_0, laneid_j, s_0, 0), and since the virtual start point is on the lane center line, the offset is 0.
For each lane, with the virtual starting point as a reference, determining a plurality of virtual points forward along the lane center line according to the step length set in the preset step length strategy, marking as P_i (roaded_0, laneid_j, s_i, 0), and collecting second coordinates of the plurality of virtual points P_i. Of course, the total length of the collected lane lines depends on the lane line length actually required in the automatic driving system.
And for each lane, determining sampling points on the lane lines at two sides of the virtual point according to the second coordinates of each virtual point and the lane width so as to obtain the second coordinates of a plurality of sampling points on each lane line. Specifically, the width w of the lane at the virtual point p_i (the width of which may also change with the change of s because the width of the lane is not a fixed value), the width w 'of the lane line, and the points p_i1 and p_i2 at the lane center line w/2+w'/2 on both sides in the normal direction of the lane center line are calculated, respectively. P_i1 and p_i2 are sampling points on the lane line corresponding to the virtual point p_i.
In this embodiment, the second coordinates of the host vehicle in the lane coordinate system are used as references to enable the sampling points on each lane line which is the same as the advancing direction of the host vehicle to be conveniently collected.
Specifically, the preset step strategy includes: equal step size strategy, segmented equal step size strategy, or equal difference increment step size strategy.
The equal step strategy is: the step size of each forward movement is equal.
The segmentation equal-step strategy is as follows: dividing the total length of the lane line to be sampled into a plurality of fixed intervals, wherein the step length in each fixed interval is equal, and the shorter the fixed interval is from the virtual starting point, the smaller the corresponding step length is.
The arithmetic increment step strategy is as follows: the step length of the movement from the virtual starting point is in an arithmetic progression relation. For example: the total sampling length is S, the number of sampling points is n, the first sampling point is a_0=0, the distance of the last movement is a_n=2s/n, and the distance of each movement step is d=a_n/(n-1) which is greater than the previous movement step.
In step S320, one of the three policies may be selected according to the actual situation. In the case where the road shape is relatively single, for example: the road is a straight line or is close to a straight line, and the three schemes can acquire better fitting precision, and the simplest equal step strategy can be selected at the moment so as to reduce the calculated amount. In the case of relatively complex road trends, for example: the multi-curve road or the radian of the road is larger, and the fitting precision is in an equal difference increment step size strategy, a segmentation equal step size strategy and an equal step size strategy from high to low by experimental comparison based on the equal number of sampling points and the sampling total length. In this case, an equal difference increment step strategy or a segmentation equal step strategy can be preferentially selected, because the closer to the host vehicle, the higher the accuracy requirement on the lane line is, and the denser the sampling points are needed in the fitting process.
In some embodiments, step S340 includes:
determining the first coordinate of each sampling point as the fitting coordinate; fitting the fitting coordinates of all the sampling points on each lane line through a unitary fitting function to obtain a lane line model. I.e. fitting based on the world coordinate system, in particular fitting can be performed by using a univariate polynomial or a univariate exponential function. Because the collected sampling points are based on the world coordinate system, the situation that the fitted lane lines in fig. 4 have larger bending, so that one x coordinate corresponds to a plurality of y coordinates, and in this case, the fitting cannot be performed by adopting a unitary fitting function, so that the lane line model fitted based on the world coordinate system is preferably used for the situation that the lane lines are straight lines or basically straight lines, the conversion from the world coordinate system to the host vehicle coordinate system is reduced once, and the calculation amount is reduced.
In addition, fitting is directly performed based on the world coordinate system, and the direct fitting may result in the loss of floating point number precision, and the fitting precision is poor, for the two reasons, in some embodiments, step S340 includes:
and converting the first coordinate of each sampling point to a third coordinate in a main vehicle coordinate system (local coordinate system), and determining the third coordinate of each sampling point as the fitting coordinate. Specifically, as shown in fig. 5, the coordinates of the position of the host vehicle in the world coordinate system are P (x 0 ,y 0 ) Heading angle is yaw, then for any sampling point P 1 The coordinate under the world coordinate system is P 1 (x 1 ,y 1 ) Then any sample point P 1 The position in the host vehicle coordinate system may be expressed as P 1 ′(x t ,y t ):
x t =x 1 –x 0 ;y t =y 1 –y 0
x b =x t ×cos(yaw)+y t ×sin(yaw)
y b =-x t ×sin(yaw)+y t ×cos(yaw)
To further optimize the computational efficiency, the conversion matrix Mat is used in this embodiment to optimize the conversion process, which is expressed as:
P′ 1 =Mat*(P 1 -P)
Figure BDA0004109423290000121
fitting the fitting coordinates of all the sampling points on each lane line through a unitary fitting function to obtain a lane line model. For example: conversion to the coordinates P 'of each sampling point in the host vehicle coordinate system through a unitary polynomial' 1 (x b ,y b ) As fitting coordinates, the following univariate polynomial expression is used for fitting:
f(x)=a n *x n +a n-1 *x n-1 +…+a 2 *x 2 +a 1 *x+a 0
wherein a is i Representing fitting parameters, i=1, 2, …, n, n is the number of sampling points, taking the fitting coordinates (x, y) of each lane line into an equation, and solving the fitting parameters a i So that the error of the approximation curves f (x) and y is minimized. In the embodiment, the least square method is adopted to solve the lane line model, and through experimental comparison of the roads with different curvatures and different line shapes, the higher fitting precision can be obtained by adopting the three-time polynomial fitting, and meanwhile, the occurrence of over-fitting under the condition of fewer sampling points on the lane line and higher polynomial times can be prevented.
The lane line fitting method for the automatic driving simulation test also comprises the following steps: and sending the lane line model or the fitted coordinates of the lane line model and all sampling points on each lane line to an automatic driving system so as to facilitate the automatic driving system to acquire the simulated lane line perception data in time. Specifically, a configurable UDP client, via which lane line information is sent to a specified autopilot system.
The lane line model is a true value directly obtained from a high-precision map (such as an OpenDRIVE format map), and the true value is different from lane line data obtained from a perception fusion result under a real scene (namely a fusion result perceived by a sensor such as a vehicle camera or a radar under the real scene) due to influence of various conditions such as lane line offset, light interference, algorithm precision and the like in the real condition. To more truly simulate the actual lane lines, in some embodiments, after fitting the fitting coordinates of all the sampling points on each lane line to obtain the lane line model, the method further includes: and adding noise to the lane line model to obtain the lane line model added with the noise. For example: adding Gaussian noise, recording a curve equation of the fitted lane line model as f (x), and recording a Gaussian noise function as g (x), wherein the lane line model after noise addition can be expressed as: f' (x) =f (x) +g (x).
Figure BDA0004109423290000131
Where μ represents the mean value of x, σ represents the standard deviation of x, and modifying both μ and σ parameters controls noise. In this embodiment, noise injection based on a gaussian function makes lane line data closer to the real situation. In practical application, the curve fitted by the unitary fitting function is used for representing the lane line model, the confidence coefficient and noise simulation can be accurately controlled according to the test verification requirement, and the larger the noise addition is, the lower the confidence coefficient is relatively.
Further, since noise is added to the lane line model, the same x is brought into f' (x), and the y value corresponding to the same is changed, in order to provide lane line coordinate point data more in line with actual situations for the automatic driving system, in some embodiments, the lane line fitting method for the automatic driving simulation test further includes:
and (3) taking the x coordinate values of the fitting coordinates of the sampling points into the lane line model added with noise, calculating the y coordinate values of the fitting coordinates of a plurality of sampling points to obtain new coordinates of the sampling points, or generating n x coordinate values of n new sampling points in the interval of [0, L ] according to the lane line length L and the number n of coordinate points required by an automatic driving system, taking the n x coordinate values into the lane line model added with noise, and calculating n y coordinate values of n new sampling points to obtain new coordinates of the new sampling points.
And sending the lane line model added with noise or the lane line model added with noise together with the new coordinates to an automatic driving system.
And re-calculating a y coordinate value according to the lane line model added with noise, so that the coordinates of points on the lane line and the lane line model which are more in line with actual conditions are sent to an automatic driving system.
The lane line fitting device for the automatic driving simulation test, which is provided by the invention, is described below, and the lane line fitting device for the automatic driving simulation test, which is described below, and the lane line fitting method for the automatic driving simulation test, which is described above, can be referred to correspondingly with each other.
The lane line fitting device for automatic driving simulation test provided by the invention, as shown in fig. 6, comprises:
a first coordinate conversion module 610, configured to convert a first coordinate of a host vehicle in a world coordinate system into a second coordinate in a lane coordinate system based on a map corresponding to a simulation scene;
the lane line sampling module 620 is configured to collect second coordinates of a plurality of sampling points on a lane line of each lane in the forward direction of the host vehicle based on second coordinates of the host vehicle in a lane coordinate system;
the second coordinate conversion module 630 is configured to convert the second coordinate of each sampling point on each lane line into the first coordinate of each sampling point in the world coordinate system;
The lane line fitting module 640 is configured to determine a fitting coordinate of each sampling point according to the first coordinate of each sampling point, and fit all the sampling points on each lane line based on the fitting coordinate, so as to obtain a lane line model.
The lane line fitting device for the automatic driving simulation test acquires the sampling points on the lane line of the map by taking the second coordinate of the host vehicle under the lane coordinate system as the reference, converts the sampling points into the first coordinate of the world coordinate system, determines the fitting coordinate of each sampling point according to the first coordinate, and fits all the sampling points on each lane line based on the fitting coordinate so as to obtain a lane line model, thereby realizing the fitting of the lane line of the automatic driving simulation test.
Optionally, the lane line sampling module 620 includes:
the lane acquisition module is used for acquiring all lanes in the forward direction of the main vehicle.
The virtual starting point setting module is used for setting a virtual starting point on the lane central line of each lane, and the distance from the origin of the lane coordinate system in the second coordinate of the virtual starting point is equal to the distance from the origin of the lane coordinate system in the second coordinate of the host vehicle under the lane coordinate system.
And the virtual point determining module is used for determining a plurality of virtual points forwards along the center line of the lane according to the step length set in the preset step length strategy by taking the virtual starting point as a reference for each lane, and collecting second coordinates of the plurality of virtual points.
And a point determining module is used for determining sampling points on the lane lines at two sides of each virtual point according to the second coordinates of each virtual point and the lane width for each lane so as to obtain the second coordinates of a plurality of sampling points on each lane line.
Optionally, the preset step strategy includes: equal step size strategy, segmented equal step size strategy, or equal difference increment step size strategy.
The equal step strategy is: the step size of each forward movement is equal.
The segmentation equal-step strategy is as follows: dividing the total length of the lane line to be sampled into a plurality of fixed intervals, wherein the step length in each fixed interval is equal, and the shorter the fixed interval is from the virtual starting point, the smaller the corresponding step length is.
The arithmetic increment step strategy is as follows: the step length of the movement from the virtual starting point is in an arithmetic progression relation.
Optionally, the lane line fitting module 640 is specifically configured to:
and determining the first coordinate of each sampling point as the fitting coordinate.
Fitting the fitting coordinates of all the sampling points on each lane line through a unitary fitting function to obtain a lane line model.
Optionally, the lane line fitting module 640 is further specifically configured to:
and converting the first coordinate of each sampling point to a third coordinate under a main vehicle coordinate system, and determining the third coordinate of each sampling point as the fitting coordinate.
Fitting the fitting coordinates of all the sampling points on each lane line through a unitary fitting function to obtain a lane line model.
Optionally, the lane line fitting device for automatic driving simulation test of the present invention further comprises: and the first lane line information sending module is used for sending the lane line model or the lane line model together with the fitting coordinates of all sampling points on each lane line to an automatic driving system.
Optionally, the lane line fitting device for automatic driving simulation test of the present invention further comprises: and the noise adding module is used for adding noise to the lane line model so as to obtain the lane line model with the noise added.
Optionally, the lane line fitting device for automatic driving simulation test of the present invention further comprises:
the recalculation module is used for bringing the x coordinate values of the fitting coordinates of the sampling points into the lane line model added with noise, calculating the y coordinate values of the fitting coordinates of a plurality of sampling points to obtain new coordinates of the sampling points, or generating n x coordinate values of n new sampling points in the interval of [0, L ] according to the lane line length L and the number n of coordinate points required by an automatic driving system, bringing the n x coordinate values into the lane line model added with noise, and calculating n y coordinate values of n new sampling points to obtain new coordinates of the new sampling points;
and the second lane line information sending module is used for sending the lane line model added with noise or the lane line model added with noise together with the new coordinates to an automatic driving system.
Fig. 7 illustrates a physical schematic diagram of an electronic device, as shown in fig. 7, which may include: processor 710, communication interface (Communications Interface) 720, memory 730, and communication bus 740, wherein processor 710, communication interface 720, memory 730 communicate with each other via communication bus 740. The processor 710 may invoke logic instructions in the memory 730 to perform a lane line fitting method for automated driving simulation testing, the method comprising:
The first coordinates of the host vehicle in the world coordinate system are converted into second coordinates in the lane coordinate system based on the map corresponding to the simulation scene.
And acquiring second coordinates of a plurality of sampling points on a lane line of each lane in the advancing direction of the main vehicle based on the second coordinates of the main vehicle under the lane coordinate system.
And converting the second coordinate of each sampling point on each lane line into the first coordinate of each sampling point in the world coordinate system.
And determining fitting coordinates of each sampling point according to the first coordinates of each sampling point, and fitting all the sampling points on each lane line based on the fitting coordinates to obtain a lane line model.
Further, the logic instructions in the memory 730 described above may be implemented in the form of software functional units and may be stored in a computer readable storage medium when sold or used as a stand alone product. Based on this understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art or in a part of the technical solution, in the form of a software product stored in a storage medium, comprising several instructions for causing a computer device (which may be a personal computer, a server, a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
In another aspect, the present invention also provides a computer program product comprising a computer program, the computer program being storable on a non-transitory computer readable storage medium, the computer program, when executed by a processor, being capable of performing the lane line fitting method for automated driving simulation testing provided by the above methods, the method comprising:
the first coordinates of the host vehicle in the world coordinate system are converted into second coordinates in the lane coordinate system based on the map corresponding to the simulation scene.
And acquiring second coordinates of a plurality of sampling points on a lane line of each lane in the advancing direction of the main vehicle based on the second coordinates of the main vehicle under the lane coordinate system.
And converting the second coordinate of each sampling point on each lane line into the first coordinate of each sampling point in the world coordinate system.
And determining fitting coordinates of each sampling point according to the first coordinates of each sampling point, and fitting all the sampling points on each lane line based on the fitting coordinates to obtain a lane line model.
In yet another aspect, the present invention also provides a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, is implemented to perform the lane line fitting method for automated driving simulation testing provided by the above methods, the method comprising:
The first coordinates of the host vehicle in the world coordinate system are converted into second coordinates in the lane coordinate system based on the map corresponding to the simulation scene.
And acquiring second coordinates of a plurality of sampling points on a lane line of each lane in the advancing direction of the main vehicle based on the second coordinates of the main vehicle under the lane coordinate system.
And converting the second coordinate of each sampling point on each lane line into the first coordinate of each sampling point in the world coordinate system.
And determining fitting coordinates of each sampling point according to the first coordinates of each sampling point, and fitting all the sampling points on each lane line based on the fitting coordinates to obtain a lane line model.
The apparatus embodiments described above are merely illustrative, wherein the elements illustrated as separate elements may or may not be physically separate, and the elements shown as elements may or may not be physical elements, may be located in one place, or may be distributed over a plurality of network elements. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment. Those of ordinary skill in the art will understand and implement the present invention without undue burden.
From the above description of the embodiments, it will be apparent to those skilled in the art that the embodiments may be implemented by means of software plus necessary general hardware platforms, or of course may be implemented by means of hardware. Based on this understanding, the foregoing technical solution may be embodied essentially or in a part contributing to the prior art in the form of a software product, which may be stored in a computer readable storage medium, such as ROM/RAM, a magnetic disk, an optical disk, etc., including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method described in the respective embodiments or some parts of the embodiments.
Finally, it should be noted that: the above embodiments are only for illustrating the technical solution of the present invention, and are not limiting; although the invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims (11)

1. A lane line fitting method for an automated driving simulation test, comprising:
converting a first coordinate of the host vehicle under a world coordinate system into a second coordinate under a lane coordinate system based on a map corresponding to the simulation scene;
acquiring second coordinates of a plurality of sampling points on a lane line of each lane in the advancing direction of the main vehicle based on the second coordinates of the main vehicle under a lane coordinate system;
converting the second coordinates of each sampling point on each lane line into the first coordinates of each sampling point under the world coordinate system;
and determining fitting coordinates of each sampling point according to the first coordinates of each sampling point, and fitting all the sampling points on each lane line based on the fitting coordinates to obtain a lane line model.
2. The lane line fitting method for an automated driving simulation test according to claim 1, wherein acquiring second coordinates of a plurality of sampling points on a lane line of each lane in a main vehicle advancing direction based on second coordinates of the main vehicle in a lane coordinate system, comprises:
acquiring all lanes in the forward direction of a main vehicle;
setting a virtual starting point on the lane central line of each lane, and making the distance from the origin of the lane coordinate system in the second coordinate of the virtual starting point equal to the distance from the origin of the lane coordinate system in the second coordinate of the host vehicle under the lane coordinate system;
For each lane, determining a plurality of virtual points forwards along the center line of the lane according to the step length set in a preset step length strategy by taking the virtual starting point as a reference, and collecting second coordinates of the plurality of virtual points;
and for each lane, determining sampling points on the lane lines at two sides of the virtual point according to the second coordinates of each virtual point and the lane width so as to obtain the second coordinates of a plurality of sampling points on each lane line.
3. The lane-line fitting method for an autopilot simulation test of claim 2 wherein the preset step size strategy comprises: equal step size strategy, segmentation equal step size strategy or equal difference increment step size strategy;
the equal step strategy is: the step size of each forward movement is equal;
the segmentation equal-step strategy is as follows: dividing the total length of a lane line to be sampled into a plurality of fixed intervals, wherein the step length in each fixed interval is equal, and the shorter the fixed interval is from the virtual starting point, the smaller the corresponding step length is;
the arithmetic increment step strategy is as follows: the step length of the movement from the virtual starting point is in an arithmetic progression relation.
4. The lane line fitting method for an automatic driving simulation test according to claim 1, wherein determining a fitting coordinate of each sampling point according to a first coordinate of each sampling point, and fitting all sampling points on each lane line based on the fitting coordinate to obtain a lane line model, comprises:
Determining the first coordinate of each sampling point as the fitting coordinate;
fitting the fitting coordinates of all the sampling points on each lane line through a unitary fitting function to obtain a lane line model.
5. The lane line fitting method for an automatic driving simulation test according to claim 1, wherein determining a fitting coordinate of each sampling point according to a first coordinate of each sampling point, and fitting all sampling points on each lane line based on the fitting coordinate to obtain a lane line model, comprises:
converting the first coordinate of each sampling point to a third coordinate under a main vehicle coordinate system, and determining the third coordinate of each sampling point as the fitting coordinate;
fitting the fitting coordinates of all the sampling points on each lane line through a unitary fitting function to obtain a lane line model.
6. The lane line fitting method for automated driving simulation testing according to any one of claims 1 to 5, further comprising:
and sending the lane line model or the lane line model together with the fitting coordinates of all sampling points on each lane line to an automatic driving system.
7. The lane line fitting method for an automated driving simulation test according to any one of claims 1 to 5, further comprising, after fitting the fitting coordinates of all the sampling points on each lane line to obtain a lane line model:
and adding noise to the lane line model to obtain the lane line model added with the noise.
8. The lane-line fitting method for an autopilot simulation test of claim 7 further comprising:
the method comprises the steps of bringing x coordinate values of fitting coordinates of sampling points into a lane line model added with noise, calculating y coordinate values of the fitting coordinates of a plurality of sampling points to obtain new coordinates of the sampling points, or generating n x coordinate values of n new sampling points in a section of [0, L ] according to the length L of the lane line and the number n of coordinate points required by an automatic driving system, bringing the n x coordinate values into the lane line model added with noise, and calculating n y coordinate values of n new sampling points to obtain new coordinates of the new sampling points;
and sending the lane line model added with noise or the lane line model added with noise together with the new coordinates to an automatic driving system.
9. A lane line fitting apparatus for automated driving simulation testing, comprising:
The first coordinate conversion module is used for converting a first coordinate of the host vehicle under a world coordinate system into a second coordinate under a lane coordinate system based on a map corresponding to the simulation scene;
the lane line sampling module is used for acquiring second coordinates of a plurality of sampling points on the lane line of each lane in the advancing direction of the main vehicle based on the second coordinates of the main vehicle under the lane coordinate system;
the second coordinate conversion module is used for converting the second coordinate of each sampling point on each lane line into the first coordinate of each sampling point under the world coordinate system;
and the lane line fitting module is used for determining the fitting coordinates of each sampling point according to the first coordinates of each sampling point, and fitting all the sampling points on each lane line based on the fitting coordinates so as to obtain a lane line model.
10. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the lane-fitting method for automated driving simulation testing of any one of claims 1-8 when the program is executed.
11. A non-transitory computer readable storage medium having stored thereon a computer program, which when executed by a processor implements the lane line fitting method for automated driving simulation testing according to any one of claims 1 to 8.
CN202310202189.1A 2023-03-03 2023-03-03 Lane line fitting method and device for automatic driving simulation test Pending CN116383041A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310202189.1A CN116383041A (en) 2023-03-03 2023-03-03 Lane line fitting method and device for automatic driving simulation test

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310202189.1A CN116383041A (en) 2023-03-03 2023-03-03 Lane line fitting method and device for automatic driving simulation test

Publications (1)

Publication Number Publication Date
CN116383041A true CN116383041A (en) 2023-07-04

Family

ID=86962421

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310202189.1A Pending CN116383041A (en) 2023-03-03 2023-03-03 Lane line fitting method and device for automatic driving simulation test

Country Status (1)

Country Link
CN (1) CN116383041A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116822256A (en) * 2023-08-29 2023-09-29 常州星宇车灯股份有限公司 Method for verifying lane line fitting deviation problem by using scene simulation debugging

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116822256A (en) * 2023-08-29 2023-09-29 常州星宇车灯股份有限公司 Method for verifying lane line fitting deviation problem by using scene simulation debugging
CN116822256B (en) * 2023-08-29 2023-11-10 常州星宇车灯股份有限公司 Method for verifying lane line fitting deviation problem by using scene simulation debugging

Similar Documents

Publication Publication Date Title
CN107481292B (en) Attitude error estimation method and device for vehicle-mounted camera
EP3796112B1 (en) Virtual vehicle control method, model training method, control device and storage medium
CN109159113B (en) Robot operation method based on visual reasoning
CN108303103A (en) The determination method and apparatus in target track
CN109426800A (en) A kind of method for detecting lane lines and device
CN112488067B (en) Face pose estimation method and device, electronic equipment and storage medium
CN110119768B (en) Visual information fusion system and method for vehicle positioning
CN115984486B (en) Bridge model generation method and device integrating laser radar and depth camera
CN116383041A (en) Lane line fitting method and device for automatic driving simulation test
CN110910440A (en) Power transmission line length determination method and system based on power image data
CN111812669B (en) Winding machine inspection device, positioning method thereof and storage medium
EP3716103A2 (en) Method and apparatus for determining transformation matrix, and non-transitory computer-readable recording medium
CN112733971B (en) Pose determination method, device and equipment of scanning equipment and storage medium
CN112304322B (en) Restarting method after visual positioning failure and vehicle-mounted terminal
CN117372536A (en) Laser radar and camera calibration method, system, equipment and storage medium
CN117232545A (en) Path planning method based on deep learning road environment perception
CN112419345A (en) Patrol car high-precision tracking method based on echo state network
CN109977884B (en) Target following method and device
CN111812668A (en) Winding inspection device, positioning method thereof and storage medium
CN114913330B (en) Point cloud component segmentation method and device, electronic equipment and storage medium
CN113885496A (en) Intelligent driving simulation sensor model and intelligent driving simulation method
CN112597959A (en) Train safety monitoring method and device based on artificial intelligence and computer vision
CN116466733B (en) Intelligent obstacle avoidance system and method for taking off and landing of unmanned aerial vehicle
CN109901589A (en) Mobile robot control method and apparatus
CN110968722A (en) Platform identification and measurement method for autonomous landing of unmanned aerial vehicle

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination