Lane center line generation method and apparatus, electronic device, and storage medium

By projecting and segmenting the sampling points on the first lane line of the lane center line, the lane center line is generated, and the problem of inaccurate generation of lane center line in the prior art is solved, and the accuracy and efficiency of lane center line are improved.

WO2025060582A9PCT designated stage expired Publication Date: 2025-05-08TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2024/103043
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-09-18
Filing Date
2024-07-02
Publication Date
2025-05-08

AI Technical Summary

Technical Problem

In the prior art, when generating lane center lines, especially when the curvature of the lane lines on both sides is inconsistent, it is difficult to accurately generate lane center lines when generating lane center lines and lane lines on both sides, resulting in too large a distance between the generated lane center lines and the lane lines on both sides, and even not even between the two lane lines.

Method used

By projecting the sampling points on the first lane line of the target lane, its projection points on the second lane line are determined, and the two lane lines are divided into multiple segmented lines. Then, take points on these segmented lines at the same distance ratio to obtain the corresponding reference points, and finally generate the lane center line based on the midpoints of these reference points.

Benefits of technology

It improves the accuracy of the lane center line and reduces the error in generating the lane center line. Especially in complex road sections, the details of the lane can be better captured, and the generated lane center line is more in line with the driving trajectory of the actual road network.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024103043_08052025_PF_FP_ABST
    Figure CN2024103043_08052025_PF_FP_ABST
Patent Text Reader

Abstract

Embodiments of the present application disclose a lane center line generation method and apparatus, an electronic device, and a storage medium. For each first sampling point on a first lane line of a target lane, a first projection point, corresponding to the first sampling point, on a second lane line of the target lane is determined. The second lane line is divided into a plurality of first segment lines on the basis of the first projection points, and on the basis of the first sampling points, the first lane line is divided into second segment lines respectively corresponding to the first segment line. The lane is reasonably and finely segmented by means of the projection of the first sampling points, so that subsequently when points are selected from the first segment lines and the second segment lines corresponding to the first segment lines on the basis of the same distance proportion, a first reference point and a second reference point that are obtained are located on the same segment. The granularity of the lane is reduced by means of segmentation, so that the accuracy of the lane center line generated is improved. The present application can be widely applied to scenarios such as maps, navigation, intelligent transportation, and assisted driving.
Need to check novelty before this filing date? Find Prior Art

Description

Lane centerline generation method, device, electronic device and storage medium

[0001] This application claims priority to the Chinese patent application filed with the China Patent Office on September 18, 2023, with application number 2023112005927 and application name “Lane Centerline Generation Method, Device, Electronic Device and Storage Medium”, the entire contents of which are incorporated by reference into this application. Technical Field

[0002] The present application relates to the field of map technology, and in particular to lane centerline generation technology. Background Art

[0003] Lane centerlines are essential data in maps, and automatically generating them is one of the key technologies the industry is focusing on. In related technologies, in situations such as curved roads and inconsistent curvature of lane lines on both sides, the distance difference between the generated lane centerline and the lane lines on both sides is often too large. The generated lane centerline may even not be between the two lane lines. In other words, the generated lane centerline does not conform to the driving trajectory of vehicles on the actual road network, and the lane centerline accuracy is low.

[0004] Summary of the Invention

[0005] The following is an overview of the subject matter described in detail in this application. This overview is not intended to limit the scope of protection of the claims.

[0006] Embodiments of the present application provide a lane centerline generation method, device, electronic device, and storage medium, which can improve the accuracy of the generated lane centerline.

[0007] In one aspect, an embodiment of the present application provides a lane centerline generation method, executed by an electronic device, comprising:

[0008] For each first sampling point on a first lane line of a target lane, determining a projection point of each first sampling point on a second lane line of the target lane as a first projection point corresponding to each first sampling point, wherein the first lane line and the second lane line are lane lines on both sides of the target lane, respectively;

[0009] Divide the second lane line into a plurality of first segmented lines according to each of the first projection points, and divide the first lane line into a plurality of second segmented lines according to each of the first sampling points, wherein the plurality of first segmented lines correspond one to one to the plurality of second segmented lines;

[0010] Selecting points on the first segmented line and the second segmented line that have a corresponding relationship according to the same distance ratio to obtain a first reference point on the first segmented line and a second reference point on the second segmented line, wherein the first reference point and the second reference point have a one-to-one correspondence;

[0011] A lane centerline of the target lane is generated according to midpoints between each group of corresponding first reference points and second reference points.

[0012] On the other hand, an embodiment of the present application further provides a lane centerline generating device, comprising:

[0013] a projection module configured to determine, for each first sampling point on a first lane line of a target lane, a projection point of each first sampling point on a second lane line of the target lane as a first projection point corresponding to each first sampling point, wherein the first lane line and the second lane line are lane lines on both sides of the target lane, respectively;

[0014] a dividing module, configured to divide the second lane line into a plurality of first segmented lines based on each of the first projection points, and to divide the first lane line into a plurality of second segmented lines based on each of the first sampling points, wherein the plurality of first segmented lines correspond one to one with the plurality of second segmented lines;

[0015] a reference point determination module, configured to select points on the first segmented line and the second segmented line that have a corresponding relationship according to the same distance ratio, to obtain a first reference point on the first segmented line and a second reference point on the second segmented line, wherein the first reference point and the second reference point have a one-to-one correspondence;

[0016] A generation module is used to generate a lane centerline of the target lane according to the midpoints between each group of corresponding first reference points and second reference points.

[0017] On the other hand, an embodiment of the present application further provides an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor implements the above-mentioned lane centerline generation method when executing the computer program.

[0018] On the other hand, an embodiment of the present application further provides a computer-readable storage medium, which stores a computer program, and the computer program is executed by a processor to implement the above-mentioned lane centerline generation method.

[0019] In another aspect, embodiments of the present application further provide a computer program product, comprising a computer program stored in a computer-readable storage medium. A processor of a computer device reads the computer program from the computer-readable storage medium and executes the computer program, causing the computer device to implement the lane centerline generation method described above.

[0020] Embodiments of the present application have at least the following advantageous effects: for each first sampling point on the first lane line of the target lane, a projection point of each first sampling point on the second lane line of the target lane is determined as the first projection point corresponding to each first sampling point. Then, based on each first projection point, the second lane line is divided into a plurality of first segmentation lines, and based on each first sampling point, the first lane line is divided into a plurality of second segmentation lines. The plurality of second segmentation lines correspond one-to-one with the plurality of first segmentation lines. In this way, the lane is segmented rationally and precisely based on the projection of the first sampling points. When points are subsequently selected on the corresponding first segmentation lines and second segmentation lines at the same distance ratio, the corresponding first reference points and second reference points are located in the same segment. Even in situations such as curves or with inconsistent curvatures of the lane lines on both sides, the lane centerline generated based on the midpoint between the first reference point and the second reference point can have a smaller deviation because the lane granularity is reduced through segmentation. This effectively reduces the error in the generated lane centerline and improves the accuracy of the generated lane centerline.

[0021] In addition, the lane centerline is generated by segmenting and taking points in equal proportion, which reduces the amount of data processing and helps improve the efficiency of the generated lane centerline.

[0022] Other features and advantages of the present application will be set forth in the following description, and in part will be apparent from the description, or may be understood by practicing the present application. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] The accompanying drawings are used to provide a further understanding of the technical solution of the present application and constitute a part of the specification. Together with the embodiments of the present application, they are used to explain the technical solution of the present application and do not constitute a limitation on the technical solution of the present application.

[0024] FIG1 is a schematic diagram of the center line of a lane in a mountain road scenario in related art.

[0025] FIG2 is a schematic diagram of a lane centerline in a U-turn scenario in the related art.

[0026] FIG3 is a schematic diagram of an optional implementation environment in an embodiment of the present application.

[0027] FIG4 is an optional flowchart of a lane centerline generation method in an embodiment of the present application.

[0028] FIG5 a is a schematic diagram of a lane line of a target lane in an embodiment of the present application.

[0029] FIG5 b is a schematic diagram of another lane line of the target lane in an embodiment of the present application.

[0030] FIG6 is a schematic diagram of a first sampling point on a first lane line in an embodiment of the present application.

[0031] FIG7 is a schematic diagram of the first projection point on the second lane line in an embodiment of the present application.

[0032] FIG8 is a schematic diagram of a first segment line and a second segment line in an embodiment of the present application.

[0033] FIG9 is another schematic diagram of the first segment line and the second segment line in an embodiment of the present application.

[0034] FIG10 is a schematic diagram of the process of removing the second projection point in an embodiment of the present application.

[0035] FIG11 is a schematic diagram of the process of removing the first projection point in an embodiment of the present application.

[0036] FIG12 is a schematic diagram of a pair of reference points with a constant distance interval when taking points in an embodiment of the present application.

[0037] FIG13 is a schematic diagram of a reference point pair with varying distance intervals when taking points in an embodiment of the present application.

[0038] FIG14 is a schematic diagram of a lane centerline obtained in an embodiment of the present application.

[0039] FIG15 is a schematic diagram comparing the lane center line in an embodiment of the present application and the lane center line generated by related technologies.

[0040] FIG16 is another schematic diagram comparing the lane centerline in an embodiment of the present application with the lane centerline generated by related technologies.

[0041] FIG17 is a schematic diagram showing a case where the same first projection line and the second lane line have multiple first intersection points in an embodiment of the present application.

[0042] FIG18 is a schematic diagram of a projection line determination model in an embodiment of the present application.

[0043] FIG19 is a schematic diagram of a distance matrix in an embodiment of the present application.

[0044] FIG20 is a schematic diagram of intersecting first projection lines in an embodiment of the present application.

[0045] FIG21 is another schematic diagram of intersecting first projection lines in an embodiment of the present application.

[0046] Figure 22 is an optional overall flow chart of the lane centerline generation method in an embodiment of the present application.

[0047] Figure 23 is an optional structural diagram of the lane centerline generating device in an embodiment of the present application.

[0048] Figure 24 is a partial structural block diagram of the terminal in an embodiment of the present application.

[0049] Figure 25 is a partial structural block diagram of the server in an embodiment of the present application. DETAILED DESCRIPTION

[0050] In order to make the purpose, technical solutions and advantages of this application more clear, the following further describes this application in detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain this application and are not intended to limit this application.

[0051] It should be noted that, in each specific embodiment of the present application, when it comes to the need to perform relevant processing based on data related to the characteristics of the target object, such as target object attribute information or attribute information set, the permission or consent of the target object will be obtained first, and the collection, use and processing of these data will comply with relevant laws, regulations and standards. Among them, the target object can be a user. In addition, when the embodiment of the present application needs to obtain target object attribute information, the target object's separate permission or separate consent will be obtained through a pop-up window or by jumping to a confirmation page. After clearly obtaining the target object's separate permission or separate consent, the necessary target object-related data for the normal operation of the embodiment of the present application will be obtained.

[0052] To facilitate understanding of the technical solutions in the embodiments of the present application, some key terms used in the embodiments of the present application are explained here:

[0053] Lane: A term used to denote a road or street area for vehicles. It is a specific width of vehicle traffic area, usually separated by white or yellow markings. The number of lanes can be set based on road width and traffic flow.

[0054] Lane centerline: A lane marking line, typically located in the center of a lane, is approximately equidistant from the lane markings on its left and right sides. It serves as a guide for vehicles traveling in the middle of the lane.

[0055] Road segments: In transportation networks, road segments are fundamental elements that represent sections of the road system. Each road segment has a unique identifier, or ID, that distinguishes it from other road segments. A road segment typically consists of attributes such as its start and end locations, length, road type (e.g., freeway, city street), speed limit, and direction of travel. Complete roads can be formed by connecting multiple road segments together.

[0056] Lane centerlines are essential data in maps, and automatically generating them is a key technology that the industry is focusing on. Related technologies typically generate lane centerlines by selecting points at equal distances. For example, a point is selected 2 meters from the right lane line. The trajectory distance between the selected point and the starting position of the right lane line is then calculated. The percentage of the trajectory distance to the total length of the right lane line is then calculated. Finally, a point is selected based on the left lane line using the same percentage. The lane centerline is drawn based on the midpoint between the points selected on the left and right lane lines. This method can quickly generate a lane centerline that meets the requirements on nearly parallel straight roads. However, on curved roads or where the curvature of the lane lines on both sides is inconsistent, the distance difference between the generated lane centerline and the lane lines on both sides is often too large, and the generated lane centerline may not even be between the two lane lines. In other words, the generated lane centerline does not conform to the actual vehicle trajectory on the road network, resulting in low lane centerline accuracy. In terms of time complexity and generation performance, the algorithms of related technologies are less effective in automatically drawing lane centerlines in maps.

[0057] Referring to Figure 1, Figure 1 is a schematic diagram of the lane centerline in a mountain road scenario generated in the related art. The solid lines in Figure 1 represent the lane lines on both sides, and the dotted lines represent the lane centerline. Referring to the partial enlarged view in Figure 1, it can be seen that at the bend in the mountain road, the lane centerline is not in the middle of the lane, and even crosses the lane line. Referring to Figure 2, Figure 2 is a schematic diagram of the lane centerline in a U-turn scenario generated in the related art. The solid lines in Figure 2 represent the lane lines on both sides, and the dotted lines represent the lane centerline. It can be seen that in this scenario, the trajectory curvature of the lane lines on both sides of the road section is quite different, and the lane centerline drawn by taking points at equal distances has a large position deviation. In addition, in the related art, the centerline generated in cases such as bends and inconsistent curvature of the lane lines on both sides is not necessarily smooth and beautiful, and requires manual calibration in the later stage, which makes it difficult to apply to application scenarios where a large number of lane centerlines are generated.

