A motor vehicle lane guardrail detection method and related device
By calculating the relative distance between the detection point and the preset reference curve and screening candidate detection points, combined with the preset angle determination method, the guardrail linear fitting is performed, which solves the problem of low guardrail detection accuracy in the existing technology and achieves higher accuracy. Detection accuracy and user experience.
Patent Information
- Application Number
- CN202110008043.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-01-05
- Publication Date
- 2024-10-11
- Estimated Expiration
- 2041-01-05
AI Technical Summary
The guardrail detection accuracy in existing adaptive cruise control systems is poor and prone to false detections, resulting in poor user experience.
By calculating the relative distance between the detection point and the preset reference curve, the candidate detection point set is screened, and the guardrail linear fitting is performed based on the preset angle determination method to obtain the target guardrail curve. Linear fitting and least squares method quadratic polynomial are used to fit the guardrail curve. Combined methods improve detection accuracy.
It improves the accuracy of guardrail detection, reduces false detections, improves user experience, and ensures the reliability of the adaptive cruise control system.
Smart Images

Figure CN112782661B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of motor vehicles, and in particular to a motor vehicle lane guardrail detection method and related devices. Background Art
[0002] The number of motor vehicles and road traffic in my country has increased dramatically. The safety defense mechanism of the vehicle can ensure the safety of the occupants after being triggered during the driving process of the motor vehicle. For example, the cruise control system of the motor vehicle, especially the adaptive cruise control system, coordinates its control unit with the anti-lock braking system and the engine control system to brake the wheels appropriately and reduce the output power of the engine, so that the vehicle always maintains a safe distance from other vehicles.
[0003] Since the guardrail detection scheme in the existing adaptive cruise control system has poor accuracy, it is easy to make false detections, such as detecting the guardrail as a vehicle, causing the system to decelerate incorrectly, resulting in a poor user experience. Summary of the invention
[0004] The present application provides a motor vehicle lane guardrail detection method and related devices, which are used to alleviate the technical problem that the existing motor vehicle lane guardrail detection accuracy is poor, prone to false detection, resulting in false deceleration of the adaptive cruise control system, and reduced user experience.
[0005] In view of this, the first aspect of the present application provides a motor vehicle lane guardrail detection method, comprising:
[0006] Calculate the relative distance between the detection point obtained by detecting the target guardrail and a preset reference curve, wherein the preset reference curve is obtained by translating the lane curve;
[0007] Using the relative distance to screen the detection points to obtain a candidate detection point set;
[0008] Based on a preset angle determination method, a guardrail linear fitting is performed according to the relative distance and the candidate detection point set to obtain a target guardrail curve.
[0009] Preferably, the configuration process of the preset reference curve is:
[0010] Performing curve fitting on the acquired lane line using a preset polynomial equation to obtain a lane curve, wherein the preset polynomial equation includes a constant term;
[0011] The size of the constant term is adjusted according to a preset step length within a preset constant range to obtain a plurality of preset reference curves parallel to the lane curve.
[0012] Preferably, the using the relative distance to screen the detection points to obtain a candidate detection point set includes:
[0013] Combine the detection points corresponding to the relative distances less than the distance threshold to obtain an initial candidate detection point set, wherein one preset reference curve corresponds to one initial candidate detection point set;
[0014] Calculating an average distance residual of each of the initial candidate detection points according to the relative distances corresponding to the initial candidate detection points, the initial candidate detection point set including a plurality of the initial candidate detection points;
[0015] The initial candidate detection point set corresponding to the smallest average distance residual is selected as the candidate detection point set.
[0016] Preferably, the preset angle determination method is based on which a guardrail linear fitting is performed according to the relative distance and the candidate detection point set to obtain a target guardrail curve, including:
[0017] S1: selecting a first preset number of candidate detection points with the smallest relative distance from the candidate detection point set, and performing a linear fitting on the first preset number of candidate detection points to obtain an initial guardrail curve;
[0018] S2: searching for a new candidate detection point at the extended end of the initial guardrail curve, and generating a fitting candidate vector in combination with the extended end of the initial guardrail curve;
[0019] S3: Determine whether the angle between the fitting candidate vector and the tangent vector of the extended end of the initial guardrail curve is less than a preset angle. If so, fit the new candidate detection point into the initial guardrail curve using a preset fitting method, and repeat steps S2-S3 until the number of candidate detection points on the initial guardrail curve reaches a second preset number, then use the initial guardrail curve as the target guardrail curve.
[0020] Preferably, step S3 further includes:
[0021] It is determined whether the candidate detection points on the initial guardrail curve reach a third preset number. If not, the preset fitting method is a linear fitting method. If so, the preset fitting method is switched to a least squares quadratic polynomial fitting method.
[0022] Preferably, the method based on the preset angle determination method performs guardrail linear fitting according to the candidate detection point set and the candidate curve to obtain a target guardrail curve, and then further includes:
[0023] The distance residual between the preset foreign object point and the target guardrail curve is calculated, and if the distance residual is less than the preset distance value, the preset foreign object point is determined to be a non-vehicle detection point.
[0024] The second aspect of the present application provides a motor vehicle lane guardrail detection device, comprising:
[0025] A calculation module, used to calculate the relative distance between the detection point obtained by detecting the target guardrail and a preset reference curve, wherein the preset reference curve is obtained by translating the lane curve;
[0026] A screening module, used to screen the detection points using the relative distance to obtain a candidate detection point set;
[0027] The curve fitting module is used to perform guardrail linear fitting based on the preset angle determination method according to the relative distance and the candidate detection point set to obtain a target guardrail curve.
[0028] Preferably, the screening module comprises:
[0029] A screening submodule, used for combining the detection points corresponding to the relative distances less than the distance threshold to obtain an initial candidate detection point set, wherein one of the preset reference curves corresponds to one of the initial candidate detection point sets;
[0030] A calculation submodule, configured to calculate an average distance residual of each of the initial candidate detection points according to the relative distances corresponding to the initial candidate detection points, wherein the initial candidate detection point set includes a plurality of the initial candidate detection points;
[0031] The first selection submodule is used to select an initial candidate detection point set corresponding to the smallest average distance residual as a candidate detection point set.
[0032] Preferably, the curve fitting module comprises:
[0033] A second selection submodule is used to select a first preset number of candidate detection points with the smallest relative distance from the candidate detection point set, and perform a linear fitting on the first preset number of candidate detection points to obtain an initial guardrail curve;
[0034] A search submodule, configured to search for a new candidate detection point at the extended end of the initial guardrail curve, and generate a fitting candidate vector in combination with the extended end of the initial guardrail curve;
[0035] The first judgment submodule is used to determine whether the angle between the fitting candidate vector and the tangent vector of the extended end of the initial guardrail curve is less than a preset angle. If so, the new candidate detection point is fitted into the initial guardrail curve using a preset fitting method, triggering the search submodule until the candidate detection points on the initial guardrail curve reach a second preset number, and then the initial guardrail curve is used as the target guardrail curve.
[0036] Preferably, it also includes:
[0037] The second judgment submodule is used to judge whether the candidate detection points on the initial guardrail curve reach a third preset number. If not, the preset fitting method is a linear fitting method. If so, the preset fitting method is switched to a least squares quadratic polynomial fitting method.
[0038] The present application provides a motor vehicle lane guardrail detection device from a third aspect, the device comprising a processor and a memory;
[0039] The memory is used to store program code and transmit the program code to the processor;
[0040] The processor is used to execute the motor vehicle lane guardrail detection method described in any one of the first aspects according to the instructions in the program code.
[0041] The present application provides a computer-readable storage medium from a fourth aspect, wherein the computer-readable storage medium is used to store program code, and the program code is used to execute the motor vehicle lane guardrail detection method described in any one of the first aspects.
[0042] It can be seen from the above technical solutions that the embodiments of the present application have the following advantages:
[0043] In the present application, a motor vehicle lane guardrail detection method is provided, including: calculating the relative distance between the detection point obtained by detecting the target guardrail and a preset reference curve, the preset reference curve being obtained by translating the lane curve; using the relative distance to screen the detection points to obtain a candidate detection point set; based on a preset angle determination method, performing guardrail linear fitting according to the relative distance and the candidate detection point set to obtain a target guardrail curve.
[0044] The motor vehicle lane guardrail detection method provided by the present application detects the guardrail on the lane by means of linear fitting, based on the assumption that the lane guardrail is parallel to the curve formed by the lane line. The advantage is that the continuous curve obtained by linear fitting conforms to the actual characteristics of the guardrail, that is, continuity; moreover, some false detection points can be removed by screening the detection points, and the obtained target guardrail curve is more reliable as the actual guardrail. Therefore, the present application can alleviate the technical problems that the existing motor vehicle lane guardrail detection accuracy is poor, false detection is prone to occur, resulting in false deceleration of the adaptive cruise control system, and reduced user experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0045] Figure 1 A schematic diagram of a flow chart of a motor vehicle lane guardrail detection method provided in an embodiment of the present application;
[0046] Figure 2 Another schematic diagram of a flow chart of a motor vehicle lane guardrail detection method provided in an embodiment of the present application;
[0047] Figure 3 A schematic diagram of the structure of a motor vehicle lane guardrail detection device provided in an embodiment of the present application;
[0048] Figure 4 A schematic diagram of relative distances provided in an embodiment of the present application;
[0049] Figure 5 A schematic diagram of target guardrail curve search and fitting provided in an embodiment of the present application;
[0050] Figure 6 A schematic diagram of the distance between a preset foreign object point and a target guardrail curve provided in an embodiment of the present application. DETAILED DESCRIPTION
[0051] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0052] For easier understanding, see Figure 1 , Embodiment 1 of a motor vehicle lane guardrail detection method provided by the present application includes:
[0053] Step 101: Calculate the relative distance between the detection point obtained by detecting the target guardrail and the preset reference curve, where the preset reference curve is obtained by translating the lane curve.
[0054] The millimeter-wave radar used to detect the target guardrail can easily obtain multiple detection points of the guardrail beside the lane, especially the metal guardrail. The number of detection points can be set according to the actual situation. To ensure accuracy, multiple detection points within the preset range can be obtained. In addition to using millimeter-wave radar to detect guardrail information, laser radar can also be used to collect point cloud data of the guardrail.
[0055] The preset reference curve is obtained by translating the lane curve. Here, a priori knowledge or an assumption is applied that the trend of most lane guardrails is consistent with the trend of the corresponding side lane line. The specific process is: the lane line can be identified by the camera on the motor vehicle, and the lane line at the near end has higher accuracy; then the lane line is fitted using a polynomial equation to obtain the lane curve; finally, the constant term of the lane curve is translated and traversed on the set coordinate system axis to obtain multiple different preset reference curves, and each of them is parallel to the lane curve.
[0056] Each preset reference curve can be used to calculate the relative distance, and the relative distance between each detection point and different preset reference curves is also different. Therefore, each detection point can obtain a batch of relative distance values according to the preset reference curve.
[0057] Step 102: Use relative distance to screen the detection points to obtain a set of candidate detection points.
[0058] Not all detection points are accurate, there may be false detections or noise points, so they need to be screened by relative distance. The basic principle is that the closer the detection point is to the preset reference curve, the higher the possibility that the detection point is a point on the guardrail. Such detection points need to be retained to form a candidate detection point set; detection points that are too far away are directly eliminated.
[0059] Step 103: Based on the preset angle determination method, a guardrail linear fitting is performed according to the relative distance and the candidate detection point set to obtain a target guardrail curve.
[0060] The preset angle determination method is used to constrain the curve trend in the linear fitting process so that it will not deviate too much from the actual direction of the guardrail. The larger the angle, the greater the possibility of fitting deviation. Therefore, it is necessary to ensure that the curve trend in the fitting process is within a certain angle range.
[0061] Linear fitting is actually the process of connecting candidate detection points according to a given linear fitting method to obtain a curve expression. The obtained continuous target guardrail curve is the continuous lane guardrail.
[0062] The motor vehicle lane guardrail detection method provided in the embodiment of the present application detects the guardrail on the lane by linear fitting, based on the assumption that the lane guardrail is parallel to the curve formed by the lane line. The advantage is that the continuous curve obtained by linear fitting conforms to the actual characteristics of the guardrail, that is, continuity; moreover, some false detection points can be removed by screening the detection points, and the obtained target guardrail curve is more reliable as the actual guardrail. Therefore, the embodiment of the present application can alleviate the technical problems that the existing motor vehicle lane guardrail detection accuracy is poor, false detection is prone to occur, resulting in false deceleration of the adaptive cruise control system, and reduced user experience.
[0063] The above is an embodiment of a motor vehicle lane guardrail detection method provided by the present application, and the following is another embodiment of a motor vehicle lane guardrail detection method provided by the present application.
[0064] For easier understanding, see Figure 2 The present application provides a second embodiment of a motor vehicle lane guardrail detection method, comprising:
[0065] Step 201: Use a preset polynomial equation to perform curve fitting on the acquired lane line to obtain a lane curve, where the preset polynomial equation includes a constant term.
[0066] Step 202: Adjust the size of the constant term according to the preset step length within the preset constant range to obtain a plurality of preset reference curves parallel to the lane curve.
[0067] In the embodiment of the present application, the preset polynomial equation is set to be a cubic polynomial equation, and the coefficients of the linear term, quadratic term, cubic term and constant term of the equation can be represented by C1, C2, C3 and C0 respectively. The lane line is obtained by a camera.
[0068] In order to facilitate the selection of the preset constant range, a coordinate system can be set, the lane curve can be moved parallel to the coordinate system, and the size of the constant term can be adjusted to obtain several preset baselines; the operation is simpler in the coordinate system and it is not easy to exceed the preset constant range. The preset constant range is configured according to actual conditions and is not limited here.
[0069] Step 203: Calculate the relative distance between the detection point obtained by detecting the target guardrail and the preset reference curve, where the preset reference curve is obtained by translating the lane curve.
[0070] Step 204: Combine the detection points corresponding to the relative distances less than the distance threshold to obtain an initial candidate detection point set. One preset reference curve corresponds to one initial candidate detection point set.
[0071] See also Figure 4 In the coordinate system, the relative distance between each detection point SGU and the preset reference curve is recorded as r, and the detection points less than the distance threshold are retained and combined to obtain the initial candidate detection point set. The distance threshold is set according to actual needs. This part of the screening is directly based on the relative distance to eliminate points with large differences. After preliminary screening, the number of detection points in the initial candidate detection point set corresponding to each preset reference curve is less than or equal to the original number of detection points.
[0072] Step 205: Calculate the average distance residual of each initial candidate detection point set according to the relative distances corresponding to the initial candidate detection points, where the initial candidate detection point set includes a plurality of initial candidate detection points.
[0073] Step 206: Select the initial candidate detection point set corresponding to the minimum average distance residual as the candidate detection point set.
[0074] Since there are multiple initial candidate detection point sets, the candidate detection point set with the highest matching degree with the guardrail can be selected by screening the average distance residual. Each initial candidate detection point set can obtain an average distance residual, and the average distance residuals corresponding to the initial candidate detection point sets corresponding to different preset reference curves are arranged in ascending order. The initial candidate detection point set corresponding to the first smallest average distance residual is the point set with the highest matching degree with the guardrail, that is, the candidate detection point set.
[0075] Step 207: Select a first preset number of candidate detection points with the smallest relative distance from the candidate detection point set, and perform a linear fit on the first preset number of candidate detection points to obtain an initial guardrail curve.
[0076] See also Figure 5 In the embodiment of the present application, the first preset number is set to 4; the relative distances of all candidate detection points in the candidate detection point set are arranged in ascending order, and the first four candidate detection points with the smallest relative distances can be obtained. A linear fit can be performed based on these four points to obtain an initial guardrail curve l. The initial guardrail curve obtained by the preliminary fitting should be a straight line, which can be understood as a special curve.
[0077] Step 208: Search for a new candidate detection point at the extended end of the initial guardrail curve, and generate a fitting candidate vector in combination with the extended end of the initial guardrail curve.
[0078] Step 209, determine whether the angle between the fitting candidate vector and the tangent vector of the extended end of the initial guardrail curve is less than the preset angle. If so, use the preset fitting method to fit the new candidate detection point into the initial guardrail curve, and repeat steps 208-209 until the candidate detection points on the initial guardrail curve reach the second preset number, and then use the initial guardrail curve as the target guardrail curve.
[0079] Figure 5 Point A in the figure is the extension end of the initial guardrail curve and the starting point for searching for candidate detection points. Points B and C are both new candidate detection points. Point C is searched first. Combined with point A, the extension end of the initial guardrail curve, a fitting candidate vector can be generated.
[0080] The tangent vector of the extended end of the initial guardrail curve is vector With vector The angle between them is represented by θ. If the angle is less than the preset angle θ0, point C is added to the curve, that is, the new candidate detection point is fitted into the guardrail curve using the preset fitting method. If the angle is not less than the preset angle, the point is discarded and the search for new candidate detection points continues. Repeated searches for candidate detection points and fitting curves can traverse all points in the candidate detection point set, but in actual operation, a complete traversal is not required. Instead, when the candidate detection points on the initial guardrail curve reach the second preset number, it can be determined that the initial guardrail curve obtained by fitting is the target guardrail curve, that is, the guardrail has been detected.
[0081] Although the preset angle is set according to the actual situation, it is generally small, such as 3°. The preset fitting methods include a relatively simple linear fitting method and a relatively accurate least squares quadratic polynomial fitting method, which can be selected according to the judgment requirements. The second preset number setting should be larger than the first preset number. In the embodiment of the present application, it is set to 10, that is, there are 10 candidate detection points on the initial guardrail curve, and the initial guardrail curve is considered to be the target guardrail curve.
[0082] It can be understood that the shape and direction of the target guardrail curve are the same as those of the lane curve, but the constant terms of the description equations of the two are different.
[0083] Furthermore, step 209 further includes:
[0084] It is determined whether the candidate detection points on the initial guardrail curve reach a third preset number. If not, the preset fitting method is a linear fitting method. If so, the preset fitting method is switched to a least squares quadratic polynomial fitting method.
[0085] The two preset fitting methods listed above can be selected according to the number of candidate detection points on the initial guardrail curve. According to the above setting of the number of candidate detection points, the third preset number is set to 7 here, that is, a linear fitting operation is performed using a linear fitting method from the initial 4 candidate detection points to the 7th candidate detection point; at the 8th candidate detection point, if the angle condition is determined to be met, the preset fitting method is switched to the least squares quadratic polynomial fitting method, and the 8th candidate detection point is fitted to the initial guardrail curve. The curve obtained by the least squares quadratic polynomial fitting method can fit the detection points as closely as possible, making the curve description more accurate.
[0086] Step 210: Calculate the distance residual between the preset foreign object point and the target guardrail curve. If the distance residual is less than the preset distance value, determine that the preset foreign object point is a non-vehicle detection point.
[0087] The purpose here is to eliminate suspected vehicle points of the guardrail, that is, the guardrail is mistakenly identified as a motor vehicle or a bicycle in the adaptive cruise control system, resulting in the vehicle's false deceleration during the adaptive cruise. The preset foreign object point is the target point detected by the camera and the millimeter-wave radar. Under normal circumstances, the camera will not obtain guardrail information, but only obtain vehicle and lane line information. However, in the case of false detection, the guardrail information corresponding to the millimeter-wave radar detection will be detected. At this time, the two types of information will be fused, and the guardrail information will be identified as vehicle information, thereby outputting a very low speed trigger information, resulting in false deceleration. Please refer to Figure 6 , the preset foreign body point in the figure is recorded as TGU, and the distance residual is recorded as d gt .
[0088] The preset distance value is generally set to be relatively small, such as 0.3 m. Correctly determining that the preset foreign object point is a non-vehicle detection point can avoid false deceleration caused by false detection in the adaptive cruise control system.
[0089] The preset distance value is used for judgment. If the distance residual value between the preset foreign object point and the target guardrail curve is less than the preset distance value, the preset foreign object point can be judged as a non-vehicle detection point.
[0090] The above is an embodiment of a motor vehicle lane guardrail detection method provided by the present application, and the following is an embodiment of a motor vehicle lane guardrail detection device provided by the present application.
[0091] For easier understanding, see Figure 3 The present application also provides an embodiment of a motor vehicle lane guardrail detection device, including:
[0092] A calculation module 301 is used to calculate the relative distance between the detection point obtained by detecting the target guardrail and a preset reference curve, where the preset reference curve is obtained by translating the lane curve;
[0093] A screening module 302 is used to screen the detection points using relative distances to obtain a candidate detection point set;
[0094] The curve fitting module 303 is used to perform guardrail linear fitting based on a preset angle determination method according to the relative distance and the candidate detection point set to obtain a target guardrail curve.
[0095] Furthermore, the screening module 302 includes:
[0096] A screening submodule 3021 is used to combine the detection points corresponding to the relative distances less than the distance threshold to obtain an initial candidate detection point set, where one preset reference curve corresponds to one initial candidate detection point set;
[0097] A calculation submodule 3022 is used to calculate the average distance residual of each initial candidate detection point set according to the relative distance corresponding to the initial candidate detection point, and the initial candidate detection point set includes a plurality of initial candidate detection points;
[0098] The first selection submodule 3023 is used to select an initial candidate detection point set corresponding to the minimum average distance residual as a candidate detection point set.
[0099] Furthermore, the curve fitting module 303 includes:
[0100] The second selection submodule 3031 is used to select a first preset number of candidate detection points with the smallest relative distance from the candidate detection point set, and perform a linear fitting on the first preset number of candidate detection points to obtain an initial guardrail curve;
[0101] A search submodule 3032 is used to search for new candidate detection points at the extended end of the initial guardrail curve, and generate a fitting candidate vector in combination with the extended end of the initial guardrail curve;
[0102] The first judgment submodule 3033 is used to determine whether the angle between the fitting candidate vector and the tangent vector of the extended end of the initial guardrail curve is less than a preset angle. If so, the new candidate detection point is fitted into the initial guardrail curve using a preset fitting method, triggering the search submodule until the number of candidate detection points on the initial guardrail curve reaches a second preset number, and the initial guardrail curve is used as the target guardrail curve.
[0103] Furthermore, it also includes:
[0104] The second judgment submodule 304 is used to judge whether the candidate detection points on the initial guardrail curve reach a third preset number. If not, the preset fitting method is a linear fitting method. If so, the preset fitting method is switched to a least squares quadratic polynomial fitting method.
[0105] The present application also provides a motor vehicle lane guardrail detection device, the device comprising a processor and a memory;
[0106] The memory is used to store program code and transmit the program code to the processor;
[0107] The processor is used to execute the motor vehicle lane guardrail detection method in the above method embodiment according to the instructions in the program code.
[0108] The present application also provides a computer-readable storage medium, which is used to store program code, and the program code is used to execute the motor vehicle lane guardrail detection method in the above method embodiment.
[0109] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0110] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0111] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0112] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for executing all or part of the steps of the method described in each embodiment of the present application through a computer device (which can be a personal computer, a server, or a network device, etc.). The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (full name in English: Read-Only Memory, English abbreviation: ROM), random access memory (full name in English: Random Access Memory, English abbreviation: RAM), disk or optical disk and other media that can store program codes.
[0113] As described above, the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application.
Claims
1. A motor vehicle lane guardrail detection method, characterized in that: include: Calculate the relative distance between the detection point obtained by detecting the target guardrail and a preset reference curve, wherein the preset reference curve is obtained by translating the lane curve; Using the relative distance to screen the detection points to obtain a candidate detection point set; Based on the preset angle determination method, a guardrail linear fitting is performed according to the relative distance and the candidate detection point set to obtain the target guardrail curve. The specific process is as follows: S1: selecting a first preset number of candidate detection points with the smallest relative distance from the candidate detection point set, and performing a linear fitting on the first preset number of candidate detection points to obtain an initial guardrail curve; S2: searching for a new candidate detection point at the extended end of the initial guardrail curve, and generating a fitting candidate vector in combination with the extended end of the initial guardrail curve; S3: Determine whether the angle between the fitting candidate vector and the tangent vector of the extended end of the initial guardrail curve is less than a preset angle. If so, fit the new candidate detection point into the initial guardrail curve using a preset fitting method, and repeat steps S2-S3 until the number of candidate detection points on the initial guardrail curve reaches a second preset number, then use the initial guardrail curve as the target guardrail curve.
2. The motor vehicle lane guardrail detection method according to claim 1, characterized in that: The configuration process of the preset reference curve is: Performing curve fitting on the acquired lane line using a preset polynomial equation to obtain a lane curve, wherein the preset polynomial equation includes a constant term; The size of the constant term is adjusted according to a preset step length within a preset constant range to obtain a plurality of preset reference curves parallel to the lane curve.
3. The motor vehicle lane guardrail detection method according to claim 1, characterized in that: The using the relative distance to screen the detection points to obtain a candidate detection point set includes: Combine the detection points corresponding to the relative distances less than the distance threshold to obtain an initial candidate detection point set, wherein one preset reference curve corresponds to one initial candidate detection point set; Calculating an average distance residual of each of the initial candidate detection points according to the relative distances corresponding to the initial candidate detection points, the initial candidate detection point set including a plurality of the initial candidate detection points; The initial candidate detection point set corresponding to the smallest average distance residual is selected as the candidate detection point set.
4. The motor vehicle lane guardrail detection method according to claim 1, characterized in that: Step S3 further includes: It is determined whether the candidate detection points on the initial guardrail curve reach a third preset number. If not, the preset fitting method is a linear fitting method. If so, the preset fitting method is switched to a least squares quadratic polynomial fitting method.
5. The motor vehicle lane guardrail detection method according to claim 1, characterized in that: The method based on the preset angle determination method performs guardrail linear fitting according to the relative distance and the candidate detection point set to obtain a target guardrail curve, and then further includes: The distance residual between the preset foreign object point and the target guardrail curve is calculated, and if the distance residual is less than the preset distance value, the preset foreign object point is determined to be a non-vehicle detection point.
6. A motor vehicle lane guardrail detection device, characterized in that: include: A calculation module, used to calculate the relative distance between the detection point obtained by detecting the target guardrail and a preset reference curve, wherein the preset reference curve is obtained by translating the lane curve; A screening module, used to screen the detection points using the relative distance to obtain a set of candidate detection points; A curve fitting module is used to perform guardrail linear fitting based on the preset angle determination method according to the relative distance and the candidate detection point set to obtain a target guardrail curve. The curve fitting module includes: A second selection submodule is used to select a first preset number of candidate detection points with the smallest relative distance from the candidate detection point set, and perform a linear fitting on the first preset number of candidate detection points to obtain an initial guardrail curve; A search submodule, configured to search for a new candidate detection point at the extended end of the initial guardrail curve, and generate a fitting candidate vector in combination with the extended end of the initial guardrail curve; The first judgment submodule is used to determine whether the angle between the fitting candidate vector and the tangent vector of the extended end of the initial guardrail curve is less than a preset angle. If so, the new candidate detection point is fitted into the initial guardrail curve using a preset fitting method, triggering the search submodule until the candidate detection points on the initial guardrail curve reach a second preset number, and then the initial guardrail curve is used as the target guardrail curve.
7. The motor vehicle lane guardrail detection device according to claim 6, characterized in that: The screening module comprises: A screening submodule, used for combining the detection points corresponding to the relative distances less than the distance threshold to obtain an initial candidate detection point set, wherein one of the preset reference curves corresponds to one of the initial candidate detection point sets; A calculation submodule, configured to calculate an average distance residual of each of the initial candidate detection points according to the relative distances corresponding to the initial candidate detection points, wherein the initial candidate detection point set includes a plurality of the initial candidate detection points; The first selection submodule is used to select an initial candidate detection point set corresponding to the smallest average distance residual as a candidate detection point set.
8. The motor vehicle lane guardrail detection device according to claim 6, characterized in that: Also includes: The second judgment submodule is used to judge whether the candidate detection points on the initial guardrail curve reach a third preset number. If not, the preset fitting method is a linear fitting method. If so, the preset fitting method is switched to a least squares quadratic polynomial fitting method.
9. A motor vehicle lane guardrail detection device, characterized in that: The device comprises a processor and a memory; The memory is used to store program code and transmit the program code to the processor; The processor is used to execute the motor vehicle lane guardrail detection method described in any one of claims 1-5 according to the instructions in the program code.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium is used to store program code, and the program code is used to execute the motor vehicle lane guardrail detection method according to any one of claims 1-5.
