Lane line anomaly detection method and device, electronic equipment and readable storage medium
By acquiring and calculating the curvature and distance of lane line shape points and driving trajectory shape points, the problem of inaccurate evaluation of lane line smoothness and width is solved, enabling accurate identification of lane line anomalies and meeting the needs of autonomous driving.
Patent Information
- Application Number
- CN202211047050.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-08-30
- Publication Date
- 2025-11-21
- Estimated Expiration
- 2042-08-30
AI Technical Summary
Existing lane line anomaly detection methods are not accurate enough in evaluating the smoothness of lane lines and cannot accurately identify abnormalities such as whether the lane line width is normal, whether there are missing lane lines, or whether there are intersections, thus failing to meet the needs of modern autonomous driving.
By acquiring lane line shape points and driving trajectory shape points, calculating the curvature and distance of lane line shape points, judging lane line smoothness and width anomalies, and using UTM coordinate transformation and heading angle to assist in judging smoothness, accurately identifying lane line smoothness, width, missing, intersection and other anomalies.
It achieves accurate detection of lane line smoothness and width, and can identify lane line anomalies, meeting the needs of modern autonomous driving.
Smart Images

Figure CN115311640B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of automatic driving, in particular to a lane line anomaly detection method and device, electronic equipment and readable storage medium. BACKGROUND
[0002] With the rapid development of computer technology, the technology of automatic driving vehicles is also progressing, and currently, many manufacturers have begun to develop fully automatic driving vehicles.
[0003] In order to realize automatic driving, it is a key technology to identify the lane line on the road, which needs to identify the specific situation of the lane line on the road, such as whether the lane line is normal, whether the lane line is a turn or a U-turn, and at the same time, it also needs to detect whether the lane line is missing, whether the width is normal, etc. However, in the detection method for lane line anomaly, the smoothness evaluation of the lane line is not accurate enough, and it cannot accurately identify whether the width of the lane line is normal, whether the lane line is missing, crossing, etc. Abnormal situation, which does not meet the needs of modern automatic driving. SUMMARY
[0004] To solve or partially solve the problems in the related art, the present application provides a lane line anomaly detection method, which can accurately detect the smoothness of the lane line and accurately identify the abnormal situation of the lane line width, missing, crossing, too close, etc.
[0005] The first aspect of the present application provides a lane line anomaly detection method, which comprises:
[0006] Obtaining lane line shape points and driving trajectory shape points, wherein the lane line shape points are used to represent the lane line to be detected, and the driving trajectory shape points are used to represent the driving trajectory of the detection vehicle;
[0007] Calculating the curvature of each point in the lane line shape points, and judging the smoothness anomaly of the lane line to be detected based on the curvature;
[0008] For any one of the driving trajectory shape points, determining a first calculation point on each lane line closest to the arbitrary one driving trajectory shape point, calculating the distance between each first calculation point and at least one other closest first calculation point, and determining the width anomaly of the lane line based on the distance.
[0009] As a possible implementation manner of the present application, in this implementation manner, the lane line shape points and the driving trajectory shape points are obtained, comprising:
[0010] obtain the latitude and longitude information of the lane line to be detected, convert the latitude and longitude information of the lane line to be detected into the latitude and longitude information of the lane line shape point, and convert the latitude and longitude information of each point in the lane line shape point into coordinate information in the UTM coordinate system;
[0011] obtain the latitude and longitude information of the driving track of the detection vehicle, convert the latitude and longitude information of the driving track into the latitude and longitude information of each point in the driving track shape point, and convert the latitude and longitude information of each point in the driving track shape point into coordinate information in the UTM coordinate system.
[0012] As a possible implementation of the present application, in this implementation, the curvature of each point in the lane line shape point is calculated, and the smoothness abnormality of the lane line to be detected is determined based on the curvature, comprising:
[0013] For the first lane line shape point of each lane line to be detected, the curvature value of the first lane line shape point is calculated, and the curvature type of the first lane line shape point is determined based on the curvature value;
[0014] determine the curvature type of the second lane line shape point, wherein the second lane line shape point is a preset number of lane line shape points before and after the first lane line shape point on the lane line where the first lane line shape point is located;
[0015] determine the percentage of the lane line shape points in the second lane line shape point whose curvature type is the same as that of the first lane line shape point in the number of the second lane line shape points;
[0016] determine whether the percentage is greater than a preset threshold, when the percentage is not less than the preset threshold, determine that the smoothness of the first lane line shape point is normal, and when the percentage is less than the preset threshold, determine that the smoothness of the first lane line shape point is abnormal.
[0017] As a possible implementation of the present application, in this implementation, determining the lane line smoothness abnormality further comprises:
[0018] For the first lane line shape point of each lane line to be detected, the heading angle of the first lane line shape point is calculated, and the heading angle threshold of the lane line to be detected is obtained;
[0019] determine the heading angle of the third lane line shape point, wherein the third lane line shape point is a lane line shape point adjacent to the first lane line shape point on the lane line where the first lane line shape point is located;
[0020] A difference between a heading angle of the first lane line shape point and a heading angle of the third lane line shape point is calculated, and when the difference is greater than the heading angle threshold, it is determined that the smoothness of the first lane line shape point is abnormal.
[0021] As a possible implementation of the present application, in this implementation, for any one of the driving trajectory shape points, a first calculation point on each lane line closest to the any one driving trajectory shape point is determined, a distance between each first calculation point and at least one other closest first calculation point is calculated, and a width abnormality of the lane line is determined based on the distance, including:
[0022] For a first driving trajectory shape point among the driving trajectory shape points, a first lane line segment and a second lane line segment on each to-be-detected lane line are determined, wherein the first lane line segment is a lane line segment on the to-be-detected lane line with a lane line shape point closest to the first driving trajectory shape point as a starting point, the second lane line segment is a lane line segment on the to-be-detected lane line with the lane line shape point closest to the first driving trajectory shape point as an ending point, and lengths of the first lane line segment and the second lane line segment are distances between adjacent two lane line shape points;
[0023] A point closest to the first driving trajectory shape point among the first lane line segment and the second lane line segment is determined as a calculation point;
[0024] All calculation points on the to-be-detected lane lines are arranged from left to right according to spatial positional relationships with the first driving trajectory shape point, and distances between adjacent two calculation points are calculated;
[0025] A distance between any two adjacent calculation points is compared with a lane line width threshold, and when a difference between the distance and the lane line width threshold exceeds a preset range, it is determined that a lane line width corresponding to the any two adjacent calculation points is abnormal.
[0026] As a possible implementation of the present application, in this implementation, for each first driving trajectory shape point, the method further includes:
[0027] A number of to-be-detected lane lines within a preset distance before and after each lane line shape point is determined;
[0028] When a number of to-be-detected lane lines at a position of the lane line shape point is less than a number of to-be-detected lane lines within a preset distance before and after the lane line shape point, it is determined that the to-be-detected lane line at the position of the lane line shape point belongs to an edge missing lane line.
[0029] In a possible implementation of the present application, in which the curvature is used to determine the smoothness abnormality of the lane line to be detected, the method comprises:
[0030] The curvature is used to determine the direction of the lane line to be detected.
[0031] The second aspect of the present application provides a lane line abnormality detection device, which comprises:
[0032] An information acquisition module is configured to acquire lane line shape points and driving track shape points, wherein the lane line shape points are used to represent the lane line to be detected, and the driving track shape points are used to represent the driving track of the detection vehicle;
[0033] A smoothness abnormality determination module is configured to calculate the curvature of each point in the lane line shape points, and determine the smoothness abnormality of the lane line to be detected based on the curvature.
[0034] A width abnormality determination module is configured to determine, for any one of the driving track shape points, a first calculation point on each lane line closest to the any one driving track shape point, calculate the distance between each first calculation point and at least one other closest first calculation point, and determine the width abnormality of the lane line based on the distance.
[0035] The third aspect of the present application provides an electronic device, which comprises:
[0036] A processor; and
[0037] A memory having executable code stored thereon, wherein the executable code, when executed by the processor, causes the processor to perform the method described above.
[0038] The fourth aspect of the present application provides a computer readable storage medium having executable code stored thereon, wherein the executable code, when executed by the processor of an electronic device, causes the processor to perform the method described above.
[0039] The embodiment of the present application can accurately identify the smoothness of the lane line by representing the lane line to be detected in the form of a lane line shape point set and calculating the curvature of each lane line shape point, and determining the smoothness abnormality of the lane line to be detected based on the curvature. The embodiment of the present application can accurately identify the abnormality of each lane line, such as whether the width of the lane line is normal or the lane line is missing, by representing the driving track of the detection vehicle in the form of a driving track shape point set, determining the first lane line shape point closest to any point on each lane line for each driving track shape point, calculating the distance between each first lane line shape point and at least one other first lane line shape point closest thereto, and determining the width abnormality of the lane line based on the distance. The lane line is detected by scattered points, the smoothness evaluation of the lane line is more accurate, and the width, missing, intersection and too close abnormality of the lane line can be evaluated, meeting the modern demand.
[0040] It should be understood that the foregoing general description and the following detailed description are only exemplary and explanatory, and are not limiting to the present application. BRIEF DESCRIPTION OF DRAWINGS
[0041] The above and other objects, features and advantages of the present application will become more apparent from the following detailed description when taken in conjunction with the accompanying drawings in which like reference characters refer to like parts throughout the several views, and in which:
[0042] Figure 1 is a flowchart of a lane line abnormality detection method according to an embodiment of the present application;
[0043] Figure 2 is a lane line display diagram according to an embodiment of the present application;
[0044] Figure 3 is a curvature calculation point diagram according to an embodiment of the present application;
[0045] Figure 4 is a first calculation point diagram according to an embodiment of the present application;
[0046] Figure 5 is a flowchart of a coordinate conversion method according to an embodiment of the present application;
[0047] Figure 6 is a flowchart of a smoothness abnormality detection method according to an embodiment of the present application;
[0048] Figure 7 is a curvature type diagram according to an embodiment of the present application;
[0049] Figure 8 is a flowchart of another smoothness abnormality detection method according to an embodiment of the present application;
[0050] Figure 9 is a flowchart of a lane line width anomaly detection method according to an embodiment of the present application;
[0051] Figure 10 is a schematic diagram of determining a calculation point according to an embodiment of the present application;
[0052] Figure 11 is a structural schematic diagram of a lane line anomaly detection device according to an embodiment of the present application;
[0053] Figure 12 is a structural schematic diagram of an electronic device according to an embodiment of the present application.
[0054] The above and other features, aspects, and advantages of the present disclosure will become more apparent with reference to the following detailed description when taken in conjunction with the accompanying drawings. Throughout the drawings, the same or like reference numerals are used to represent the same or similar elements. It is to be understood that the drawings are schematically showing the elements and features, which are not necessarily drawn to scale. DETAILED DESCRIPTION
[0055] Embodiments of the present application will be described in greater detail below with reference to the accompanying drawings. While embodiments of the present application are shown in the drawings, it is understood that the present application can be embodied in various forms without being limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the application to those skilled in the art.
[0056] The terminology used in the present application is for the purpose of describing particular embodiments only and is not intended to be limiting of the present application. As used in the present application and the appended claims, the singular forms "a," "an" and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will be further understood that the terms "comprises" and / or "comprising," when used in this specification, specify the presence of stated features, integers, steps, operations, elements, and / or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and / or groups thereof.
[0057] It is to be understood that the terms "first," "second," "third," and so on, as used in describing various information, do not limit the information. Rather, these terms are used to differentiate between one information and another of the same type. For example, a first information can also be referred to as a second information, and similarly, a second information can also be referred to as a first information, without departing from the scope of the present application. As such, features defined with "first," "second" can explicitly or implicitly include one or more of the features. In the description of the present application, the meaning of "a plurality of" is two or more, unless otherwise specifically defined.
[0058] With the rapid development of computer technology, the technology of automatic driving vehicle is also progressing, at present, many manufacturers have begun to develop full automatic driving vehicle. In order to realize automatic driving of vehicle, the identification of lane line on road is a key technology, which needs to identify the specific situation of lane line on road, such as whether the lane line is normal, whether the lane line is turning, U-turn and the like, and also needs to detect whether the lane line is missing, whether the width of lane line is normal and the like, and in the detection method for abnormal situation of lane line, the smoothness evaluation of lane line is often not accurate enough, and the width of lane line is not accurately identified, whether the lane line is missing, crossing and other abnormal situations, which cannot meet the modern demand.
[0059] In view of the above problems, the embodiment of the present application provides a lane line abnormality detection method, which can accurately detect the smoothness of lane line and accurately identify the abnormal situations of lane line width, missing, crossing and too close.
[0060] The technical solutions of the embodiments of the present application are described in detail below with reference to the drawings.
[0061] Figure 1 is a flowchart of the lane line abnormality detection method shown in the embodiments of the present application.
[0062] Referring to Figure 1 , the lane line abnormality detection method shown in the embodiments of the present application comprises:
[0063] Step S101, acquiring lane line shape points and driving trajectory shape points, wherein the lane line shape points are used to represent the lane line to be detected, and the driving trajectory shape points are used to represent the driving trajectory of the detection vehicle.
[0064] In the embodiments of the present application, the lane line shape points are points used to represent the lane line to be detected, and the set of all points can be fitted as the lane line to be detected. For a lane line to be detected, the code conversion of the lane line in the picture or video can be performed by shooting the picture or video of the lane line to be detected, and the lane line to be detected can be represented by the set of points, and optionally, the lane line to be detected can be represented by uniformly discrete points. In the embodiments of the present application, the driving trajectory shape points refer to points used to represent the driving trajectory of the detection vehicle, wherein the detection vehicle refers to the vehicle used to shoot the lane line to be detected, which can be a manually driven vehicle or an automatic driving vehicle, wherein the driving trajectory of the detection vehicle should be on the road and in the lane line, and for a certain section of road, if there are multiple lane lines on the road, the detection vehicle can drive in any two adjacent lane lines. As a possible implementation manner of the present application, the driving trajectory of the detection vehicle does not coincide with the lane line.
[0065] As a possible implementation manner of the present application, for the convenience of description, a specific embodiment is taken as an example, such as Figure 2As shown, lane lines a and b are represented as lane line shape points, and the vehicle's trajectory c is represented as trajectory shape points, where trajectory c lies between lane lines a and b. Of course, in practice, the number, length, width, direction, and turning conditions of lane lines can be determined according to actual conditions, and the vehicle's trajectory can also be determined accordingly; this application does not impose any restrictions on these aspects.
[0066] Step S102: Calculate the curvature of each point in the lane line shape points, and determine the smoothness abnormality of the lane line to be detected based on the curvature.
[0067] In this embodiment, the curvature of each point among the lane line shape points refers to the curvature of the lane line at the location of the lane line shape point on the lane line to be detected. When calculating the curvature of a certain point among the lane line shape points, it can be calculated using the curvature formula using that point and the two lane line shape points adjacent to that point on the lane line. By comparing the curvature of the lane line shape point on the lane line to be detected with the curvature of other lane line shape points adjacent to that point, it can be determined whether the curvature of the lane line shape point is abnormal, and thus whether the smoothness of the lane line where the lane line shape point is located is abnormal.
[0068] As one possible implementation of this application, for ease of explanation, a specific embodiment is taken as an example, such as... Figure 3 As shown, for lane line d, there exists a lane line shape point d1. When calculating the curvature of lane line shape point d1, the curvature of lane line shape point d1 is calculated through its two adjacent lane line shape points d0 and d2. Similarly, the curvature of all lane line shape points on the lane line to be detected can be calculated. By comparing the magnitude of the curvature between adjacent lane line shape points, the smoothness abnormality of the lane line shape points can be determined.
[0069] Step S103: For any one of the driving trajectory shape points, determine the first calculation point on each lane line that is closest to the arbitrary driving trajectory shape point, calculate the distance between each first calculation point and at least one other nearest first calculation point, and determine the lane line width anomaly based on the distance.
[0070] In the embodiments of the present application, the first calculation point is a point on the driving trajectory shape point, and the point on the to-be-detected lane line closest to the point on the driving trajectory shape point, wherein the first calculation point can be a lane line shape point or not. In determining the width abnormality of the to-be-detected lane line, for any point on the driving trajectory shape point, for any one of the driving trajectory shape points, the first calculation point on each lane line closest to the any one driving trajectory shape point is determined, for example, if there are three to-be-detected lane lines, then for one driving trajectory shape point, three first calculation points should be obtained, then the distance between the adjacent two first calculation points is calculated, two distances are obtained, based on the distance, whether the width between the corresponding two lane lines is abnormal can be determined. The specific judgment method will be described later.
[0071] As a possible implementation manner of the present application, for the convenience of description, a specific embodiment is taken as an example, as shown in Figure 4 The lane line a and the lane line b are displayed in the form of lane line shape points, and the driving trajectory c of the vehicle is displayed in the form of driving trajectory shape points, wherein for a driving trajectory point c1 on the driving trajectory c, the first calculation point a1 on the lane line a closest to the driving trajectory point c1 and the first calculation point b1 on the lane line b closest to the driving trajectory point c1 are determined, then the distance x1 of the line segment a1-b1 is calculated, and then whether the width between the lane line a and the lane line b is normal is determined according to x1. Specifically, when the value of x1 is greater than a certain set maximum threshold value or less than a certain set minimum threshold value, it is indicated that the width between the lane line a and the lane line b is abnormal. Of course, in the actual implementation process, the number of lane lines, the relationship between the lane lines and the selection of the first calculation point can be selected according to the actual situation, and whether the width between the lane line a and the lane line b is abnormal can also be determined by other methods, and the present application does not limit this.
[0072] The embodiment of the present application can accurately identify the smoothness of the lane line by representing the lane line to be detected by a lane line shape point set and calculating the curvature of each lane line shape point, and determining the smoothness abnormality of the lane line to be detected based on the curvature. The embodiment of the present application can accurately identify the abnormality of each lane line, such as whether the width of the lane line is normal or the lane line is missing, by representing the driving track of the detection vehicle by a driving track shape point set, determining the first lane line shape point closest to any point on each lane line for each driving track shape point, calculating the distance between each first lane line shape point and at least one other first lane line shape point closest thereto, and determining the width abnormality of the lane line based on the distance. The lane line is detected by scattered points, the evaluation of the smoothness of the lane line is more accurate, and the width, missing, intersection, and too close abnormality of the lane line can be evaluated, meeting the modern demand.
[0073] As a possible implementation manner of the present application, in the implementation manner, as shown in the figure, Figure 5 The lane line shape point and the driving track shape point are obtained, including:
[0074] In step S501, the latitude and longitude information of the lane line to be detected is obtained, the latitude and longitude information of the lane line to be detected is converted into the latitude and longitude information of the lane line shape point, and the latitude and longitude information of each point in the lane line shape point is converted into the coordinate information in the UTM coordinate.
[0075] In the embodiment of the present application, when the lane line shape point is obtained, the latitude and longitude information of the lane line shape point can be determined based on the latitude and longitude information of the lane line to be detected, and then the latitude and longitude information of the lane line shape point is converted into the coordinate information in the UTM coordinate. Optionally, when the lane line is converted into the lane line shape point, the lane line to be detected can be represented by selecting a lane line shape point every 0.5 meters. Of course, the specific selection manner can be selected according to the actual situation, and the present application does not limit this.
[0076] In step S502, the latitude and longitude information of the driving track of the detection vehicle is obtained, the latitude and longitude information of the driving track is converted into the latitude and longitude information of each point in the driving track shape point, and the latitude and longitude information of each point in the driving track shape point is converted into the coordinate information in the UTM coordinate.
[0077] In the embodiment of the present application, as described above, the conversion of the driving track of the detection vehicle can adopt the conversion manner of the lane line to be detected, which will not be described here.
[0078] The embodiment of the present application converts the lane line shape point and the driving track shape point into the UTM coordinate to obtain the coordinate information in meters, which is convenient for subsequent calculation.
[0079] As a possible implementation of the present application, in which, as shown in Figure 6 The curvature of each of the lane line shape points is calculated, and based on the curvature, a smoothness abnormality of the lane line to be detected is determined, including:
[0080] In step S601, for each first lane line shape point of a lane line to be detected, a curvature value of the first lane line shape point is calculated, and based on the curvature value, a curvature type of the first lane line shape point is determined.
[0081] In the embodiments of the present application, the curvature type refers to the direction type of the lane line at the position of the lane line shape point, such as left turn, right turn, U-turn, etc. When the curvature type is determined according to the curvature value, the direction of the lane line at the point can be determined according to the curvature value.
[0082] As a possible implementation of the present application, for the convenience of description, an example of a specific embodiment is taken, as shown in Figure 7 For the lane line group A, when calculating the curvature of the lane line shape point A1, the vertical direction in the figure is 180 degrees, and the included angle of the lane line at the lane line shape point A1 on the lane line can be obtained to be greater than 180 degrees, so it can be determined that the lane line at this position is in the left turn direction. When calculating the curvature of the lane line shape point A2, the vertical direction in the figure is 180 degrees, and the included angle of the lane line at the lane line shape point A2 on the lane line can be obtained to be less than 180 degrees, so it can be determined that the lane line at this position is in the right turn direction. It can be determined that the curvature type of the lane line shape point A1 is left turn curvature, and the curvature type of the lane line shape point A2 is right turn curvature.
[0083] In step S602, a curvature type of a second lane line shape point is determined, wherein the second lane line shape point is a preset number of lane line shape points before and after the first lane line shape point on the lane line at the first lane line shape point.
[0084] In the embodiments of the present application, there are multiple second lane line shape points, which can be a preset number of lane line shape points before and after the first lane line shape point on the lane line at the first lane line shape point, specifically, it can be a lane line shape point within 10 meters from the first lane line shape point. When determining whether the curvature of the first lane line shape point is normal, the curvature type of the second lane line shape point can be calculated to determine.
[0085] In step S603, a percentage of the second lane line shape points whose curvature type is the same as that of the first lane line shape point in the number of the second lane line shape points is determined.
[0086] In the embodiments of the present application, the curvature types of the first lane line shape point and the second lane line shape points are determined respectively, such as the curvature types of the first lane line shape point and the 20 second lane line shape points before and after the first lane line shape point, the curvature types of 41 lane line shape points, and the percentage of the number of lane line shape points with the same curvature type as the first lane line shape point in the 41 lane line shape points is determined. For example, for the convenience of description, taking a specific embodiment as an example, the curvature type of the first lane line is left turning curvature, and the curvature types of 35 lane line shape points in the 41 lane line shape points are left turning curvature, so the percentage of left turning curvature is 85.3%.
[0087] In step S604, it is judged whether the percentage is greater than a preset threshold value. When the percentage is not less than the preset threshold value, it is determined that the smoothness of the first lane line shape point is normal. When the percentage is less than the preset threshold value, it is determined that the smoothness of the first lane line shape point is abnormal.
[0088] In the embodiments of the present application, the percentage threshold value is set, such as 60%. When the percentage value calculated through the foregoing steps is greater than the threshold value, it is indicated that the smoothness of the first lane line shape point is normal, otherwise it is determined to be abnormal.
[0089] In the embodiments of the present application, by comparing the curvature of the lane line shape point with the curvature of the adjacent lane line shape point, the smoothness abnormality of the lane line shape point is determined, and whether the smoothness of the lane line is abnormal can be accurately judged.
[0090] As a possible implementation manner of the present application, in the implementation manner, as shown in FIG. 8, judging the smoothness abnormality of the lane line further includes: Figure 8
[0091] In step S801, for the first lane line shape point of each to-be-detected lane line, the heading angle of the first lane line shape point is calculated, and the heading angle threshold value of the to-be-detected lane line is obtained.
[0092] In the embodiments of the present application, the heading angle of the lane line shape point refers to the heading angle of the to-be-detected lane line based on the lane line shape point, such as the degree of northward calculated in the clockwise direction with the north direction as the reference. According to the line type and function of the lane line, the heading angle threshold value of the lane line is determined, such as the heading angle of the straight lane line is not greater than 10 degrees, the heading angle of the right turning direction lane line is greater than not greater than 90 degrees, the heading angle of the left turning direction is greater than 270 degrees and less than 360 degrees, etc.
[0093] In step S802, the heading angle of the third lane line shape point is determined, wherein the third lane line shape point is the lane line shape point adjacent to the first lane line shape point on the lane line where the first lane line shape point is located.
[0094] In the embodiment of the present application, the third lane line shape point is a lane line shape point adjacent to the first lane line shape point on the lane line where the first lane line shape point is located. The heading angle of the third lane line shape point is calculated according to the method described above.
[0095] In the embodiment of the present application, the difference between the heading angle of the first lane line shape point and the heading angle of the third lane line shape point is calculated. When the difference is greater than the heading angle threshold, it is determined that the smoothness of the first lane line shape point is abnormal.
[0096] In the embodiment of the present application, the difference between the heading angle of the first lane line shape point and the heading angle of the third lane line shape point is calculated. When the difference is greater than the heading angle threshold, it is determined that the smoothness of the first lane line shape point is abnormal. The heading angle is used to assist in determining the smoothness abnormality of the lane line, thereby increasing the accuracy of the determination of the smoothness abnormality of the lane line.
[0097] As a possible implementation manner of the present application, in this implementation manner, as shown in the figure, Figure 9 For any one of the driving trajectory shape points, a first calculation point closest to the any one driving trajectory shape point on each lane line is determined. The distance between each first calculation point and at least one other closest first calculation point is calculated. Based on the distance, the width abnormality of the lane line is determined, which includes:
[0098] In the embodiment of the present application, the first lane line segment is a lane line segment on the to-be-detected lane line with a lane line shape point closest to the first driving trajectory shape point as a starting point. The second lane line segment is a lane line segment on the to-be-detected lane line with a lane line shape point closest to the first driving trajectory shape point as a terminal point. The length of the first lane line segment and the second lane line segment is the distance between two adjacent lane line shape points.
[0099] In the embodiment of the present application, the first lane line segment is a lane line segment on the to-be-detected lane line with a lane line shape point closest to the first driving trajectory shape point as a starting point. The second lane line segment is a lane line segment on the to-be-detected lane line with a lane line shape point closest to the first driving trajectory shape point as a terminal point. The length of the first lane line segment and the second lane line segment is the distance between two adjacent lane line shape points.
[0100] In the embodiment of the present application, the first lane line segment is a lane line segment on the to-be-detected lane line with a lane line shape point closest to the first driving trajectory shape point as a starting point. The second lane line segment is a lane line segment on the to-be-detected lane line with a lane line shape point closest to the first driving trajectory shape point as a terminal point. The length of the first lane line segment and the second lane line segment is the distance between two adjacent lane line shape points.
[0101] As one possible implementation of this application, for ease of explanation, a specific embodiment is used as an example, such as... Figure 10 As shown, lane lines a and b are represented as lane line shape points, and the vehicle's trajectory c is represented as trajectory shape points. For a trajectory point c1 on trajectory c, the nearest lane line shape point ai on lane line a to trajectory point c1 is first determined, and then the lane line shape points ai adjacent to lane line shape point ai on lane line a are also determined. 1 and ai+1, and the lane segment ai Let 1-ai be the first lane segment on lane line a, and let lane segment ai-ai+1 be the second lane segment on lane line a. Similarly, determine the first lane segment bi on lane line b. 1-bi and the second lane segment bi-bi+1 on lane line b, then determine the distance from the driving trajectory point c1 to lane segment ai. The closest point E1 among 1-ai and lane segment ai-ai+1 is determined as the first calculation point, and the distance between the driving trajectory point c1 and lane segment bi is set. The nearest point E2 between 1-bi and lane line segment bi-bi+1 is determined as the first calculation point, where calculation points E1 and E2 are points on lane line a and lane line b, respectively.
[0102] Step S903: Arrange all the first calculation points on the lane lines to be detected from left to right according to their spatial position relationship with the first driving trajectory shape points, and calculate the distance between two adjacent first calculation points.
[0103] In the embodiments of this application, such as Figure 10 As shown, calculation points E1 and E2 can be sorted according to their positional relationship with the driving trajectory point c1. Specifically, they can be sorted from left to right, resulting in calculation point E1 and calculation point E2. Similarly, when there are multiple calculation points, they are calculated and sorted in the same way. In this embodiment, the distance between line segment E1 and E2 is calculated.
[0104] Step S904: Determine the threshold between the distance between any two adjacent first calculation points and the lane width. When the difference between the distance and the lane width threshold exceeds a preset range, determine that the lane width corresponding to any two adjacent first calculation points is abnormal.
[0105] In the embodiments of the present application, a lane line width threshold is set for different to-be-detected lane lines. After the distance of the line segment E1-E2 is calculated based on the foregoing steps, a comparison is made between the distance and the preset lane line width threshold. When the distance of the line segment E1-E2 is not within the threshold, it indicates that the width between the lane line a and the lane line b is abnormal. In the embodiments of the present application, the number of lane lines can be determined according to actual conditions, and the specific threshold size can also be determined according to actual conditions. The present application does not limit this.
[0106] In the embodiments of the present application, the driving track of the detected vehicle is represented by a set of driving track shape points, and for each driving track shape point, the first lane line shape point closest to the arbitrary point on each lane line is determined, the distance between each first lane line shape point and at least one other first lane line shape point closest thereto is calculated, and the width abnormality of the lane line is determined based on the distance. The abnormal conditions such as whether the width of each lane line is normal or whether the lane line is missing can be accurately identified. The lane line is detected by scattered points, which can evaluate the abnormal conditions such as lane line width, missing, intersection, and too close, and meet the modern needs.
[0107] As a possible implementation manner of the present application, in this implementation manner, for each first driving track shape point, the method further includes:
[0108] determining the number of to-be-detected lane lines within a preset distance before and after each lane line shape point;
[0109] when the number of to-be-detected lane lines at the position of the lane line shape point is less than the number of to-be-detected lane lines within a preset distance before and after the lane line shape point, it is determined that the to-be-detected lane line at the position of the lane line shape point belongs to an edge missing lane line.
[0110] In the embodiments of the present application, for some special conditions such as edge missing of a lane line, that is, missing of the outermost lane line or the innermost lane line of the to-be-detected lane line, the relationship between the number of lane lines at the position of a certain lane line shape point and the number of lane lines within a preset distance before and after the lane line shape point can be compared to determine whether the number of lane lines at the point is normal. For example, when the number of lane lines at the point is less than the number of lane lines at a position 5 meters before the point, it can be determined that the lane line at the point is in an edge missing state.
[0111] In the embodiments of the present application, the number of lane lines at adjacent positions is compared to determine whether the lane line is in an edge missing state, which can more accurately determine the abnormal conditions of the lane line.
[0112] As a possible implementation manner of the present application, in this implementation manner, the judging of the smoothness abnormality of the to-be-detected lane line based on the curvature includes:
[0113] determine the direction of the lane line to be detected based on the curvature.
[0114] In the embodiments of the present application, as shown in Figure 7 the lane line shape point A1, the angle of the lane line on which the lane line shape point A1 is located is greater than 180 degrees, it can be determined that the lane line at this position is a left turn direction, and when calculating the curvature of the lane line shape point A2, the angle of the lane line on which the lane line shape point A2 is located is less than 180 degrees, it can be determined that the lane line at this position is a right turn direction, it can be determined that the curvature type of the lane line shape point A1 is a left turn curvature, and the curvature type of the lane line shape point A2 is a right turn curvature. The direction of the lane line can be determined according to the curvature of the lane line shape point on the lane line.
[0115] The embodiments of the present application can accurately identify the smoothness of the lane line by representing the lane line to be detected by a set of lane line shape points, calculating the curvature of each lane line shape point, and determining the smoothness abnormality of the lane line to be detected based on the curvature. The embodiments of the present application can accurately identify whether the width of each lane line is normal, whether the lane line is missing, and other abnormal conditions by representing the driving trajectory of the detection vehicle by a set of driving trajectory shape points, determining the first lane line shape point closest to any point on each lane line for each driving trajectory shape point, calculating the distance between each first lane line shape point and at least one other first lane line shape point closest thereto, and determining the width abnormality of the lane line based on the distance. The lane line is detected by scattered points, the evaluation of the smoothness of the lane line is more accurate, and the width, missing, intersection, and too close abnormal conditions of the lane line can be evaluated, meeting the modern demand.
[0116] Corresponding to the foregoing application function implementation method embodiments, the present application also provides a lane line abnormality detection device, an electronic device, and corresponding embodiments.
[0117] Figure 11 FIG. 1 is a structural schematic diagram of a lane line abnormality detection device according to an embodiment of the present application.
[0118] Referring to Figure 11 , the lane line abnormality detection device according to the embodiments of the present application includes an information acquisition module 1110, a smoothness abnormality judgment module 1120, and a smoothness abnormality judgment module 1120, wherein:
[0119] The information acquisition module 1110 is configured to acquire lane line shape points and driving trajectory shape points, wherein the lane line shape points are used to represent lane lines to be detected, and the driving trajectory shape points are used to represent the driving trajectory of a detection vehicle.
[0120] The smoothness abnormality judging module 1120 is configured to calculate the curvature of each point in the lane line shape points, and judge the smoothness abnormality of the to-be-detected lane line based on the curvature.
[0121] The width abnormality judging module 1130 is configured to, for any one of the driving track shape points, determine a first calculation point on each lane line closest to the any one driving track shape point, calculate the distance between each first calculation point and at least one closest other first calculation point, and determine the width abnormality of the lane line based on the distance.
[0122] As a possible implementation form of the present application, in this implementation form, the information acquisition module 1110 is configured to, when acquiring the lane line shape points and the driving track shape points:
[0123] acquire the latitude and longitude information of the to-be-detected lane line, convert the latitude and longitude information of the to-be-detected lane line into the latitude and longitude information of the lane line shape points, and convert the latitude and longitude information of each point in the lane line shape points into the coordinate information in the UTM coordinate;
[0124] acquire the latitude and longitude information of the driving track of the detection vehicle, convert the latitude and longitude information of the driving track into the latitude and longitude information of each point in the driving track shape points, and convert the latitude and longitude information of each point in the driving track shape points into the coordinate information in the UTM coordinate.
[0125] As a possible implementation form of the present application, in this implementation form, the smoothness abnormality judging module 1120 is configured to, when calculating the curvature of each point in the lane line shape points and judging the smoothness abnormality of the to-be-detected lane line based on the curvature:
[0126] for the first lane line shape point of each to-be-detected lane line, calculate the curvature value of the first lane line shape point, and determine the curvature type of the first lane line shape point based on the curvature value;
[0127] determine the curvature type of the second lane line shape point, wherein the second lane line shape point is a preset number of lane line shape points before and after the first lane line shape point on the lane line where the first lane line shape point is located;
[0128] judge the percentage of the lane line shape points in the second lane line shape points whose curvature type is the same as that of the first lane line shape point;
[0129] determine whether the percentage is greater than a preset threshold, when the percentage is not less than the preset threshold, determine that the smoothness of the first lane line shape point is normal, and when the percentage is less than the preset threshold, determine that the smoothness of the first lane line shape point is abnormal.
[0130] As a possible implementation of the present application, in the implementation, the determining the lane line smoothness abnormality further includes:
[0131] For the first lane line shape point of each to-be-detected lane line, calculate the heading angle of the first lane line shape point, and obtain a heading angle threshold of the to-be-detected lane line;
[0132] determine the heading angle of a third lane line shape point, wherein the third lane line shape point is a lane line shape point adjacent to the first lane line shape point on the lane line where the first lane line shape point is located;
[0133] calculate the difference between the heading angle of the first lane line shape point and the heading angle of the third lane line shape point, and when the difference is greater than the heading angle threshold, determine that the smoothness of the first lane line shape point is abnormal.
[0134] As a possible implementation of the present application, in the implementation, when the width abnormality determining module 1130 determines, for any one of the driving trajectory shape points, a first calculation point on each lane line closest to the any one driving trajectory shape point, calculates the distance between each first calculation point and at least one other closest first calculation point, and determines the width abnormality of the lane line based on the distance, is used for:
[0135] For a first driving trajectory shape point in the driving trajectory shape points, determine a first lane line segment and a second lane line segment on each to-be-detected lane line, wherein the first lane line segment is a lane line segment on the to-be-detected lane line with a lane line shape point closest to the first driving trajectory shape point as a starting point, the second lane line segment is a lane line segment on the to-be-detected lane line with a lane line shape point closest to the first driving trajectory shape point as an ending point, and the length of the first lane line segment and the second lane line segment is the distance between two adjacent lane line shape points;
[0136] determine a point closest to the first driving trajectory shape point in the first lane line segment and the second lane line segment as a first calculation point;
[0137] arrange all the first calculation points on the to-be-detected lane lines from left to right according to the spatial positional relationship with the first driving trajectory shape point, and calculate the distance between two adjacent first calculation points;
[0138] The distance between any two adjacent first calculation points is compared with a threshold of lane line width, and when the difference between the distance and the threshold of lane line width exceeds a preset range, it is determined that the lane line width corresponding to the any two adjacent first calculation points is abnormal.
[0139] As a possible implementation of the present application, in this implementation, for each of the first driving trajectory shape points, the method further comprises:
[0140] determining the number of to-be-detected lane lines within a preset distance before and after each of the lane line shape points;
[0141] when the number of to-be-detected lane lines at the position of the lane line shape point is less than the number of to-be-detected lane lines within a preset distance before and after the lane line shape point, it is determined that the to-be-detected lane line at the position of the lane line shape point belongs to an edge missing lane line.
[0142] As a possible implementation of the present application, in this implementation, the judging of the smoothness abnormality of the to-be-detected lane line based on the curvature comprises:
[0143] judging the trend of the to-be-detected lane line based on the curvature.
[0144] As to the device in the above embodiments, the specific manner in which each module performs operations has been described in detail in the embodiments of the method, and will not be described in detail here.
[0145] The embodiments of the present application can accurately identify the smoothness of the lane line by representing the to-be-detected lane line in the form of a set of lane line shape points and calculating the curvature of each lane line shape point, and determining the smoothness abnormality of the to-be-detected lane line based on the curvature. By representing the driving trajectory of the detection vehicle in the form of a set of driving trajectory shape points, and for each driving trajectory shape point, determining the first lane line shape point closest to the arbitrary point on each lane line, calculating the distance between each first lane line shape point and at least one other first lane line shape point closest thereto, and determining the width abnormality of the lane line based on the distance, the abnormality of each lane line, such as whether the width of the lane line is normal or the lane line is missing, can be accurately identified. By detecting the lane line through scattered points, the evaluation of the smoothness of the lane line is more accurate, and the abnormality of the lane line width, missing, crossing, and being too close, etc. can be evaluated, meeting the modern demand.
[0146] Figure 12 FIG. 1 is a structural schematic diagram of an electronic device according to an embodiment of the present application.
[0147] Referring to FIG. 1, Figure 12 The electronic device 120 includes a memory 1210 and a processor 1220.
[0148] The processor 1220 can be a central processing unit (CPU), and can also be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gates or transistor logic, discrete hardware components, etc. The general-purpose processor can be a microprocessor or the processor can be any conventional processor.
[0149] The memory 1210 can include various types of storage units, such as a system memory, a read-only memory (ROM), and a permanent storage device. Among them, the ROM can store static data or instructions required by the processor 1220 or other modules of the computer. The permanent storage device can be a read and write storage device. The permanent storage device can be a non-volatile storage device that does not lose stored instructions and data even after the computer is powered off. In some embodiments, the permanent storage device uses a mass storage device (such as a magnetic or optical disk, flash memory) as a permanent storage device. In some other embodiments, the permanent storage device can be a removable storage device (such as a floppy disk, an optical drive). The system memory can be a read and write storage device or a volatile read and write storage device, such as a dynamic random access memory. The system memory can store some or all of the instructions and data required by the processor during runtime. In addition, the memory 1210 can include a combination of any computer readable storage media, including various types of semiconductor storage chips (such as DRAM, SRAM, SDRAM, flash memory, programmable read-only memory), magnetic disks and / or optical disks. In some embodiments, the memory 1210 can include a read and / or write removable storage device, such as a compact disc (CD), a read-only digital versatile disc (such as DVD-ROM, double-layer DVD-ROM), a read-only Blu-ray disc, an ultra-density optical disc, a flash memory card (such as an SD card, a min SD card, a Micro-SD card, etc.), a magnetic floppy disk, etc. The computer readable storage medium does not include a carrier wave and a transient electronic signal transmitted through a wireless or wired transmission.
[0150] The memory 1210 stores executable code, which, when processed by the processor 1220, can cause the processor 1220 to perform part or all of the above-mentioned methods.
[0151] Furthermore, the method according to the present application can also be implemented as a computer program or a computer program product, which comprises computer program code instructions for executing some or all of the steps of the above-mentioned method according to the present application.
[0152] Alternatively, the present application can also be implemented as a computer readable storage medium (or a non-transitory machine readable storage medium or a machine readable storage medium) having stored thereon executable codes (or computer programs or computer instruction codes) which, when executed by a processor of an electronic device (or a server, etc.), cause the processor to perform some or all of the steps of the above-mentioned method according to the present application.
[0153] The above has described the embodiments of the present application, the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and changes are obvious to those skilled in the art without departing from the scope and spirit of the described embodiments. The selection of the terms used herein is intended to best explain the principles of the embodiments, practical application, or improvement to the technology in the market, or to enable other ordinary skilled in the art to understand the embodiments disclosed herein.
Claims
1. A method for detecting lane line anomalies, characterized in that, The method includes: Obtain lane line shape points and driving trajectory shape points, wherein the lane line shape points are used to represent the lane line to be detected, and the driving trajectory shape points are used to represent the driving trajectory of the detected vehicle; Calculate the curvature of each point in the lane line shape points, and determine the smoothness anomaly of the lane line to be detected based on the curvature; For any one of the driving trajectory shape points, determine the first calculation point on each lane that is closest to the arbitrary driving trajectory shape point, calculate the distance between each first calculation point and at least one other nearest first calculation point, and determine the lane width anomaly based on the distance.
2. The lane line anomaly detection method according to claim 1, characterized in that, The acquisition of lane line shape points and driving trajectory shape points includes: Obtain the latitude and longitude information of the lane line to be detected, convert the latitude and longitude information of the lane line to be detected into the latitude and longitude information of the lane line shape points, and convert the latitude and longitude information of each point in the lane line shape points into coordinate information in UTM coordinates; The latitude and longitude information of the vehicle's driving trajectory is obtained, and the latitude and longitude information of the driving trajectory is converted into the latitude and longitude information of each point in the shape points of the driving trajectory, and the latitude and longitude information of each point in the shape points of the driving trajectory is converted into coordinate information in UTM coordinates.
3. The lane line anomaly detection method according to claim 2, characterized in that, The step of calculating the curvature of each point in the lane line shape points, and judging the smoothness anomalies of the lane line to be detected based on the curvature, includes: For each lane shape point of the lane line to be detected, calculate the curvature value of the first lane shape point, and determine the curvature type of the first lane shape point based on the curvature value; Determine the curvature type of the second lane line shape point, wherein the second lane line shape point is a preset number of lane line shape points located before and after the first lane line shape point on the lane line where the first lane line shape point is located; Determine the percentage of lane line shape points in the second lane line shape points whose curvature type is the same as that of the first lane line shape points; Determine whether the percentage is greater than a preset threshold. If the percentage is not less than the preset threshold, determine that the smoothness of the first lane line shape point is normal; if the percentage is less than the preset threshold, determine that the smoothness of the first lane line shape point is abnormal.
4. The lane line anomaly detection method according to claim 2, characterized in that, Determining the abnormal lane line smoothness also includes: For each lane shape point of the lane to be detected, calculate the heading angle of the first lane shape point and obtain the heading angle threshold of the lane to be detected; Determine the heading angle of the third lane line shape point, wherein the third lane line shape point is a lane line shape point adjacent to the first lane line shape point on the lane line where the first lane line shape point is located; Calculate the difference between the heading angle of the first lane line shape point and the heading angle of the third lane line shape point. When the difference is greater than the heading angle threshold, determine that the smoothness of the first lane line shape point is abnormal.
5. The lane line anomaly detection method according to claim 1, characterized in that, For any one of the driving trajectory shape points, determine the first calculation point on each lane that is closest to that driving trajectory shape point, calculate the distance between each first calculation point and at least one other nearest first calculation point, and determine lane width anomalies based on the distances, including: For the first driving trajectory shape point in the driving trajectory shape points, determine the first lane line segment and the second lane line segment on each lane line to be detected. The first lane line segment is the lane line segment on the lane line to be detected that starts from the lane line shape point closest to the first driving trajectory shape point, and the second lane line segment is the lane line segment on the lane line to be detected that ends from the lane line shape point closest to the first driving trajectory shape point. The lengths of the first lane line segment and the second lane line segment are the distance between two adjacent lane line shape points. The point closest to the shape of the first driving trajectory in the first lane segment and the second lane segment is determined as the first calculation point; Arrange all the first calculation points on the lane lines to be detected from left to right according to their spatial position relationship with the first driving trajectory shape points, and calculate the distance between two adjacent first calculation points; The distance between any two adjacent first calculation points and the threshold of the lane width are determined. When the difference between the distance and the lane width threshold exceeds a preset range, the lane width corresponding to any two adjacent first calculation points is determined to be abnormal.
6. The lane line anomaly detection method according to claim 5, characterized in that, For each point of the first driving trajectory shape, the method further includes: Determine the number of lane lines to be detected at preset distances before and after each lane line shape point; When the number of lane lines to be detected at the location of the lane line shape point is less than the number of lane lines to be detected at a preset distance before and after the lane line shape point, the lane line to be detected at the location of the lane line shape point is determined to be a lane line with missing edges.
7. The lane line anomaly detection method according to claim 3, characterized in that, The step of determining the smoothness anomaly of the lane line to be detected based on the curvature includes: The direction of the lane line to be detected is determined based on the curvature.
8. A lane line anomaly detection device, characterized in that, The device includes: The information acquisition module is used to acquire lane line shape points and driving trajectory shape points, wherein the lane line shape points are used to represent the lane line to be detected, and the driving trajectory shape points are used to represent the driving trajectory of the detected vehicle. The smoothness anomaly detection module is used to calculate the curvature of each point in the lane line shape points, and to determine the smoothness anomaly of the lane line to be detected based on the curvature. The width anomaly judgment module is used to determine, for any one of the driving trajectory shape points, the first calculation point closest to the arbitrary driving trajectory shape point on each lane line, calculate the distance between each first calculation point and at least one other nearest first calculation point, and determine the width anomaly of the lane line based on the distance.
9. An electronic device, characterized in that, include: processor; as well as A memory having executable code stored thereon, which, when executed by the processor, causes the processor to perform the method as described in any one of claims 1-7.
10. A computer-readable storage medium having executable code stored thereon, which, when executed by a processor of an electronic device, causes the processor to perform the method as described in any one of claims 1-7.
Citation Information
Patent Citations
Automatic road drawing method and system for mining area map and electronic equipment
CN112150632A
Lane line identification method and device, electronic equipment and computer readable storage medium
CN113255404A