[0058] Based on this, the embodiments of the present application provide a lane centerline generation method, device, electronic device and storage medium, which can improve the accuracy of the generated lane centerline, ensure that the difference between the lane centerline and the lane lines on both sides is within a certain tolerance range, and meet the requirements of a smooth and beautiful lane centerline.

[0059] 3 , which is a schematic diagram of an optional implementation environment in an embodiment of the present application, the implementation environment includes a terminal 301 and a data processing server 302 , wherein the terminal 301 and the data processing server 302 are connected via a communication network.

[0060] Exemplarily, taking terminal 301 as an on-board terminal, the data processing server 302 obtains lane data of the target lane. Based on the lane data, for each first sampling point in the first lane line of the target lane, the data processing server 302 determines the projection point of each first sampling point on the second lane line, thereby obtaining a first projection point corresponding to each first sampling point. Then, based on each first projection point, the second lane line is divided into a plurality of first segment lines, and based on each first sampling point, the first lane line is divided into a plurality of second segment lines, wherein the plurality of second segment lines correspond one-to-one to the plurality of first segment lines. Furthermore, points are taken on the corresponding first segment lines and second segment lines according to the same distance ratio, thereby obtaining a first reference point on the first segment line and a second reference point on the second segment line, wherein the first reference point and the second reference point correspond one-to-one. Finally, based on the midpoint between each group of corresponding first reference points and second reference points, the lane center line of the target lane is generated. Then, map data is constructed based on the lane center line, and the map data is sent to the terminal 301. By projecting based on the first sampling point, the lane is segmented reasonably and finely, so that when points are subsequently taken on the corresponding first segmentation line and second segmentation line at the same distance ratio, the first reference point and the second reference point obtained are located in the same segment of the target road. Therefore, even in cases of curves or inconsistent curvature of the lane line trajectories on both sides, the lane granularity is reduced by segmentation, and the deviation of the lane centerline generated based on the midpoint between the corresponding first reference point and the second reference point can be made smaller, thereby effectively reducing the error of the generated lane centerline and improving the accuracy of the generated lane centerline.

[0061] Accordingly, terminal 301 can implement functions such as vehicle navigation, lane departure warning, and assisted driving based on map data, ensuring the vehicle stays in the correct lane and maintains an appropriate distance from other vehicles to prevent lane departure or collision. Furthermore, using accurate lane centerlines to detect vehicle position and direction and perform automatic control can also improve the performance and reliability of assisted driving.

[0062] The terminal 301 may be a smartphone, tablet computer, laptop computer, desktop computer, smart speaker, smart watch, vehicle-mounted terminal, etc., but is not limited thereto. The terminal 301 and the data processing server 302 may be connected directly or indirectly via wired or wireless communication, which is not limited in this embodiment of the present application.

[0063] Data processing server 302 can be a standalone physical server, a server cluster or distributed system consisting of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence platforms. Furthermore, data processing server 302 can also be a node server in a blockchain network.

[0064] The method in the embodiments of the present application can be applied to various scenarios, including but not limited to maps, navigation, smart transportation, assisted driving and other scenarios.

[0065] The principles of the lane centerline generation method in the embodiment of the present application are described in detail below.

[0066] Referring to Figure 4, Figure 4 is an optional flowchart of a lane centerline generation method according to an embodiment of the present application. The lane centerline generation method can be executed by an electronic device, such as a server, a terminal, or a server and a terminal. In the present embodiment, the method is described using the server as an example. The lane centerline generation method includes but is not limited to steps 401 to 404.

[0067] Step 401: For each first sampling point on the first lane line of the target lane, determine the projection point of each first sampling point on the second lane line of the target lane as the first projection point corresponding to each first sampling point.

[0068] In one possible implementation, since lanes are generally long, they can be segmented into lane segments. The lane centerline of each lane segment is drawn one by one, and then the lane centerlines of each lane segment are connected to obtain the overall lane centerline. The lane corresponding to the lane segment is referred to as the target lane. In practice, the target lane can also be a complete lane, and this embodiment of the application does not impose any limitation on this.

[0069] In one possible implementation, the server can obtain lane data corresponding to the target lane from road data. The road data includes road geometry information such as the shape, length, and width of the road. The lane data includes the positions of lane lines on both sides of the target lane calculated based on the road geometry information. Lane line-related information of the target lane can be obtained based on the lane data. The road data here can be obtained through ground measurement, remote sensing, connection to a geographic information system, or receiving vehicle sensors. Ground measurement refers to the use of measuring tools to conduct on-site measurements of the road to obtain road geometry and other relevant data. Remote sensing refers to the use of remote sensing technologies such as photography, satellite imagery, or drones to obtain image data of the road, and then extract road information through image processing and computer vision algorithms. It can also be connected to existing geographic information system data to obtain road data such as topographic maps, urban planning data, and satellite images. Alternatively, road data may be uploaded by a vehicle-mounted terminal. Accordingly, the road data may be collected by a vehicle-mounted acquisition device and then uploaded by the vehicle-mounted terminal. The acquisition device may be a camera, a lidar, a millimeter-wave radar, or other radar device. Alternatively, the road data may be collected by a remote sensor installed on a remote sensing platform such as a remote sensing vehicle, ship, or aircraft, and then transmitted to the vehicle-mounted terminal for upload. Alternatively, the road data may be acquired by an intelligent vehicle-road cooperative system and then transmitted to the vehicle-mounted terminal for upload. The disclosed embodiments do not limit the method for acquiring road data.

[0070] In one possible implementation, the first lane line and the second lane line are lane lines on both sides of the target lane, respectively. Referring to Figure 5a, Figure 5a is a schematic diagram of the lane lines of the target lane in an embodiment of the present application. Along the driving direction, each target lane includes lane lines on the left and right sides. For the convenience of description, the two lane lines are respectively recorded as the first lane line and the second lane line. For example, the lane line on the left can be referred to as the first lane line, and the lane line on the right can be referred to as the second lane line. Referring to Figure 5a, target lane 1 and target lane 2 are shown, wherein target lane 1 and target lane 2 are adjacent lanes in opposite directions, and target lane 1 and target lane 2 share a lane line C2. Therefore, the first lane line of target lane 1 is C1, and the second lane line is C2. The first lane line of target lane 2 is C3, and the second lane line of target lane 2 is C2. Referring to Figure 5b, Figure 5b is another schematic diagram of the lane lines of the target lane in an embodiment of the present application. 5b , target lane 1 and target lane 2 are shown, where target lane 1 and target lane 2 are adjacent lanes in opposite directions and are spaced a certain distance apart. Therefore, the first lane line of target lane 1 is C1 and the second lane line is C2, and the first lane line of target lane 2 is C3 and the second lane line is C4.

[0071] In one possible implementation, the sampling points can be located at locations on the lane line where the curvature changes, and the starting and ending points of the lane line can also serve as sampling points for the lane line. Therefore, the first sampling points include the starting point, end point, and point where the curvature changes on the first lane line. Referring to Figure 6, Figure 6 is a schematic diagram of the first sampling points on the first lane line in an embodiment of the present application. Assuming that there are three locations where the curvature changes on the first lane line in Figure 6, the first lane line has five first sampling points, including the starting and ending points, namely first sampling point 1, second sampling point 2, second sampling point 3, second sampling point 4, and second sampling point 5.

[0072] In one possible implementation, for each first sampling point in a first lane line of a target lane, determining the projection point of each first sampling point on a second lane line of the target lane to obtain the corresponding first projection point specifically includes: generating a first tangent line for the first lane line based on each first sampling point in the first lane line of the target lane; then generating a first projection line perpendicular to the first tangent line based on the first sampling point; and determining the first projection point corresponding to the first shape point based on a first intersection of the first projection line and the second lane line of the target lane. On a road or map, the process of extending or mapping a point along a certain direction onto another line is called projection. In this embodiment, the first sampling point on the first lane line is projected onto the second lane line. Specifically, determining the projection point of the first sampling point on the first lane line on the second lane line refers to extending the first sampling point on the first lane line in a direction perpendicular to the first lane line on which it is located until it intersects with the second lane line of the target lane, thereby obtaining the corresponding projection point. Through projection, corresponding positions on the first lane line and the second lane line of the target lane can be obtained.

[0073] In a possible implementation, refer to FIG7 , which is a schematic diagram of determining the first projection point on the second lane line in an embodiment of the present application. In FIG7 , the target lane includes the first lane line D1 and the second lane line D2. Assume that the first lane line D1 includes N first sampling points, and the first sampling points are represented by {X1,…,X N}, where the first sampling point X1 and the first sampling point X N Indicates the starting point and end point of the first lane line D1, and the other first sampling points are the points where the curvature of the first lane line D1 changes. A first tangent line of the first lane line is generated at each first sampling point, and then a first projection line perpendicular to the corresponding first tangent line is generated at the first sampling point. The first projection line is extended until it intersects with the second lane line. This intersection is recorded as the first intersection point. In Figure 7, the first intersection point corresponds to the first sampling point, and the first intersection point is represented by {X1',…,X N Finally, a first projection point is determined based on the first intersection point and projected onto the second lane line of the target lane.

[0074] In this way, by determining the first projection points corresponding to each first sampling point on the first lane line on the second lane line in the above manner, the accuracy of the determined first projection points can be guaranteed. Accordingly, the subsequent division of the first lane line based on each first sampling point and the division of the second lane line based on each first projection point can ensure that the segmented lines obtained by the division correspond accurately, which is conducive to improving the accuracy of the finally determined lane centerline.

[0075] The above process starts from each first sampling point in the first lane line of the target lane and projects it onto the second lane line of the target lane to obtain the first projection point. Then, the first sampling point and the first projection point are used to segment the corresponding lane line.

[0076] Step 402: Divide the second lane line into a plurality of first segmentation lines according to each first projection point, and divide the first lane line into a plurality of second segmentation lines according to each first sampling point, with the plurality of first segmentation lines corresponding to the plurality of second segmentation lines in a one-to-one manner.

[0077] In one possible implementation, the first projection lines corresponding to the first projection points have a projection order, which is called a projection line order, meaning the first projection lines are arranged in an orderly manner. The projection line order can be obtained by ordering the distances between the corresponding first sampling points and the starting point of the first lane line. Alternatively, during projection, the first sampling points are projected in order of distance from the starting point of the first lane line, from near to far. In this case, the projection line order of the first projection lines can be obtained by ordering the first projection lines based on the generation time. Based on the projection line order of the first projection lines corresponding to each first sampling point, the order of the first projection points corresponding to the first shape point is obtained. The second lane line is then segmented in sequence along the direction of travel of the target road in the order of the first projection points to obtain a plurality of first segmentation lines. Furthermore, the first lane line is segmented in sequence along the direction of travel of the target road in the order of the first sampling points to obtain a second segmentation line corresponding to each first segmentation line. In this manner, the two lane lines of the target lane are divided and the segmentation lines are aligned.

[0078] In one possible implementation, refer to FIG8 , which is a schematic diagram of a first segmented line and a second segmented line in an embodiment of the present application. In FIG8 , the first lane line includes two first sampling points, PL0 and PL2. First sampling point PL0 is the starting point of the first lane line, and first sampling point PL2 is the point where the curvature changes on the first lane line. Projections are performed sequentially based on the distance between the first sampling point and the starting point to generate a first projection line for each first sampling point. Based on the first intersection of the first projection line and the second lane line, two first projection points are obtained on the second lane line. In order, the first projection points are PR1 and PR3. Assuming that the starting point of the second lane line is PR0 according to the driving direction of the target road, the second lane line is cut according to the first projection points to obtain three first segmented lines, represented in sequence as: line segment Lr1 between PR0 and PR1, line segment Lr2' between PR1 and PR3, and line segment Lr4 consisting of the remaining portion of the second lane line after PR3. Correspondingly, the first lane line is segmented sequentially along the travel direction of the target road according to the order of the first sampling points, resulting in three corresponding second segmentation lines, represented as follows: the first sampling point PL0, the line segment L12' between PL0 and PL2, and the line segment L13 consisting of the remaining portion of the first lane line after PL2. It is understood that a second segmentation line may be formed by a single point. Furthermore, the corresponding first and second segmentation lines segment the target lane to obtain corresponding lane segments. Lane segmentation sampling includes two types: approximate triangular sectors and approximate quadrilaterals.

[0079] The corresponding relationship between the first segment line and the second segment line in FIG8 is shown in Table 1 below.

[0080] Table 1 Correspondence between the first segment line and the second segment line in Figure 8

[0081] In one possible implementation, to more reasonably subdivide the two lane boundary lines of the target lane, the first lane line is reversely segmented based on the curvature change of the second lane line. Therefore, the process of dividing the second lane line into multiple first segment lines based on each first projection point, and dividing the first lane line into multiple second segment lines based on each first sampling point, specifically includes: for a second sampling point between two adjacent first projection points on the second lane line, determining the projection point of the second sampling point on the first lane line, and obtaining the second projection point corresponding to the second sampling point; then, dividing the second lane line into multiple first segment lines along the driving direction of the target lane based on the first projection point and the second sampling point; finally, dividing the first lane line into multiple second segment lines along the driving direction based on the first sampling point and the second projection point.

[0082] In one possible implementation, a second sampling point exists between adjacent first projection points on the second lane line. Similarly, the second sampling point includes the starting point, end point, or point where the curvature of the second lane line changes. A second sampling point is selected between every two adjacent first projection points in the order of the first projection points. A second tangent line for the second lane line is generated based on the selected second sampling point. A second projection line perpendicular to the second tangent line is then generated at the position of the second sampling point. The second projection line is extended until it intersects the first lane line. This intersection is recorded as the second intersection point. The second projection point corresponding to the second sampling point on the first lane line is determined based on the second intersection point. In this case, the second lane line includes the first projection point and the second sampling point, and the first projection point and the second sampling point are arranged in an orderly manner. Therefore, the second lane line is sequentially divided into multiple first segment lines along the direction of travel of the target lane and the order of the first projection point and the second sampling point. In this case, the first lane line includes the second projection point and the first sampling point, and the second projection point and the first sampling point are arranged in an orderly manner. Therefore, the first lane line is sequentially divided into multiple second segment lines along the direction of travel and the order of the second projection point and the first sampling point.

[0083] In a possible implementation, refer to Figure 9 , which is another schematic diagram of the first segment line and the second segment line in the embodiment of the present application. Figure 9 is a subdivision based on Figure 8 . As shown in Figure 9, the first lane line includes two first sampling points, namely PL0 and PL2. Projection is performed in sequence according to the distance between the first sampling point and the starting point to generate the first projection line of each first sampling point. According to the first intersection of the first projection line and the second lane line, two first projection points on the second lane line are obtained, respectively. In order, the first projection points are PR1 and PR3. There is a second sampling point PR2 between the first projection points PR1 and PR3. The second sampling point PR2 is the point where the curvature changes on the second lane line. At the same time, assuming that the starting point of the second lane line is PR0 according to the driving direction, the second lane line is divided into multiple first segment lines along the driving direction according to the starting point PR0, the first projection point PR1, the second sampling point PR2 and the first projection point PR3, which are represented as: line segment Lr1 between PR0 and PR1, line segment Lr2 between PR1 and PR2, line segment Lr3 between PR1 and PR2, and line segment Lr4 consisting of the remaining part of the second lane line after PR3. At this time, the first lane line is projected based on the second sampling point PR2 to obtain the second projection point PL1. At this time, the first lane line is sequentially divided into multiple second segment lines along the driving direction according to the first sampling point PL0, the second projection point PL1, and the first sampling point PL2. The resulting four second segment lines correspond to the first segment lines and are represented in sequence as: the first sampling point PL0, the line segment Ll1 between PL0 and PL1, the line segment Ll2 between PL1 and PL2, and the line segment Ll3 consisting of the remaining portion of the first lane line after PL2.

[0084] The corresponding relationship between the first segment line and the second segment line in FIG9 is shown in Table 2 below.

[0085] Table 2 Correspondence between the first segment line and the second segment line in Figure 9

[0086] The above process first performs forward segmentation on the second lane line using the first projection point corresponding to the first sampling point of the first lane line and the second sampling point on the second lane line. Then, the first lane line is reversely segmented using the second projection point corresponding to the second sampling point of the second lane line and the first sampling point on the first lane line. Through the forward and reverse segmentation processes, a better correspondence between the first lane line and the second lane line can be established, thereby achieving a more reasonable division of the target lane.

[0087] In one possible implementation, in the process of dividing the second segmented line, in order to improve the reliability and rationality of the division of the second segmented line, it is necessary to screen the second projection points. Therefore, the process of dividing the first lane line into multiple second segmented lines along the driving direction according to the first sampling point and the second projection point specifically includes: for each second projection point, obtaining the first position coordinates of the second projection point and the second position coordinates of two target sampling points on the first lane line, wherein the two target sampling points are the first sampling points corresponding to two first projection points adjacent to the second sampling point corresponding to the second projection point; determining the positional relationship between the second projection point and the two target sampling points according to the first position coordinates and the second position coordinates; when the positional relationship indicates that the second projection point is outside the two target sampling points, eliminating the second projection point; and then, dividing the first lane line into multiple second segmented lines along the driving direction according to the first sampling point and the remaining second projection points.

[0088] In one possible implementation, after obtaining the second projection point, it is necessary to perform validity screening based on the position of the second projection point on the first lane line. Referring to Figure 10, Figure 10 is a schematic diagram of the elimination process of the second projection point in an embodiment of the present application. The two adjacent first sampling points on the first lane line are A1 and A2, and their corresponding first projection points on the second lane line are A1' and A2', respectively. There are two second sampling points B1' and B2' between the first projection points A1' and A2'. The second projection point corresponding to the second sampling point B1' on the first lane line is B1, and the second projection point corresponding to the second sampling point B2' on the first lane line is B2. At this time, the two target sampling points associated with the second projection point B1 are A1 and A2, and the two target sampling points associated with the second projection point B2 are also A1 and A2. During the screening process, the first position coordinates of each of the second projection points B1 and B2, as well as the second position coordinates of each of the corresponding two target sampling points A1 and A2, are first obtained. Then, based on the first and second position coordinates, the positional relationship between the second projection point and the two target sampling points is determined. If the positional relationship indicates that the second projection point is outside the two adjacent first sampling points, the second projection point is eliminated. As can be seen from Figure 10, second projection point B2 is outside target sampling points A1 and A2, while second projection point B1 is inside target sampling points A1 and A2. Therefore, second projection point B2 needs to be eliminated. At this point, based on the first sampling points A1 and A2 and the remaining second projection point B1, the first lane line can be divided into second segmentation lines corresponding to each first segmentation line along the driving direction.

[0089] It is understandable that if a second projection point is removed, then when dividing the second lane line into the first segmented line, the second sampling point corresponding to the removed second projection point also needs to be removed, so that the first segmented line and the second segmented line correspond to each other.

[0090] In one possible implementation, when determining the first projection point corresponding to the first sampling point on the first lane line on the second lane line, the validity screening of the first projection point can be performed based on the position in a manner similar to the above. Referring to Figure 11, Figure 11 is a schematic diagram of the process of eliminating the first projection point in an embodiment of the present application. For example, the first projection points corresponding to the first sampling points A3, A4, A5 and A6 are B3, B4, B5, and B6, respectively. The position information of each first projection point is obtained, and based on the adjacent order of the first sampling points, two target projection points of the first projection point are selected. The target projection points are the first projection points corresponding to the two adjacent first sampling points of the first sampling point corresponding to the first projection point. For example, the target projection points of the first projection point B5 are B4 and B6 respectively. As can be seen from Figure 11, the first projection point B5 is located outside the target projection points B4 and B6, so the first projection point B5 needs to be eliminated. After eliminating the first projection point B5, the validity screening is performed again. Based on the remaining first projection points, the second lane line is divided into multiple first segment lines along the driving direction.

[0091] In this way, through the above method, the second projection point on the first lane line and the first projection point on the second lane line are screened for effectiveness, and then multiple second segmentation lines are divided according to the first sampling point on the first lane line and the retained second projection point, and multiple first segmentation lines are divided according to the second sampling point on the second lane line and the retained first projection point, which can ensure the reliability and rationality of the division of the second segmentation lines and the first segmentation lines.

[0092] The above process segments the first lane line and the second lane line of the target lane to obtain the corresponding first segmentation line and second segmentation line. Next, the method of obtaining the reference point of the lane centerline using the segmentation line is described.

[0093] Step 403: According to the same distance ratio, points are selected on the first segment line and the second segment line having a corresponding relationship to obtain a first reference point on the first segment line and a second reference point on the second segment line.

[0094] It can be seen that the number of the first reference points and the second reference points are the same, and the first reference points correspond to the second reference points one to one.

[0095] In one possible implementation, the distance ratio is used to represent the ratio of the distance between a reference point and one end of a segment line to the length of the segment line. For example, the distance between the first reference point and the starting point of the first segment line is defined as the first starting point distance, the distance between the first reference point and the end point of the first segment line is defined as the first end point distance, the distance between the second reference point and the starting point of the second segment line is defined as the second starting point distance, and the distance between the second reference point and the end point of the second segment line is defined as the second end point distance. Accordingly, for the first segment line, the distance ratio here can be the first starting point distance / first segment line length, or the first end point distance / first segment line length, and for the second segment line, the distance ratio here can be the second starting point distance / second segment line length, or the second end point distance / second segment line length.

[0096] In one possible implementation, points are taken according to the same distance ratio, that is, the distance ratio of the first reference point is the same as the distance ratio of the corresponding second reference point. Specifically, the process of taking points on the first segmentation line and the second segmentation line with a corresponding relationship according to the same distance ratio specifically includes: determining the target segmentation line in the first segmentation line and the second segmentation line, and taking points on the target segmentation line according to a preset distance interval; then, determining the distance ratio according to the distance interval, and taking points on another segmentation line in the first segmentation line and the second segmentation line except the target segment according to the distance ratio.

[0097] In a possible implementation, if the target segmentation line is the first segmentation line, the second segmentation line corresponds to the target segmentation line; if the target segmentation line is the second segmentation line, the first segmentation line corresponds to the target segmentation line. Assuming that the target segmentation line is the first segmentation line, the above-mentioned point selection process includes: first, starting from the starting point on the first segmentation line according to a preset distance interval, the preset distance interval here can be set according to the actual scenario, for example, the distance interval is 1m. After obtaining the distance interval, the distance ratio can be calculated. For example, if the total length of the first segmentation line is 10m and the total length of the second segmentation line is 5m, and the preset distance interval is 1m, the distance ratio of the first point selection can be 1 / 10=0.1. On the first segmentation line, the first first reference point is taken at a distance of 10m*0.1=1m from the starting point. Then, on the second segmentation line, the point position is calculated according to 5m*0.1=0.5m. At this time, the first second reference point is taken at a distance of 0.5m from the starting point of the second segmentation line. If the preset distance interval remains unchanged, when taking the point for the second time, the distance between the second first reference point and the starting point of the first segment line is 2m. At this time, the distance ratio is (1+1) / 10=0.2, and the second second reference point needs to be taken at a position 5m*0.2=1m away from the starting point of the second segment line. Similarly, the first reference point is evenly taken on the first segment line, and the corresponding second reference point is taken on the second segment line. The first reference point and the corresponding second reference point form a reference point pair. Referring to Figure 12, Figure 12 is a schematic diagram of a reference point pair with a constant distance interval when taking points in an embodiment of the present application. It can be seen that in Figure 12, the first reference points are evenly distributed on the first segment line, and similarly, the second reference points are evenly distributed on the second segment line.

[0098] In one possible implementation method, if the preset distance interval remains unchanged, the number of points in the target segmented line can be calculated based on the distance interval, and the first segmented line and the second segmented line can be divided evenly according to the number of points. The distance ratio of each point is the same, and the point taking efficiency is improved in this way.

[0099] In one possible implementation, the preset distance interval can be dynamically and adaptively adjusted each time a point is taken, that is, the distance interval may change each time a point is taken. In this case, each time a point is taken, it is necessary to calculate the distance ratio based on the current distance interval to ensure that the reference point selected on the target segmented line changes with the distance interval, and at the same time changes synchronously with the reference point on the first segmented line or the second segmented line corresponding to the target segmented line. Setting a dynamic distance interval and calculating the distance ratio each time a point is taken has the following advantages: First, the distance ratio is calculated based on the current distance interval, and an adaptive sampling strategy can be implemented. By adaptively sampling according to actual conditions, the problem of too many or too few sampling points is avoided. For example, in the case of a segmented line with little curvature change or a straight segment, a larger distance interval can be used to reduce the number of sampling points and improve the efficiency of point selection. In key areas such as curves with large curvature changes, a smaller distance interval can be used to increase the density of sampling points, thereby selecting more accurate reference point pairs and further improving the accuracy of the lane centerline. In addition, recalculating the distance ratio each time a point is taken can ensure that the reference point on the target segment line and the reference point on the corresponding first segment line or second segment line keep changing synchronously, which helps to reduce the accumulation of deviations and errors, while maintaining the spatial relationship between the two segment lines, ensuring the continuity and consistency of the division, and improving the accuracy and stability of the reference point selection. Referring to Figure 13, Figure 13 is a schematic diagram of the reference point pair with the changing distance interval when taking points in an embodiment of the present application. Assuming that the distance interval gradually decreases with the number of times the points are taken, the reference points become more and more dense with the number of times the points are taken. It can be seen in Figure 13 that along the direction of travel, the first reference point is increasingly concentrated on the first segment line. Similarly, along the direction of travel, the second reference point is increasingly concentrated on the second segment line.

[0100] In one possible implementation, the process of determining the target segmentation line between the first segmentation line and the second segmentation line specifically includes: when the length of the first segmentation line is greater than the length of the second segmentation line, determining the first segmentation line as the target segmentation line; or, when the length of the first segmentation line is less than the length of the second segmentation line, determining the second segmentation line as the target segmentation line; or, when the length of the first segmentation line is equal to the length of the second segmentation line, determining the first segmentation line or the second segmentation line as the target segmentation line.

[0101] The purpose of the above process is to select the longer of the first segmented line and the second segmented line as the target segmented line. This method determines the target segmented line according to the actual situation of the specific scene by comparing the lengths of the first segmented line and the second segmented line. The selection rules are flexible and can adapt to segmented lines of different lengths. Whether the first segmented line is longer, the second segmented line is longer, or the lengths of the two are equal, they can be selected according to the specific situation. It is only necessary to compare the lengths of the first segmented line and the second segmented line to select the target segmented line. The operation is simple and clear, and it can avoid complex calculation processes and additional judgment conditions, thereby reducing the amount of calculation in the lane centerline generation process and improving generation efficiency. In addition, the target segmented line is determined based on the length difference between the first segmented line and the second segmented line. When there is a significant difference in the lengths of the two segmented lines, selecting the longer one as the target segmented line can better cover the entire road, thereby improving the accuracy of the reference point pair results.

[0102] Step 404: Generate a lane centerline of the target lane based on the midpoints between the groups of first reference points and second reference points that have a corresponding relationship.

[0103] Referring to Tables 1 and 2, after considering the target lane segmentation, the shapes of the lane segments include two types: approximate triangular sectors and approximate quadrilaterals. In one possible implementation, when the first projection point corresponding to the starting point of the first lane line matches the starting point of the second lane line, it means that there is no lane segment that is approximately a triangular sector. At this time, after obtaining the first reference point and the second reference point, the coordinates of the first reference point and the second reference point are averaged to obtain the midpoint coordinates of the two points, and the midpoint coordinates are used as a point on the center line of the target lane. Repeat this process, select the first reference point and the second reference point in the next adjacent reference point pair, calculate the midpoint coordinates, obtain a series of midpoint coordinates of the lane centerline, and connect the generated midpoint coordinates in sequence to form the lane centerline of the target lane.

[0104] In order to further improve the accuracy of lane centerline generation, in a possible implementation method, in the process of generating lane centerlines for lane segments that are approximately triangular fans, the process of generating the lane centerline of the target lane based on the midpoint between each group of corresponding first reference points and second reference points specifically includes: when the first projection point corresponding to the starting point of the first lane line does not match the starting point of the second lane line, determining a third segment line on the second lane line based on the starting point of the second lane line and the first projection point corresponding to the starting point of the first lane line; taking points in the third segment line to obtain a third reference point; and generating the lane centerline of the target lane based on the midpoint between each group of corresponding first reference points and second reference points, and the midpoint between the third reference point and the starting point of the first lane line.

[0105] In the above embodiment, if the first projection point corresponding to the starting point of the first lane line does not match the starting point of the second lane line, it means that there is a lane segment that is approximately a triangular fan after the target lane segmentation, so it is necessary to select more reference points on the curved edge of the triangular fan to assist in generating the lane centerline. Referring to Figure 14, Figure 14 is a schematic diagram of the lane centerline in the embodiment of the present application. In Figure 14, the starting point of the first lane line is Q1, and its corresponding first projection point on the second lane line is Q1', and the starting point of the second lane line is Q2. Therefore, based on the starting point Q2 of the second lane line and the first projection point Q1' corresponding to the starting point Q1 of the first lane line, the third segment line is determined on the second lane line, where the third segment line is represented as Q2Q1'. Then, points are taken on the third segment line Q2Q1', as shown in Figure 14, and multiple points are selected on the third segment line Q2Q1' as the third reference points. At the same time, the starting point Q2 of the second lane line can also be used as the third reference point. At this time, the lane segment includes a reference point pair formed by the first reference point and the second reference point, and a reference point pair formed by the third reference point and the starting point of the first lane line. Then, the corresponding midpoints of each reference point pair are calculated to obtain the coordinates of multiple midpoints. Then, as shown in Figure 14, the multiple midpoints are connected to form the lane centerline of the target lane segment.

[0106] In one possible implementation, the process of selecting a point on the third segment line to obtain the third reference point specifically includes: selecting a point on the third segment line according to a preset distance interval to obtain the third reference point; or selecting the midpoint of the third segment line as the third reference point. In this embodiment, when selecting a point on the third segment line as the third reference point, a preset distance interval can be set, where the distance interval can be fixed or dynamically adjusted. Alternatively, for computational efficiency, the midpoint of the third segment line can be directly selected as the sampling point without calculating the distance interval.

[0107] In this way, through the above method, when the first projection point corresponding to the starting point of the first lane line does not match the starting point of the second lane line, the third segmented line is further determined on the second lane line according to the starting point of the second lane line and the first projection point corresponding to the starting point of the first lane line, and the third reference point is sampled in the third segmented line according to a specific point selection rule, and then the lane center line is determined in combination with the midpoint between each third reference point and the starting point of the first lane line. In this way, the integrity of the determined lane center line can be guaranteed, that is, it fully corresponds to the target lane, thereby improving the accuracy of the determined lane center line.

[0108] After obtaining the lane centerline for each lane segment through the above process, the embodiment of the present application connects all lane centerlines to obtain the lane centerline of the target lane. By combining segments and selecting points in equal proportions, lane centerline generation requires less data processing, which improves the efficiency of lane centerline generation. Furthermore, after obtaining the lane centerline, it can also be smoothed.

[0109] 15 and 16 , which are schematic diagrams comparing lane centerlines generated by an embodiment of the present application and lane centerlines generated by related technologies, respectively.

[0110] In Figures 15 and 16, the thick solid line represents the first lane line or the second lane line of the target lane. Each first lane line and its corresponding second lane line include a lane centerline. The thin solid line represents the lane centerline generated by the embodiments of the present application, while the dashed line represents the lane centerline generated by the related art. As shown in Figures 15 and 16, on straight road sections where the first and second lane lines are nearly parallel, the difference between the lane centerline generated by the embodiments of the present application and the lane centerline generated by the related art is small. The lane centerline generated by the embodiments of the present application may be closer to the center trajectory with less deviation. However, in areas with curves and large changes in lane line curvature, due to changes in road geometry, the lane centerline generation method of the embodiments of the present application can better capture the curvature changes and details of the curve area. Therefore, the lane centerline generated by the embodiments of the present application is more consistent with the center trajectory, with smaller positional deviations, and a higher degree of automation in the lane centerline generation process. In contrast, the lane centerline generated by the related art has large positional deviations at curves, requiring more manual correction of the lane centerline, generally requiring more than 3% of the work, resulting in a high workload and labor cost for the lane centerline generation process.

[0111] In an embodiment of the present application, for each first sampling point on the first lane line of the target lane, a projection point of each first sampling point on the second lane line of the target lane is determined as the first projection point corresponding to each first sampling point. Then, based on each first projection point, the second lane line is divided into multiple first segmentation lines. Based on each first sampling point, the first lane line is divided into multiple second segmentation lines. These multiple second segmentation lines correspond one-to-one with the multiple first segmentation lines. In this way, the lane is segmented in a reasonable and refined manner based on the projections of the first sampling points. When points are subsequently selected on the corresponding first and second segmentation lines at the same distance ratio, the corresponding first and second reference points are located in the same segment. Even in situations such as curves or with inconsistent curvature of the lane lines on both sides, the lane centerline generated based on the midpoint between the first and second reference points can have a smaller deviation due to the reduced lane granularity achieved through segmentation. This effectively reduces the error in the generated lane centerline and improves the accuracy of the generated lane centerline. In addition, lane centerline generation is performed by combining segmentation with proportional point selection, which reduces the amount of data processing and helps improve the efficiency of lane centerline generation.

[0112] In one possible implementation, on a winding road, such as an S-shaped mountain road, the relative position between the first lane line and the second lane line may change multiple times. In this case, the same first projection line may have multiple first intersection points with the second lane line. Therefore, the process of determining the first projection point corresponding to the first sampling point based on the first intersection point of the first projection line and the second lane line specifically includes: first determining the first distance between each first sampling point and the starting point of the first lane line; then determining the projection line sequence of each first projection line in order of the first distances from closest to farthest; then determining the second distance between each first intersection point and the starting point of the second lane line; and then determining the target intersection point from the first intersection points corresponding to each first projection line in order of the projection line sequence, wherein the second distances of each target intersection point increase in order of the projection line sequence; and finally, determining the target intersection point as the first projection point corresponding to the first sampling point.

[0113] Referring to Figure 17, Figure 17 is a schematic diagram illustrating an embodiment of the present application in which the same first projection line has multiple first intersections with the second lane line. The target lane in Figure 17 is S-shaped, with the starting point of the first lane line being x0. The first sampling points include x1, x2, and x3. Correspondingly, the first projection line of the first sampling point x1 is v1, the first projection line of the first sampling point x2 is v2, and the first projection line of the first sampling point x3 is v3. First projection line v1 has multiple first intersections with the second lane line, namely {y1, y2, y3}. First projection line v2 has one first intersection y4 with the second lane line, and first projection line v3 has one first intersection y5 with the second lane line. In this scenario, the process of determining the first projection point corresponding to the first sampling point based on the first intersections of the first projection line and the second lane line is as follows: First, the first distances between the first sampling points x1, x2, and x3 and the starting point x0 of the first lane line are determined. The first distances here are not the straight-line distances between the first sampling points and the starting point of the first lane line, but rather the distances between the first sampling points and the starting point of the first lane line on the first lane line. In Figure 17, the first distance between the first sampling point x1 and the starting point x0 of the first lane line is d1, the first distance between the first sampling point x2 and the starting point x0 of the first lane line is d2, and the first distance between the first sampling point x3 and the starting point x0 of the first lane line is d3. The first distances are in the following order: d1 < d2 < d3. Therefore, the projection lines of the multiple first projection lines are ordered from closest to farthest first distances: first projection line v1 → first projection line v2 → first projection line v3.

[0114] Next, determine the second distance between each first intersection point and the starting point of the second lane line. Assuming the starting point of the second lane line is y0, determine the second distance between the first intersection points y1, y2, y3, y4, and y5 and the starting point y0 of the second lane line. The second distance here is not the straight-line distance between the first intersection point and the starting point of the second lane line, but the distance between the two along the second lane line. In Figure 17, the second distance between the first intersection point y1 and the starting point y0 of the second lane line is k1, the second distance between the first intersection point y2 and the starting point y0 of the second lane line is k2, the second distance between the first intersection point y3 and the starting point y0 of the second lane line is k3, the second distance between the first intersection point y4 and the starting point y0 of the second lane line is k4, and the second distance between the first intersection point y5 and the starting point y0 of the second lane line is k5. The second distances are related by the following relationship: second distance k1 < second distance k4 < second distance k5 < second distance k2 < first distance d3.

[0115] Next, the target intersection point is determined from the multiple first intersection points corresponding to each first projection line, sorted by projection line order. Since first projection line v2 and first projection line v3 each have only one first intersection point with the second lane line, first intersection point y4 is the target intersection point for first projection line v2, and first intersection point y5 is the target intersection point for first projection line v3. Since the first projection line v1 and the second lane line have multiple first intersection points {y1, y2, y3}, the target intersection point of the first projection line v1 needs to be determined from the first intersection points {y1, y2, y3}. Since the second distances of each target intersection point must increase in order according to the projection line order, the second distance of the target intersection point of the first projection line v1 must be less than the second distance k4 of the target intersection point y4 of the first projection line v2. The second distance k4 of the target intersection point y4 of the first projection line v2 must also be less than the second distance k5 of the target intersection point y5 of the first projection line v3. According to the order of the second distances from closest to far, only the second distance k1 < the second distance k4. Therefore, the target intersection point of the first projection line v1 is determined to be the first intersection point y1 corresponding to the second distance k1. Finally, the target intersection point is determined to be the first projection point corresponding to the first sampling point x1. This yields the following: the first projection point y1 corresponding to the first sampling point x1, the first projection point y4 corresponding to the first sampling point x2, and the first projection point y5 corresponding to the first sampling point x3.

[0116] Through the above process, the first distance between the first sampling point and the starting point of the first lane line and the second distance between the first intersection point and the starting point of the second lane line are taken into account. The target intersection point corresponding to each first sampling point in the winding road section is determined according to the projection line sorting, and then the target lane line that conforms to the actual lane layout is generated.

[0117] Similarly, on a winding road section, when projecting a second sampling point between two adjacent first projection points onto the first lane line to obtain a second projection point, it is possible that the same second projection line may have multiple second intersection points with the first lane line. In this case, the process of determining the second projection point corresponding to the second sampling point based on the second intersection point of the second projection line with the first lane line of the target lane specifically includes: first determining the third distance between each second sampling point and the starting point of the second lane line; then, determining the second projection line order of each second projection line in order of the third distance from closest to farthest; then, determining the fourth distance between each second intersection point and the starting point of the first lane line; and determining the second target intersection point from the second intersection points corresponding to each second projection line in order of the second projection line order, wherein the fourth distance of each second target intersection point increases in order of the second projection line order; and finally, determining the second target intersection point as the second projection point corresponding to the second sampling point.

[0118] In one possible implementation, the process of determining the target intersection point from a plurality of first intersection points corresponding to each first projection line in sequence according to the projection line sorting specifically includes: constructing a distance matrix of the first intersection points with the second distance as a matrix element according to the projection line sorting; inputting the distance matrix into a projection point determination model, traversing the distance matrix through the projection point determination model, and determining a target matrix element sequence from the distance matrix, wherein the target matrix element sequence includes a plurality of second distances that increase in sequence according to the projection line sorting; and determining the target intersection point from a plurality of first intersection points corresponding to each first projection line according to the position of the target matrix element sequence in the distance matrix.

[0119] First, a projection line ordering based on the first distances is obtained, constructed from near to far. Next, a distance matrix is ​​constructed, where the matrix elements of the distance matrix represent the second distances between each first intersection point and the starting point of the second lane line, and each row of the matrix corresponds to the second distance of each first intersection point under a first projection line. It is understood that if a first projection line corresponds to only one first intersection point, the number of matrix elements in that row is 1. The distance matrix is ​​then input into a projection point determination model, which is used to determine the target intersection point corresponding to each first projection line based on the distance matrix.

[0120] Referring to FIG18 , FIG18 is a schematic diagram of the projection line determination model in an embodiment of the present application. The projection point determination model is expressed as: Fun(x, y) = the longest continuously increasing subsequence, where x represents the projection line order, and y represents the second distance between each first intersection point and the starting point of the second lane line. The known quantities in the projection line determination model include the projection line order and the second distance, and the result constraints include two: 1) the projection line order constraint is satisfied; 2) the second distance from the starting point of the second lane line is increasing. When determining the target intersection point, the projection point determination model traverses the distance matrix, sorts the projection lines, and selects the first intersection point that satisfies the rule of gradually increasing values ​​of the corresponding matrix elements as the target intersection point, thereby obtaining the longest continuously increasing subsequence.

[0121] In one possible implementation, referring to Figure 19 , which is a schematic diagram of a distance matrix in an embodiment of the present application, Figure 19 includes eight first projection lines, and each first projection line has four intersections with the second lane line. Sorted by projection lines, the second distances of the four first intersections of the first projection line V0 are: 30, 129, 75, 173 respectively; the second distances of the four first intersections of the first projection line V1 are: 45, 146, 85, 180 respectively; the second distances of the four first intersections of the first projection line V2 are: 65, 163, 20, 120 respectively; the second distances of the four first intersections of the first projection line V3 are: 190, 90, 51, 150 respectively; the second distances of the starting points of the four first intersections of the first projection line V4 are: 29, 128, 78, 174 respectively; the second distances of the four first intersections of the first projection line V5 are: 44, 145, 73, 172 respectively; the second distances of the four first intersections of the first projection line V6 are: 64, 162, 18, 119 respectively; the second distances of the four first intersections of the first projection line V7 are: 191, 89, 52, 151 respectively. Therefore, the distance matrix in Figure 19 is expressed as:

[0122] The above distance matrix is ​​input into the projection line determination model, and the target intersection point of each first projection line is selected row by row. It needs to satisfy the following: according to the projection line sorting, the second distance of the target intersection point of the previous first projection line is less than the second distance of the target intersection point of the next first projection line. Therefore, each matrix element in the distance matrix needs to be comprehensively considered during selection. In Figure 19, for the first projection line V0, the second distance corresponding to the selected target intersection point is 30, for the first projection line V1, the second distance corresponding to the selected target intersection point is 45, for the first projection line V2, the second distance corresponding to the selected target intersection point is 65, for the first projection line V3, the second distance corresponding to the selected target intersection point is 90, for the first projection line V4, the second distance corresponding to the selected target intersection point is 128, for the first projection line V5, the second distance corresponding to the selected target intersection point is 145, for the first projection line V6, the second distance corresponding to the selected target intersection point is 162, and for the first projection line V7, the second distance corresponding to the selected target intersection point is 191. The target matrix element sequence obtained above is {30, 45, 65, 90, 128, 145, 162, 191}, where the target matrix element sequence includes multiple second distances that are ordered in ascending order by projection line. Finally, based on the position of the target matrix element sequence in the distance matrix, the target intersection point is determined from the multiple first intersection points corresponding to each first projection line.

[0123] In one possible implementation, if the number of first intersection points corresponding to each first projection line in the distance matrix is ​​inconsistent, in order to reduce the computational complexity, the distance matrix can be completed by completing the other rows according to the number of matrix elements included in the row corresponding to the largest number of first intersection points. When completing, the maximum value of the row can be used to fill the missing positions.

[0124] The above process uses a projection point determination model that considers the order of projection lines and the relationship between the second distance between each first projection point and the second lane line, enabling more accurate determination of the target intersection point. Furthermore, the projection point determination model automatically processes the distance matrix and determines the target intersection point without manual intervention. This reduces the labor cost associated with traditional manual lane centerline correction, avoids tedious manual corrections and adjustments, improves work efficiency, and reduces the risk of manual operation and human error.

[0125] In one possible implementation, multiple first projection lines may intersect. In this case, in order to improve the rationality of the selection of the first projection point, it is necessary to screen the first projection points corresponding to the intersecting first projection lines to reduce the inaccuracy or confusion caused by the intersection. Therefore, the process of determining the first projection point corresponding to the first sampling point based on the first intersection of the first projection line and the second lane line specifically includes: when there are intersecting first projection lines, among the first sampling points corresponding to each of the intersecting first projection lines, two first sampling points located on both sides along the driving direction of the target road are determined as the first to-be-processed point and the second to-be-processed point; based on the number of sampling points between the first to-be-processed point and the second to-be-processed point, among the first intersections of the first projection line and the second lane line, the first intersection points corresponding to the first to-be-processed point or the second to-be-processed point are eliminated; and the first projection point is determined based on the remaining first intersection points.

[0126] In the case where there are intersecting first projection lines, the first to-be-processed point and the second to-be-processed point are selected according to the driving direction of the target road, and when calculating the first intersection point, the first intersection point corresponding to the first to-be-processed point or the second to-be-processed point is eliminated according to the number of first sampling points between the two to-be-processed points, thereby removing the intersection relationship of the first projection line, and then determining the first projection point corresponding to the first sampling point based on the remaining first intersection points.

[0127] In one possible implementation, the process of eliminating the first intersection point corresponding to the first to-be-processed point or the second to-be-processed point at the first intersection of the first projection line and the second lane line based on the number of sampling points between the first to-be-processed point and the second to-be-processed point specifically includes: when the number of sampling points between the first to-be-processed point and the second to-be-processed point is greater than or equal to a quantity threshold, eliminating the first intersection point corresponding to the second to-be-processed point at the first intersection of the first projection line and the second lane line; or, when the number of sampling points between the first to-be-processed point and the second to-be-processed point is less than the quantity threshold, eliminating the first intersection point corresponding to the first to-be-processed point or the second to-be-processed point at the first intersection of the first projection line and the second lane line.

[0128] The quantity threshold can be 0 or 1. For example, when the quantity threshold is 1, and the number of first sampling points between the first to-be-processed point and the second to-be-processed point is 3, the number of first sampling points 3 is greater than the quantity threshold 1. There are multiple first sampling points near the second to-be-processed point. If only the first to-be-processed point is removed, the intersection relationship between the first projection lines may not be eliminated. Therefore, the first intersection point corresponding to the second to-be-processed point can be eliminated. When the number of first sampling points between the first to-be-processed point and the second to-be-processed point is 0, it means that there are no other first sampling points between the first to-be-processed point and the second to-be-processed point. At this time, the number of first sampling points 0 is less than the quantity threshold 1. There are no first sampling points between the first to-be-processed point or the second to-be-processed point. It can be seen that the first to-be-processed point and the second to-be-processed point are adjacent first sampling points. At this time, randomly selecting one of the first intersection points for elimination can eliminate the intersection relationship between the first projection lines.

[0129] Referring to Figure 20, Figure 20 is a schematic diagram of intersecting first projection lines in an embodiment of the present application. As can be seen from Figure 20, the first lane line includes four first sampling points {a1, a2, a3, a4}, and the corresponding first projection lines are s1, s2, s3, and s4. The first intersection point of the first sampling point a1 with the second lane line through the first projection line s1 is b1, the first intersection point of the first sampling point a2 with the second lane line through the first projection line s2 is b2, the first intersection point of the first sampling point a3 with the second lane line through the first projection line s3 is b3, and the first intersection point of the first sampling point a4 with the second lane line through the first projection line s4 is b4. Among them, the first projection line s4 intersects with the first projection line s1, the first projection line s2, and the first projection line s3, respectively. Therefore, according to the above process, since there are intersecting first projection lines, the two first sampling points located on both sides of the first sampling points corresponding to the intersecting first projection lines are sequentially determined as the first to-be-processed point and the second to-be-processed point along the driving direction of the target road. In Figure 20, the first point to be processed is determined to be a1, and the second point to be processed is determined to be a4. Then, the number of first sampling points between the first point to be processed a1 and the second point to be processed a4 is calculated. It can be seen that there are two first sampling points {a2, a3} between the first point to be processed a1 and the second point to be processed a4, so the number of sampling points is 2. Assuming that the number threshold is 1, the number of sampling points 2 is greater than the number threshold 1. Referring to Figure 20, if the first intersection point b1 corresponding to the first point to be processed a1 is removed, and the first projection line s1 corresponding to the first intersection point b1 is removed, the remaining first projection lines s2, s3, and s4 still have an intersection relationship. Therefore, it is necessary to eliminate the first intersection point b4 corresponding to the second point to be processed a4 from the first intersection points {b1, b2, b3, b4} of the first projection lines {s1, s2, s3, s4} and the second lane line of the target lane. Since the first intersection point b4 is removed, the first projection line s4 corresponding to the first intersection point b4 is removed. At this time, there is no intersection relationship between the remaining first projection lines s1, s2, and s3. Then, the first projection point {b1, b2, b3} corresponding to the first sampling point is determined based on the remaining first intersection points {b1, b2, b3}.

[0130] It is understandable that if after removing the first intersection point corresponding to the first point to be processed or the second point to be processed according to the above process, some first projection lines still have an intersection relationship, then the first point to be processed and the second point to be processed are reselected and the intersection relationship is continued to be removed according to the above process.

[0131] Referring to Figure 21, Figure 21 is another schematic diagram of intersecting first projection lines in an embodiment of the present application. As shown in Figure 21, the first lane line includes two first sampling points {a5, a6}, corresponding to first projection lines s5 and s6. The first intersection of first sampling point a5 with the second lane line through first projection line s5 is b5, and the first intersection of first sampling point a6 with the second lane line through first projection line s6 is b6. First projection line s5 intersects first projection line s6. Therefore, according to the above process, due to the existence of intersecting first projection lines, the two first sampling points located on either side of the first sampling points corresponding to the intersecting first projection lines are sequentially determined as the first to-be-processed point and the second to-be-processed point along the driving direction of the target road. The first to-be-processed point determined in Figure 21 is a5, and the second to-be-processed point is a6. The number of first sampling points between first to-be-processed point a5 and second to-be-processed point a6 is then calculated. It can be seen that there are no other first sampling points between first to-be-processed point a5 and second to-be-processed point a6, so the number of sampling points is 0. Assuming the number threshold is 1, the number of sampling points 0 is less than the number threshold 1. Referring to Figure 21 , if the first intersection point b5 corresponding to the first unprocessed point a5 or the first intersection point b6 corresponding to the first unprocessed point a6 is randomly removed, neither the remaining first projection line s5 nor the remaining first projection line s6 intersects. Therefore, either the first intersection point b5 or the first intersection point b6 can be removed. The first projection point corresponding to the first sampling point is determined based on the remaining first intersection point b5 or the first intersection point b6.

[0132] Through the above process, the first intersection point affected by the intersection relationship of the first projection line is removed, which can improve the rationality of selecting the first projection point and further improve the rationality of lane segmentation of the subsequent target lane.

[0133] Similarly, in the process of projecting the second sampling point between two adjacent first projection points onto the first lane line to obtain the second projection point, there may also be intersecting second projection lines. In this case, the process of determining the second projection point corresponding to the second sampling point based on the second intersection point of the second projection line and the first lane line of the target lane specifically includes: when there are intersecting second projection lines, among the second sampling points corresponding to each of the intersecting second projection lines, determining two second sampling points located on both sides thereof along the driving direction of the target road as a third to-be-processed point and a fourth to-be-processed point; then, based on the number of sampling points between the third to-be-processed point and the fourth to-be-processed point, among the second intersection points of the second projection line and the first lane line, excluding the second intersection point corresponding to the third to-be-processed point or the fourth to-be-processed point; and then, determining the second projection point corresponding to the second sampling point based on the remaining second intersection points. In addition, the process of eliminating the second intersection point corresponding to the third to-be-processed point or the fourth to-be-processed point at the second intersection of the second projection line and the first lane line based on the number of sampling points between the third to-be-processed point and the fourth to-be-processed point specifically includes: when the number of sampling points between the third to-be-processed point and the fourth to-be-processed point is greater than or equal to the number threshold, eliminating the second intersection point corresponding to the fourth to-be-processed point at the second intersection of the second projection line and the first lane line; or, when the number of sampling points between the third to-be-processed point and the fourth to-be-processed point is less than the number threshold, eliminating the second intersection point corresponding to the third to-be-processed point or the fourth to-be-processed point at the second intersection of the second projection line and the first lane line.

[0134] Through these multiple measures, on the one hand, appropriate first projection points and second sampling points are selected on the second lane line to rationally divide the second lane line into multiple first segmentation lines along the travel direction of the target road based on the first projection points and second sampling points. On the other hand, appropriate first sampling points and second projection points are selected on the first lane line to rationally divide the first lane line into second segmentation lines corresponding to each first segmentation line along the travel direction of the target road based on the first sampling points and second projection points. Fine-grained lane segmentation using these rationally divided first segmentation lines and second segmentation lines can better capture details of curvature changes and turning areas. The lane centerline generated based on the lane segmentation better conforms to the driving trajectory and has a smaller positional deviation of the lane centerline.

[0135] In this embodiment of the present application, after obtaining lane centerline data, it is sent to the navigation engine of the high-precision map, accurately locating the drivable lanes and effectively improving the efficiency of high-precision map production. Accurate lane centerlines provide data support for assisted driving decisions during driving, preventing vehicles from exceeding the target lane, thereby reducing the probability of traffic accidents during driving and improving the safety of assisted driving.

[0136] The principle of the lane centerline generation method in the embodiment of the present application is described in detail below.

[0137] Refer to Figure 22, which is a schematic diagram of an optional overall process of the lane centerline generation method in an embodiment of the present application.

[0138] Step 2210: For each first sampling point on the first lane line of the target lane, determine the projection point of each first sampling point on the second lane line of the target lane as the first projection point corresponding to each first sampling point.

[0139] Among them, the lane data corresponding to the target lane can be obtained from the road data, wherein the road data includes road geometry information such as the shape, length, and width of the road, and the lane data includes the positions of the lane lines on both sides of the target lane calculated based on the road geometry information. The lane line related information of the target lane can be obtained based on the lane data. In an embodiment of the present application, the road data can be data obtained by ground measurement, remote sensing, connecting to a geographic information system, or receiving automobile sensors. In addition, the first lane line and the second lane line are the lane lines on both sides of the target lane, respectively, and the sampling point is located at the position where the curvature of the lane line changes. At the same time, the starting point and end point of the lane line can also be used as the sampling points of the lane line.

[0140] In the embodiment of the present application, for each first sampling point on the first lane line of the target lane, determining the projection point of each first sampling point on the second lane line of the target lane as the first projection point corresponding to each first sampling point specifically includes:

[0141] Step 2211: Generate a first tangent line of the first lane line according to each first sampling point in the first lane line.

[0142] Step 2212: Generate a first projection line perpendicular to the first tangent line based on the first sampling point, and determine a first projection point corresponding to the first sampling point according to a first intersection point of the first projection line and the second lane line.

[0143] Among them, on a road or map, the process of extending or mapping a point along a certain direction to another line is called projection. By performing projection, a position point having a corresponding relationship between the first lane line and the second lane line of the target lane can be obtained. In this embodiment, the first sampling point on the first lane line is mapped to the second lane line by projection. And the first projection line corresponding to the first projection point obtained by projection has a projection order, and the projection order is called projection line sorting. In the embodiment of the present application, the projection line sorting can be obtained by sorting according to the distance between the corresponding first sampling point and the starting point of the first lane line, or by sorting according to the generation time of the first projection line. Specifically, step 2212 projects each first sampling point in the first lane line of the target lane to the second lane line of the target lane, which means extending the first sampling point on the first lane line in a direction perpendicular to the first lane line in which it is located until it intersects with the second lane line of the target lane to obtain a first intersection point, and obtaining the corresponding first projection point based on the first intersection point.

[0144] In one possible implementation, considering that the relative position between the first lane line and the second lane line may change multiple times in some special road sections, the same first projection line may have multiple first intersection points with the second lane line. Therefore, the process of determining the first projection point corresponding to the first sampling point based on the first intersection point of the first projection line and the second lane line in step 2212 specifically includes: first determining the first distance between each first sampling point and the starting point of the first lane line; then determining the projection line order of each first projection line in order of the first distance from closest to farthest; then determining the second distance between each first intersection point and the starting point of the second lane line; and then determining the target intersection point from the multiple first intersection points corresponding to each first projection line in order of the projection line order, wherein the second distance of each target intersection point increases in order of the projection line order; and finally, determining the target intersection point as the first projection point corresponding to the first sampling point.

[0145] In addition, the process of determining the target intersection point from the first intersection points corresponding to each first projection line in sequence according to the projection line sorting specifically includes: constructing a distance matrix of the first intersection points with the second distance as the matrix element in accordance with the projection line sorting; inputting the distance matrix into the projection point determination model, traversing the distance matrix through the projection point determination model, and determining a target matrix element sequence from the distance matrix, wherein the target matrix element sequence includes a plurality of second distances that increase in sequence according to the projection line sorting; and determining the target intersection point from the plurality of first intersection points corresponding to each first projection line according to the position of the target matrix element sequence in the distance matrix.

[0146] The above process takes into account the first distance between the first sampling point and the starting point of the first lane line, and the second distance between the first intersection point and the starting point of the second lane line. The target intersection point corresponding to each first sampling point in the winding road section is determined according to the projection line sorting, and then the target lane line that conforms to the actual lane layout is generated.

[0147] In one possible implementation, considering that multiple first projection lines may intersect, in order to improve the rationality of selecting the first projection point, it is necessary to screen the first projection points corresponding to the intersecting first projection lines to avoid inaccuracies caused by the intersection of the first projection lines. Therefore, step 2212 determines the first projection point corresponding to the first sampling point based on the first intersection of the first projection line and the second lane line, specifically including: when there are intersecting first projection lines, among the first sampling points corresponding to the intersecting first projection lines, the two first sampling points located on both sides are sequentially determined as the first to-be-processed point and the second to-be-processed point along the driving direction of the target road; based on the number of sampling points between the first to-be-processed point and the second to-be-processed point, among the first intersections of the first projection line and the second lane line, the first intersection points corresponding to the first to-be-processed point or the second to-be-processed point are eliminated; and the first projection point is determined based on the remaining first intersection points.

[0148] In one possible implementation, the process of eliminating the first intersection point corresponding to the first to-be-processed point or the second to-be-processed point at the first intersection of the first projection line and the second lane line based on the number of sampling points between the first to-be-processed point and the second to-be-processed point specifically includes: when the number of sampling points between the first to-be-processed point and the second to-be-processed point is greater than or equal to a quantity threshold, eliminating the first intersection point corresponding to the second to-be-processed point at the first intersection of the first projection line and the second lane line; or, when the number of sampling points between the first to-be-processed point and the second to-be-processed point is less than the quantity threshold, eliminating the first intersection point corresponding to the first to-be-processed point or the second to-be-processed point at the first intersection of the first projection line and the second lane line.

[0149] By removing the first intersection point affected by the intersection relationship of the first projection lines through the above process, the rationality of selecting the first projection point can be improved, thereby improving the rationality of lane segmentation of the subsequent target lane.

[0150] In the above process, starting from each first sampling point in the first lane line of the target lane, projection is performed toward the second lane line of the target lane to obtain a corresponding first projection point.

[0151] Step 2220: Divide the second lane line into multiple first segmentation lines according to each first projection point, and divide the first lane line into multiple second segmentation lines according to each first sampling point, with the multiple first segmentation lines corresponding to the multiple second segmentation lines one by one.

[0152] The method uses a projection line sorting algorithm based on the first projection line of the first sampling point to obtain the order of the first projection points. The second lane line is then segmented sequentially along the travel direction of the target road in the order of the first projection points to obtain multiple first segmentation lines. The first lane line is then segmented sequentially along the travel direction of the target road in the order of the first sampling points, creating second segmentation lines corresponding to each first segmentation line. In this way, the two lane lines of the target lane are segmented and the segmentation lines are aligned.

[0153] In one possible implementation, in order to more reasonably subdivide the two lane boundary lines of the target lane, the first lane line is reversely segmented based on the curvature change of the second lane line. Therefore, the second lane line is divided into multiple first segment lines based on each first projection point, and the first lane line is divided into multiple second segment lines based on each first sampling point. The process specifically includes:

[0154] Step 2221: For a second sampling point between two adjacent first projection points on the second lane line, determine a projection point of the second sampling point on the first lane line as the second projection point corresponding to the second sampling point.

[0155] Wherein, a second sampling point exists between adjacent first projection points on the second lane line. Similarly, the second sampling point includes the start point, end point, or point where the curvature of the second lane line changes. The second sampling point is selected between two adjacent first projection points in the order of the first projection points.

[0156] Step 2222: Divide the second lane line into a plurality of first segment lines along the driving direction of the target lane according to the first projection point and the second sampling point.

[0157] A second tangent line for the second lane line is generated based on the second sampling point. A second projection line perpendicular to the second tangent line is then generated at the location of the second sampling point. The second projection line is extended until it intersects the first lane line. The intersection is recorded as the second intersection point. Based on the second intersection point, a second projection point corresponding to the second sampling point on the first lane line is determined. At this point, the second lane line includes the first projection point and the second sampling point, and the first projection point and the second sampling point are arranged in an orderly manner. Therefore, the second lane line is sequentially divided into multiple first segment lines along the driving direction of the target road and the order of the first projection point and the second sampling point.

[0158] Step 2223: Divide the first lane line into a plurality of second segment lines along the driving direction of the target road according to the first sampling point and the second projection point.

[0159] The first lane line includes the second projection point and the first sampling point, and the second projection point and the first sampling point are arranged in order. Therefore, along the driving direction of the target road and the order of the second projection point and the first sampling point, the first lane line is sequentially divided into multiple second segment lines.

[0160] In addition, in the process of dividing the second segmented line, in order to improve the reliability and rationality of the division of the second segmented line, the second projection points need to be screened. Therefore, step 2223 is a process of dividing the first lane line into multiple second segmented lines along the driving direction according to the first sampling point and the second projection point, which specifically includes: for each second projection point, obtaining the first position coordinates of the second projection point and the second position coordinates of two target sampling points on the first lane line, wherein the two target sampling points are the first sampling points corresponding to two first projection points adjacent to the second sampling point corresponding to the second projection point; determining the positional relationship between the second projection point and the two target sampling points according to the first position coordinates and the second position coordinates; when the positional relationship indicates that the second projection point is outside the two target sampling points, the second projection point is eliminated; and dividing the first lane line into multiple second segmented lines along the driving direction according to the first sampling point and the remaining second projection points.

[0161] In one possible implementation, considering that in some special road sections, in the process of projecting the second projection point from the second sampling point between two adjacent first projection points in the second lane line to the first lane line, it is possible that there are multiple second intersections between the same second projection line and the first lane line. The second intersections can also be screened according to the target intersection determination process in the above step 2212 when there are multiple first intersections between the same first projection line and the second lane line.

[0162] In one possible implementation, considering that in some special road sections, in the process of projecting the second projection point from the second sampling point between two adjacent first projection points in the second lane line to the first lane line, there may also be intersecting second projection lines. In this case, the second projection points can also be screened according to the process of eliminating the first projection points in the case where there are intersecting first projection lines in the above step 2212.

[0163] In the embodiment of the present application, the second lane line is forward segmented based on the first sampling point of the first lane line, and then the first lane line is reversely segmented based on the second sampling point of the second lane line. Through the forward and reverse segmentation processes, the correspondence between the first lane line and the second lane line can be better established, thereby achieving a more reasonable division of the target lane.

[0164] Step 2230: According to the same distance ratio, points are taken on the first segment line and the second segment line with corresponding relationship to obtain the first reference point on the first segment line and the second reference point on the second segment line. The first reference point and the second reference point correspond one to one.

[0165] In a possible implementation, step 2230 of selecting points on the first segment line and the second segment line having a corresponding relationship according to the same distance ratio specifically includes:

[0166] Step 2231: Determine a target segment line between the first segment line and the second segment line, and select points on the target segment line according to a preset distance interval.

[0167] If the target segmentation line is the first segmentation line, the target segmentation line corresponds to the second segmentation line; if the target segmentation line is the second segmentation line, the target segmentation line corresponds to the first segmentation line.

[0168] Step 2232: Determine the distance ratio according to the distance interval, and select a point on the first segment line or the second segment line corresponding to the target segment line according to the distance ratio.

[0169] In one possible implementation, assuming the target segment line is the first segment line, points are selected on the first segment line starting from the starting point according to a preset distance interval. The preset distance interval can be set based on the actual scenario. After determining the distance interval, the distance ratio is calculated. The first first reference point is then selected on the first segment line based on the distance interval. Next, on the second segment line, the point location is calculated based on the distance ratio and the first second reference point is selected. At this point, the first reference point and the second reference point form a reference point pair. Similarly, the first reference point is evenly selected on the first segment line and the second reference point is evenly selected on the second segment line to form multiple reference point pairs.

[0170] In one possible implementation, the preset distance interval can be dynamically and adaptively adjusted each time a point is taken, that is, the distance interval may change each time a point is taken. At this time, each time a point is taken, it is necessary to calculate the distance ratio based on the current distance interval to ensure that the reference point taken on the target segmentation line changes with the distance interval, and at the same time changes synchronously with the reference point on the first segmentation line or the second segmentation line corresponding to the target segmentation line.

[0171] In one possible implementation, the process of determining a target segmentation line from a first segmentation line and a second segmentation line specifically includes: determining the first segmentation line as the target segmentation line when the length of the first segmentation line is greater than the length of the second segmentation line; or determining the second segmentation line as the target segmentation line when the length of the first segmentation line is less than the length of the second segmentation line; or determining either the first segmentation line or the second segmentation line as the target segmentation line when the length of the first segmentation line is equal to the length of the second segmentation line. The purpose is to select the longer of the first segmentation line and the second segmentation line as the target segmentation line. This operation is simple and clear, avoiding complex calculation processes and additional judgment conditions, thereby reducing the computational complexity of the lane centerline generation process and improving generation efficiency. Furthermore, the target segmentation line is determined based on the length difference between the first segmentation line and the second segmentation line. When there is a significant difference in the length of the two segmentation lines, selecting the longer one as the target segmentation line can better cover the entire road, thereby improving the accuracy of the reference point pair results.

[0172] Step 2240: Generate a lane centerline of the target lane based on the midpoints between each group of corresponding first reference points and second reference points.

[0173] In one possible implementation, when the first projection point corresponding to the start point of the first lane line matches the start point of the second lane line, after obtaining the first and second reference points, the coordinates of the first and second reference points are averaged to obtain the midpoint coordinates of these two points. This midpoint coordinate is then used as a point on the centerline of the target lane. This process is repeated, selecting the next set of corresponding first and second reference points, calculating their midpoint coordinates, and obtaining a series of lane centerline midpoint coordinates. These generated midpoint coordinates are then sequentially connected to form the lane centerline of the target lane.

[0174] To further improve lane centerline generation accuracy, in one possible implementation, during lane centerline generation for a segmented, approximately triangular sector lane, step 2240 generates the target lane centerline based on the midpoint between each set of corresponding first and second reference points, specifically including:

[0175] Step 2241: When the first projection point corresponding to the starting point of the first lane line does not match the starting point of the second lane line, determine a third segment line on the second lane line based on the starting point of the second lane line and the first projection point corresponding to the starting point of the first lane line.

[0176] Step 2242: Take a point on the third segment line to obtain the third reference point.

[0177] Step 2243: Generate a lane centerline of the target lane based on the midpoints between the first reference point and the second reference point in each group, and the midpoint between the third reference point and the starting point of the first lane line.

[0178] In one possible implementation, the process of selecting points on the third segment line to obtain the third reference point specifically includes: selecting points on the third segment line according to a preset distance interval to obtain the third reference point; or selecting the midpoint of the third segment line as the third reference point. In this embodiment, a preset distance interval can be set when selecting points on the third segment line as sampling points, where the distance interval can be fixed or dynamically adjusted. Alternatively, for computational efficiency, the midpoint of the third segment line can be directly selected as the sampling point. The sampling points are then connected to form the lane centerline of the target lane segment.

[0179] After obtaining the lane centerline for each lane segment through the above process, the embodiment of the present application connects all lane centerlines to obtain the lane centerline of the target lane. By combining segments and selecting points in equal proportions, lane centerline generation requires less data processing, which improves the efficiency of lane centerline generation. Furthermore, after obtaining the lane centerline, it can also be smoothed.

[0180] In an embodiment of the present application, for each first sampling point on the first lane line of the target lane, a projection point of each first sampling point on the second lane line of the target lane is determined as the first projection point corresponding to each first sampling point. Then, based on each first projection point, the second lane line is divided into a plurality of first segmentation lines, and based on each first sampling point, the first lane line is divided into a plurality of second segmentation lines. The plurality of second segmentation lines correspond one-to-one with the plurality of first segmentation lines. In this way, the lane is segmented in a reasonable and refined manner based on the projection of the first sampling points. When points are subsequently selected on the corresponding first and second segmentation lines at the same distance ratio, the corresponding first and second reference points are located in the same segment. Even in situations such as curves or with inconsistent curvature of the lane lines on both sides, the lane centerline generated based on the midpoint between the first and second reference points can have a smaller deviation due to the reduced lane granularity achieved through segmentation, thereby effectively reducing the error of the generated lane centerline and improving the accuracy of the generated lane centerline.

[0181] For example, the lane centerline generation method in the embodiments of the present application can be applied to scenarios such as vehicle navigation, assisted driving, map drawing and updating.

[0182] It will be appreciated that, although the various steps in the above-mentioned various flow charts are shown in sequence according to the indication of the arrows, these steps are not necessarily performed in sequence according to the order indicated by the arrows. Unless clearly stated in the present embodiment, the execution of these steps does not have strict order restrictions, and these steps can be performed in other orders. Moreover, at least a portion of the steps in the above-mentioned flow charts can include multiple steps or multiple stages, and these steps or stages are not necessarily performed at the same time, but can be performed at different times, and the execution order of these steps or stages is not necessarily performed in sequence, but can be performed in turn or alternately with at least a portion of the steps or stages in other steps or other steps.

[0183] 23 , which is a schematic diagram of an optional structure of a lane centerline generating device according to an embodiment of the present application, the lane centerline generating device 2300 includes:

[0184] A projection module 2301 is configured to determine, for each first sampling point on a first lane line of a target lane, a projection point of each first sampling point on a second lane line of the target lane as a first projection point corresponding to each first sampling point, where the first lane line and the second lane line are lane lines on both sides of the target lane, respectively.

[0185] a division module 2302 for dividing the second lane line into a plurality of first segmentation lines based on each first projection point, and dividing the first lane line into a plurality of second segmentation lines based on each first sampling point, wherein the plurality of first segmentation lines correspond to the plurality of second segmentation lines in a one-to-one manner;

[0186] A reference point determination module 2303 is configured to select points on a first segment line and a second segment line that have a corresponding relationship according to the same distance ratio to obtain a first reference point on the first segment line and a second reference point on the second segment line, wherein the first reference point and the second reference point have a one-to-one correspondence;

[0187] The generating module 2304 is configured to generate a lane centerline of the target lane according to the midpoints between the groups of first reference points and second reference points having corresponding relationships.

[0188] Furthermore, the projection module 2301 is specifically configured to:

[0189] Generating a first tangent line of the first lane line according to each first sampling point in the first lane line;

[0190] A first projection line perpendicular to the first tangent line is generated based on the first sampling point, and a first projection point corresponding to the first sampling point is determined according to a first intersection point of the first projection line and the second lane line.

[0191] Furthermore, the projection module 2301 is specifically used for:

[0192] Determine a first distance between each first sampling point and the starting point of the first lane line, and determine a projection line order of each first projection line according to the first distance from near to far;

[0193] determining a second distance between each first intersection point and a starting point of a second lane line;

[0194] Sorting the projection lines, determining the target intersection point from the first intersection points corresponding to the respective first projection lines, wherein the second distances of the target intersection points are increased in sequence according to the order of the projection lines;

[0195] The target intersection point is determined as the first projection point corresponding to the first sampling point.

[0196] Furthermore, the projection module 2301 is specifically used for:

[0197] Sort by projection line and construct the distance matrix of the first intersection point with the second distance as the matrix element;

[0198] Inputting the distance matrix into a projection point determination model, traversing the distance matrix through the projection point determination model, and determining a target matrix element sequence from the distance matrix, wherein the target matrix element sequence includes a plurality of second distances that are sequentially increased according to the projection line order;

[0199] According to the position of the target matrix element sequence in the distance matrix, the target intersection point is determined in sequence from the multiple first intersection points corresponding to each of the first projection lines.

[0200] Furthermore, the projection module 2301 is specifically used for:

[0201] When there are intersecting first projection lines, among the first sampling points corresponding to the intersecting first projection lines, two first sampling points located on both sides along the driving direction of the target road are determined as the first to-be-processed point and the second to-be-processed point;

[0202] Eliminate, from among the first intersections of the first projection line and the second lane line, the first intersection corresponding to the first point to be processed or the second point to be processed according to the number of sampling points between the first point to be processed and the second point to be processed;

[0203] The first projection point is determined according to the remaining first intersection point.

[0204] Furthermore, the projection module 2301 is specifically used for:

[0205] When the number of sampling points between the first to-be-processed point and the second to-be-processed point is greater than or equal to the number threshold, the first intersection point corresponding to the second to-be-processed point is removed from the first intersection point of the first projection line and the second lane line;

[0206] Alternatively, when the number of sampling points between the first point to be processed and the second point to be processed is less than the number threshold, the first intersection point corresponding to the first point to be processed or the second point to be processed is eliminated from the first intersection point of the first projection line and the second lane line.

[0207] Furthermore, the division module 2302 is specifically configured to:

[0208] For a second sampling point between two adjacent first projection points on the second lane line, determine a projection point of the second sampling point on the first lane line as a second projection point corresponding to the second sampling point;

[0209] Dividing the second lane line into a plurality of first segmentation lines along the driving direction of the target lane according to the first projection point and the second sampling point;

[0210] The first lane line is divided into a plurality of second segment lines along the driving direction according to the first sampling point and the second projection point.

[0211] Furthermore, the division module 2302 is specifically configured to:

[0212] For each second projection point, obtain the first position coordinates of the second projection point and the second position coordinates of two target sampling points on the first lane line, where the two target sampling points are first sampling points corresponding to two first projection points adjacent to the second sampling point corresponding to the second projection point;

[0213] Determining a positional relationship between the second projection point and the two target sampling points according to the first position coordinates and the second position coordinates;

[0214] When the positional relationship indicates that the second projection point is outside the two target sampling points, the second projection point is eliminated;

[0215] The first lane line is divided into a plurality of second segmentation lines along the driving direction according to the first sampling point and the remaining second projection points.

[0216] Furthermore, the reference point determination module 2303 is specifically configured to:

[0217] Determine a target segmentation line between the first segmentation line and the second segmentation line, and select points on the target segmentation line according to a preset distance interval;

[0218] The distance ratio is determined according to the distance interval, and points are taken on another segment line other than the target segment line in the first segment line and the second segment line according to the distance ratio.

[0219] Furthermore, the reference point determination module 2303 is specifically configured to:

[0220] When the length of the first segment line is greater than the length of the second segment line, the first segment line is determined as the target segment line;

[0221] Alternatively, when the length of the first segment line is less than the length of the second segment line, the second segment line is determined as the target segment line;

[0222] Alternatively, when the length of the first segment line is equal to the length of the second segment line, the first segment line or the second segment line is determined as the target segment line.

[0223] Furthermore, the generating module 2304 is specifically configured to:

[0224] When the first projection point corresponding to the starting point of the first lane line does not match the starting point of the second lane line, determining a third segment line on the second lane line according to the starting point of the second lane line and the first projection point corresponding to the starting point of the first lane line;

[0225] Take a point on the third segment line to obtain a third reference point;

[0226] A lane centerline of the target lane is generated based on the midpoints between the corresponding first reference points and the second reference points, and the midpoint between the third reference point and the starting point of the first lane line.

[0227] Furthermore, the generating module 2304 is specifically configured to:

[0228] Pick a point on the third segment line according to the preset distance interval to obtain the third reference point;

[0229] Alternatively, the midpoint of the third segment line is used as the third reference point.

[0230] The lane centerline generating device 2300 and the lane centerline generating method are based on the same inventive concept.

[0231] In the embodiment of the present application, the electronic device used to execute the lane centerline generation method described above may be a terminal. Referring to FIG. 24 , FIG. 24 is a partial structural block diagram of the terminal in the embodiment of the present application. The terminal includes components such as a camera assembly 2410, a first memory 2420, an input unit 2430, a display unit 2440, a sensor 2450, an audio circuit 2460, a wireless fidelity (WiFi) module 2470, a first processor 2480, and a power supply 2490. Those skilled in the art will appreciate that the terminal structure shown in FIG. 24 does not limit the terminal, and may include more or fewer components than shown, or combine certain components, or arrange the components differently.

[0232] The camera assembly 2410 can be used to capture images or videos. Optionally, the camera assembly 2410 includes a front camera and a rear camera. Typically, the front camera is set on the front panel of the terminal, and the rear camera is set on the back of the terminal. In some embodiments, there are at least two rear cameras, which are any one of a main camera, a depth of field camera, a wide-angle camera, and a telephoto camera, so as to realize the fusion of the main camera and the depth of field camera to realize the background blur function, the fusion of the main camera and the wide-angle camera to realize panoramic shooting and VR (Virtual Reality) shooting function or other fusion shooting functions.

[0233] The first memory 2420 may be used to store software programs and modules. The first processor 2480 executes various functional applications and data processing of the terminal by running the software programs and modules stored in the first memory 2420 .

[0234] The input unit 2430 may be configured to receive input digital or character information and generate key signal input related to terminal settings and function control. Specifically, the input unit 2430 may include a touch panel 2431 and other input devices 2432 .

[0235] The display unit 2440 may be configured to display input information or information and various menus of the terminal. The display unit 2440 may include a display panel 2441 .

[0236] The audio circuit 2460 , the speaker 2461 , and the microphone 2462 may provide an audio interface.

[0237] The power source 2490 may be AC ​​power, DC power, disposable batteries, or rechargeable batteries.

[0238] The number of sensors 2450 can be one or more, and the one or more sensors 2450 include but are not limited to: acceleration sensors, gyroscope sensors, pressure sensors, optical sensors, etc. Among them:

[0239] The accelerometer can detect the magnitude of acceleration on the three coordinate axes of the coordinate system established by the terminal. For example, the accelerometer can be used to detect the components of gravity acceleration on the three coordinate axes. The first processor 2480 can control the display unit 2440 to display the user interface in a horizontal or vertical view based on the gravity acceleration signal collected by the accelerometer. The accelerometer can also be used to collect game or user motion data.

[0240] The gyroscope sensor can detect the terminal's body orientation and rotation angle. It can also work with the accelerometer to collect 3D motions of the user on the terminal. Based on the data collected by the gyroscope sensor, the first processor 2480 can implement the following functions: motion sensing (such as changing the UI based on the user's tilt), image stabilization during shooting, game control, and inertial navigation.

[0241] The pressure sensor can be set on the side frame of the terminal and / or the lower layer of the display unit 2440. When the pressure sensor is set on the side frame of the terminal, it can detect the user's grip signal of the terminal, and the first processor 2480 performs left and right hand recognition or shortcut operations based on the grip signal collected by the pressure sensor. When the pressure sensor is set on the lower layer of the display unit 2440, the first processor 2480 controls the operability controls on the UI interface based on the user's pressure operation on the display unit 2440. The operability controls include at least one of a button control, a scroll bar control, an icon control, and a menu control.

[0242] The optical sensor is used to collect ambient light intensity. In one embodiment, the first processor 2480 can control the display brightness of the display unit 2440 based on the ambient light intensity collected by the optical sensor. Specifically, when the ambient light intensity is high, the display brightness of the display unit 2440 is increased; when the ambient light intensity is low, the display brightness of the display unit 2440 is decreased. In another embodiment, the first processor 2480 can also dynamically adjust the shooting parameters of the camera assembly 2410 based on the ambient light intensity collected by the optical sensor.

[0243] In this embodiment, the first processor 2480 included in the terminal can execute the lane centerline generation method of the previous embodiment.

[0244] In the embodiment of the present application, the electronic device used to execute the lane centerline generation method described above can also be a server. Referring to FIG. 25 , which is a partial block diagram of the server structure in the embodiment of the present application, the server 2500 may vary significantly due to different configurations or performance. It may include one or more second processors 2510 and a second memory 2520, and one or more storage media 2530 (e.g., one or more mass storage devices) storing application programs 2533 or data 2532. The second memory 2520 and storage medium 2530 may be either transient or persistent storage. The program stored in the storage medium 2530 may include one or more modules (not shown), each of which may include a series of instruction operations on the server 2500. Furthermore, the second processor 2510 may be configured to communicate with the storage medium 2530, executing the series of instruction operations in the storage medium 2530 on the server 2500.

[0245] The server 2500 may further include one or more power supplies 2540, one or more wired or wireless network interfaces 2550, one or more input and output interfaces 2560, and / or one or more operating systems 2531, such as Windows Server 2003. TM , Mac OS X TM , Unix TM , Linux TM , Free BSD TM wait.

[0246] The second processor 2510 in the server 2500 may be configured to execute a lane centerline generation method.

[0247] An embodiment of the present application further provides a computer-readable storage medium, which is used to store a computer program, and the computer program is used to execute the lane centerline generation method of each of the aforementioned embodiments.

[0248] The present application also provides a computer program product, comprising a computer program stored in a computer-readable storage medium. A processor of a computer device reads the computer program from the computer-readable storage medium and executes the computer program, causing the computer device to implement the lane centerline generation method described above.

[0249] The terms "first", "second", "third", "fourth", etc. (if any) in the specification of the present application and the above-mentioned drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequential order. It should be understood that the numbers used in this way can be interchanged where appropriate to describe the embodiments of the present application, for example, they can be implemented in an order other than those illustrated or described here. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0250] It should be understood that in this application, "at least one (item)" means one or more, and "plurality" means two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "A and / or B" can mean: only A exists, only B exists, and A and B exist at the same time, where A and B can be singular or plural. The character " / " generally indicates that the previous and next associated objects are in an "or" relationship. "At least one of the following items" or similar expressions refers to any combination of these items, including any combination of single items or plural items. For example, at least one of a, b or c can mean: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, c can be single or multiple.

[0251] It should be understood that in the description of the embodiments of the present application, multiple (or multiple items) means more than two, greater than, less than, exceed, etc. are understood to exclude the number itself, and above, below, within, etc. are understood to include the number itself.

[0252] In the several embodiments of the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of units is only a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interface, device or unit, which can be electrical, mechanical or other forms.

[0253] Units described as separate components may or may not be physically separate, and components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.

[0254] In addition, the functional units in the various embodiments of the present application may be integrated into a single processing unit, or each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.

[0255] 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, 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. The computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the various embodiments of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.

[0256] It should also be understood that the various implementations in the embodiments of the present application can be combined arbitrarily to achieve different technical effects.

[0257] The above is a specific description of the preferred implementation of the present application, but the present application is not limited to the above implementation mode. Technical personnel familiar with the art can also make various equivalent modifications or substitutions under the shared conditions that do not violate the spirit of the present application. These equivalent modifications or substitutions are all included in the scope defined by the claims of the present application.

Claims

1. A lane centerline generation method, executed by an electronic device, comprising: For each first sampling point on a first lane line of a target lane, determine a projection point of each first sampling point on a second lane line of the target lane as a first projection point corresponding to each first sampling point, wherein the first lane line and the second lane line are lane lines on both sides of the target lane respectively; According to each of the first projection points, the second lane line is divided into a plurality of first segmentation lines; according to each of the first sampling points, the first lane line is divided into a plurality of second segmentation lines, and the plurality of first segmentation lines correspond to the plurality of second segmentation lines one by one; According to the same distance ratio, points are selected on the first segment line and the second segment line having a corresponding relationship to obtain a first reference point on the first segment line and a second reference point on the second segment line, wherein the first reference point and the second reference point correspond to each other one by one; A lane centerline of the target lane is generated according to midpoints between each group of corresponding first reference points and second reference points.

2. The lane centerline generation method according to claim 1, wherein the second lane line is divided into a plurality of first segmentation lines according to each of the first projection points, and the first lane line is divided into a plurality of second segmentation lines according to each of the first shape points, comprising: For a second sampling point between two adjacent first projection points on the second lane line, determine a projection point of the second sampling point on the first lane line as a second projection point corresponding to the second sampling point; Dividing the second lane line into the plurality of first segmentation lines along the driving direction of the target lane according to the first projection point and the second sampling point; The first lane line is divided into the plurality of second segmentation lines along the driving direction according to the first sampling point and the second projection point.

3. The lane centerline generation method according to claim 2, wherein the first lane line is divided into the plurality of second segment lines along the driving direction according to the first sampling point and the second projection point, comprising: For each second projection point, obtain the first position coordinates of the second projection point and the second position coordinates of two target sampling points on the first lane line, wherein the two target sampling points are first sampling points respectively corresponding to two first projection points adjacent to the second sampling point corresponding to the second projection point; determine the positional relationship between the second projection point and the two target sampling points according to the first position coordinates and the second position coordinates; when the positional relationship indicates that the second projection point is outside the two target sampling points, remove the second projection point; The first lane line is divided into the plurality of second segment lines along the driving direction according to the first sampling point and the remaining second projection points.

4. The lane centerline generation method according to any one of claims 1 to 3, wherein for each first sampling point on the first lane line of the target lane, determining the projection point of each first sampling point on the second lane line of the target lane as the first projection point corresponding to each first sampling point comprises: generating a first tangent line of the first lane line according to each of the first sampling points in the first lane line; A first projection line perpendicular to the first tangent line is generated based on the first sampling point, and the first projection point corresponding to the first sampling point is determined according to a first intersection point between the first projection line and the second lane line.

5. The lane centerline generation method according to claim 4, wherein determining the first projection point corresponding to the first sampling point according to the first intersection point of the first projection line and the second lane line comprises: Determine a first distance between each of the first sampling points and a starting point of the first lane line, and determine a projection line sequence of each of the first projection lines according to the first distances from near to far; Determine a second distance between each of the first intersection points and a starting point of the second lane line; According to the order of the projection lines, the target intersection point is determined from the first intersection points corresponding to the first projection lines in sequence, wherein the second distances of the target intersection points are increased in sequence according to the order of the projection lines; The target intersection point is determined as the first projection point corresponding to the first sampling point.

6. The lane centerline generation method according to claim 5, wherein the step of determining the target intersection point from the plurality of first intersection points corresponding to each of the first projection lines in order of the projection lines comprises: Sorting the projection lines, and constructing a distance matrix of the first intersection points using the second distances as matrix elements; Inputting the distance matrix into a projection point determination model, traversing the distance matrix through the projection point determination model, and determining a target matrix element sequence from the distance matrix, wherein the target matrix element sequence includes a plurality of second distances that are sequentially increased according to the order of the projection lines; According to the position of the target matrix element sequence in the distance matrix, the target intersection point is determined in sequence from the plurality of first intersection points corresponding to each of the first projection lines.

7. The lane centerline generation method according to any one of claims 4 to 6, wherein determining the first projection point corresponding to the first sampling point according to the first intersection point of the first projection line and the second lane line comprises: When there are intersecting first projection lines, among the first sampling points corresponding to the intersecting first projection lines, two first sampling points located on both sides along the driving direction of the target road are determined as a first to-be-processed point and a second to-be-processed point; According to the number of sampling points between the first to-be-processed point and the second to-be-processed point, among the first intersection points of the first projection line and the second lane line, the first intersection point corresponding to the first to-be-processed point or the second to-be-processed point is eliminated; The first projection point is determined according to the remaining first intersection points.

8. The lane centerline generation method according to claim 7, wherein the first intersection point corresponding to the first to-be-processed point or the second to-be-processed point is eliminated from the first intersection point of the first projection line and the second lane line according to the number of sampling points between the first to-be-processed point and the second to-be-processed point, comprising: When the number of sampling points between the first to-be-processed point and the second to-be-processed point is greater than or equal to a number threshold, the first intersection point corresponding to the second to-be-processed point is removed from the first intersection points of the first projection line and the second lane line; Alternatively, when the number of sampling points between the first point to be processed and the second point to be processed is less than the number threshold, the first intersection point corresponding to the first point to be processed or the second point to be processed is eliminated from the first intersection point of the first projection line and the second lane line.

9. The lane centerline generation method according to any one of claims 1 to 8, wherein the step of selecting points on the first segment line and the second segment line having a corresponding relationship according to the same distance ratio comprises: Determine a target segmentation line between the first segmentation line and the second segmentation line, and select points on the target segmentation line according to a preset distance interval; A distance ratio is determined according to the distance interval, and points are taken on another segment line other than the target segment line in the first segment line and the second segment line according to the distance ratio.

10. The lane centerline generation method according to claim 9, wherein determining a target segmentation line among the first segmentation line and the second segmentation line comprises: When the length of the first segment line is greater than the length of the second segment line, determining the first segment line as the target segment line; Alternatively, when the length of the first segment line is less than the length of the second segment line, the second segment line is determined as the target segment line; Alternatively, when the length of the first segment line is equal to the length of the second segment line, the first segment line or the second segment line is determined as the target segment line.

11. The lane centerline generation method according to any one of claims 1 to 10, wherein generating the lane centerline of the target lane according to the midpoints between the first reference points and the second reference points in the groups having a corresponding relationship comprises: When the first projection point corresponding to the starting point of the first lane line does not match the starting point of the second lane line, determining a third segment line on the second lane line according to the starting point of the second lane line and the first projection point corresponding to the starting point of the first lane line; Pick a point in the third segment line to obtain a third reference point; A lane centerline of the target lane is generated according to the midpoints between the first reference points and the second reference points in each group having a corresponding relationship, and the midpoint between the third reference point and the starting point of the first lane line.

12. The lane centerline generation method according to claim 11, wherein taking a point from the third segment line to obtain a third reference point comprises: Taking points from the third segment line according to a preset distance interval to obtain the third reference point; Alternatively, the midpoint of the third segment line is used as the third reference point.

13. A lane centerline generating device, comprising: a projection module, for determining, for each first sampling point on a first lane line of a target lane, a projection point of each first sampling point on a second lane line of the target lane as a first projection point corresponding to each first sampling point, wherein the first lane line and the second lane line are lane lines on both sides of the target lane respectively; a dividing module, configured to divide the second lane line into a plurality of first segmentation lines according to each of the first projection points, and to divide the first lane line into a plurality of second segmentation lines according to each of the first sampling points, wherein the plurality of first segmentation lines correspond to the plurality of second segmentation lines in a one-to-one manner; A reference point determination module, configured to select points on the first segment line and the second segment line having a corresponding relationship according to the same distance ratio, to obtain a first reference point on the first segment line and a second reference point on the second segment line, wherein the first reference point and the second reference point correspond to each other one by one; A generating module is used to generate a lane centerline of the target lane according to the midpoints between each group of the first reference points and the second reference points having a corresponding relationship.

14. An electronic device comprising a memory and a processor, wherein the memory stores a computer program, and the processor implements the lane centerline generation method according to any one of claims 1 to 12 when executing the computer program.

15. A computer-readable storage medium storing a computer program, wherein the computer program, when executed by a processor, implements the lane centerline generation method according to any one of claims 1 to 12.

16. A computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the lane centerline generation method according to any one of claims 1 to 12 is implemented.