True value generation method and device, lane line identification method and device, electronic equipment and medium

By updating the geometric feature parameters of lane lines to generate true value images, the problem of low lane line detection accuracy in existing technologies is solved, and the accuracy and robustness of the lane line recognition model are improved.

CN120808293APending Publication Date: 2025-10-17ECARX (HUBEI) TECHCO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510865295.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-25
Publication Date
2025-10-17

Smart Images

  • Figure CN120808293A_ABST
    Figure CN120808293A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a truth value generation method, a lane line identification method and device, electronic equipment and a medium, and relates to the technical field of intelligent driving. The method is applied to a lane line recognition model, and comprises the following steps: acquiring geometric feature parameters of different lane lines in a real image; the geometrical characteristic parameters comprise shape information of the lane line, and coordinate information and width information corresponding to a marking point of the lane line; and updating the geometric feature parameters of at least one lane line in the different lane lines, and generating a true value image corresponding to the true image according to the updated geometric feature parameters of the different lane lines. The method can improve the accuracy of lane recognition based on the lane line recognition model.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of intelligent driving, and in particular to a ground truth generation method, a lane line identification method, a device, an electronic device and a medium. BACKGROUND

[0002] Lane line detection is one of the important technologies in autonomous driving and intelligent transportation systems. Its purpose is to detect lane lines on the road where the vehicle is traveling in real time through a vehicle-mounted camera or other sensors, and to determine the position and direction of travel of the vehicle in the lane.

[0003] At present, a deep learning method based on instance segmentation is proposed in the known technology to realize lane line detection. Specifically, this method segments and identifies each lane line instance in the image. Through this method, multiple lane line instances can be detected at the same time, effectively ensuring the robustness of the detection, and thus it is widely used.

[0004] However, the above lane line detection method still has the defect of low detection accuracy in actual application. SUMMARY

[0005] The embodiments of the present application provide a ground truth generation method, a lane line identification method, a device, an electronic device and a medium to improve the accuracy of lane line detection.

[0006] In a first aspect, the embodiments of the present application provide a ground truth generation method, which is applied to a lane line identification model, and the method comprises:

[0007] Obtaining geometric feature parameters of different lane lines in a real image; the geometric feature parameters include shape information of the lane lines, and coordinate information and width information corresponding to the labeled points of the lane lines;

[0008] Updating the geometric feature parameters of at least one lane line of the different lane lines, and generating a ground truth image corresponding to the real image according to the updated geometric feature parameters of the different lane lines.

[0009] In a possible implementation, the updating the geometric feature parameters of at least one lane line of the different lane lines, and generating a ground truth image corresponding to the real image according to the updated geometric feature parameters of the different lane lines comprises:

[0010] According to the coordinate information of the labeled points, updating the width information corresponding to the labeled points of at least one lane line of the different lane lines;

[0011] According to the width information corresponding to each labeled point and the shape information of the lane lines, generating a ground truth image corresponding to the real image.

[0012] In a possible implementation, the updating of the geometric feature parameter of at least one lane line in the different lane lines, and the generating of the ground truth image corresponding to the real image according to the updated geometric feature parameter of the different lane lines, comprises the following steps of:

[0013] updating shape information of the at least one lane line according to width information of a target annotation point and a transverse tangent of the target annotation point; the target annotation point comprises an annotation start point and / or an annotation end point, and the transverse tangent is a line perpendicular to a center line in a width direction of the real image;

[0014] generating the ground truth image corresponding to the real image according to the width information corresponding to each annotation point and the shape information of the lane line.

[0015] In a possible implementation, the updating of the width information corresponding to the annotation point of the at least one lane line in the different lane lines according to the coordinate information of the annotation point comprises the following steps of:

[0016] obtaining type information of different lane lines in a real image; the type information is used to indicate that the lane line is any one of a first lane line and a second lane line, the first lane line is any lane line adjacent to a vehicle, and the second lane line is any lane line spaced apart from the vehicle by one lane line;

[0017] updating the width information corresponding to the annotation point of the at least one lane line according to the type information and the coordinate point of the annotation point.

[0018] In a possible implementation, the width information of the annotation point of the first lane line is kept unchanged; the updating of the width information corresponding to the annotation point of the at least one lane line according to the type information and the coordinate point of the annotation point comprises the following steps of:

[0019] for the second lane line, the width information of the first type annotation point is updated, so that the width of the first type annotation point is smaller than the width of the second type annotation point, and the width information of the second type annotation point is kept unchanged; the coordinate information of the first type annotation point indicates that the distance between the coordinate point and the shooting device is greater than a preset value, and the coordinate information of the second type annotation point indicates that the distance between the coordinate point and the shooting device is not greater than the preset value;

[0020] or, for the second lane line, the width information of the first type annotation point and the second type annotation point is updated, so that the width of the first type annotation point is equal to the width of the second type annotation point, and smaller than the width indicated by the width information of the annotation point of the first lane line;

[0021] Or, for the second lane line, the width information of the first type of annotation point and the second type of annotation point is updated, so that the width of the first type of annotation point is less than the width of the second type of annotation point, and the width of the second type of annotation point is less than the width indicated by the width information of the annotation point of the first lane line.

[0022] In a possible implementation, the updating of the width information corresponding to the annotation point of the at least one lane line according to the type information and the coordinate point of the annotation point comprises:

[0023] For the first lane line, the width information of the third type of annotation point is updated so that the width of the third type of annotation point is less than the width of the fourth type of annotation point, and the width information of the fourth type of annotation point remains unchanged; the coordinate information of the third type of annotation point indicates that the distance between the coordinate point and the shooting device is greater than a preset value, and the coordinate information of the fourth type of annotation point indicates that the distance between the coordinate point and the shooting device is not greater than the preset value.

[0024] For the second lane line, the width information of the first type of annotation point is updated so that the width of the first type of annotation point is less than the width of the second type of annotation point, and the width information of the second type of annotation point remains unchanged, or the width information of the first type of annotation point and the second type of annotation point is updated so that the width of the first type of annotation point is less than the width of the second type of annotation point, and the width of the second type of annotation point is less than or equal to the width of the fourth type of annotation point.

[0025] In a possible implementation, the updating of the shape information of the at least one lane line according to the width information of the target annotation point and the transverse tangent of the target annotation point comprises:

[0026] For each lane line, a target rectangular frame corresponding to the target annotation point is determined according to the width information of the target annotation point and the transverse tangent of the target annotation point.

[0027] The shape information of the lane line is updated according to the target rectangular frame, so that the shape indicated by the shape information of the lane line does not contain the area in the target rectangular frame.

[0028] In a possible implementation, the determination of the target rectangular frame according to the width information of the target annotation point and the transverse tangent of the target annotation point comprises:

[0029] The first intersection point and the second intersection point of the transverse tangent of the target annotation point and the shape region indicated by the shape information are obtained.

[0030] A third intersection point is determined based on the first intersection point and the width information, and a fourth intersection point is determined based on the second intersection point and the width information.

[0031] According to the coordinate information of the first intersection point, the second intersection point, the third intersection point, and the fourth intersection point, the target rectangular frame is determined.

[0032] In a possible implementation, the method further includes:

[0033] An adjacent annotation point of the target annotation point is obtained, and a target included angle between a line connecting the target annotation point and the adjacent annotation point and the transverse tangent line is obtained.

[0034] According to the target included angle and coordinate information of the target annotation point, coordinate information of the first intersection point, the second intersection point, the third intersection point, and the fourth intersection point is determined.

[0035] In a second aspect, an embodiment of the present application provides a lane line identification method, and the method includes:

[0036] An image to be segmented is collected, and the image to be segmented includes lane lines.

[0037] The image to be segmented is input into a trained lane line identification model to obtain a segmentation result, and the trained lane line identification model is obtained based on a ground truth image.

[0038] In a third aspect, an embodiment of the present application provides a ground truth generation device, and the device is applied to a lane line identification model, and the device includes:

[0039] An acquisition module is configured to acquire geometric feature parameters of different lane lines in a real image, and the geometric feature parameters include shape information of the lane lines, and coordinate information and width information corresponding to annotation points of the lane lines.

[0040] A generation module is configured to update geometric feature parameters of at least one lane line in the different lane lines, and generate a ground truth image corresponding to the real image according to the updated geometric feature parameters of the different lane lines.

[0041] In a fourth aspect, an embodiment of the present application provides a lane line identification device, and the device includes:

[0042] An acquisition module is configured to collect an image to be segmented, and the image to be segmented includes a vehicle and lane lines.

[0043] A segmentation module is configured to input the image to be segmented into a trained lane line identification model to obtain a segmentation result, and the trained lane line identification model is obtained based on a ground truth image.

[0044] In a fifth aspect, an embodiment of the present application provides an electronic device, comprising: a memory, a processor;

[0045] The memory stores computer-executable instructions.

[0046] The processor executes the computer-executable instructions stored in the memory, so that the processor executes the method according to any one of the first aspect or the second aspect.

[0047] In a sixth aspect, an embodiment of the present application provides a computer-readable storage medium, the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are executed by a processor to implement the method according to any one of the first aspect or the second aspect.

[0048] In a seventh aspect, an embodiment of the present application provides a computer program product, comprising a computer program, and the computer program is executed by a processor to implement the method according to any one of the first aspect or the second aspect.

[0049] The true value generation method, the lane line identification method, the device, the electronic device and the medium provided by the embodiments of the present application are used in a lane line identification scene. In the true value generation method of the present application, for each real image, the electronic device first obtains the geometric feature parameters of different lane lines contained in the real image, then updates the geometric feature parameters of at least one lane line to obtain updated geometric feature parameters of different lane lines, and finally generates a true value image corresponding to the real image according to the updated geometric feature parameters of different lane lines. Since the geometric feature parameters include shape information of the lane line, and coordinate information and width information corresponding to the labeled points of the lane line, and the coordinate information can reflect the distance between the labeled points and the shooting device, and the shape information can reflect the shape of the lane line, updating the geometric feature parameters of at least one lane line is beneficial to correcting the shape deviation caused by the distance, so that the final lane line presents geometric features that are more consistent with the image characteristics. Using the true value image obtained based on the foregoing process in the training process of the lane line identification model can make the trained lane line identification model have higher accuracy. BRIEF DESCRIPTION OF DRAWINGS

[0050] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.

[0051] Figure 1 An application scenario diagram of the true value generation method provided by the present application;

[0052] Figure 2 A flowchart of the true value generation method provided by the present application Figure 1 ;

[0053] Figure 3 Flowchart of the true value generation method provided in the present application Figure 2 ;

[0054] Figure 4A Example of the true value generation method provided in the present application Figure 1 ;

[0055] Figure 4B Example of updating the width information provided in the present application Figure 2 ;

[0056] Figure 4C Example of updating the width information provided in the present application Figure 3 ;

[0057] Figure 4D Example of updating the width information provided in the present application

[0058] Figure 5 Flowchart of the true value generation method provided in the present application Figure 3 ;

[0059] Figure 6A Example of updating the shape information provided in the present application Figure 1 ;

[0060] Figure 6B Example of updating the shape information provided in the present application Figure 2 ;

[0061] Figure 6C Example of updating the shape information provided in the present application Figure 3 ;

[0062] Figure 7 Flowchart of the lane line recognition method provided in the present application

[0063] Figure 8 Structure diagram of the true value generation device provided in the present application

[0064] Figure 9 Structure diagram of the lane line recognition device provided in the present application

[0065] Figure 10 Structure diagram of the electronic device provided in the present application

[0066] The specific embodiments of the present application have been shown in the above-described drawings, and will be described in more detail hereinafter. These drawings and written descriptions are not intended to limit the scope of the concept of the present application by any means, but to illustrate the concept of the present application to those skilled in the art by referring to specific embodiments. DETAILED DESCRIPTION

[0067] The exemplary embodiments will be described in detail below with reference to the drawings. In the following description, the same numbers are used to denote the same elements throughout the several views. The embodiments described in the following exemplary embodiments are not meant to represent all embodiments consistent with the present application. Rather, they are merely examples of apparatus and methods consistent with some aspects of the present application.

[0068] Lane line detection is one of the important technologies in autonomous driving and intelligent transportation systems, which aims to detect lane lines on the road where the vehicle is driving in real time through vehicle-mounted cameras or other sensors, and determine the position and driving direction of the vehicle in the lane. Lane line detection technology can help vehicles achieve automatic cruise, lane keeping, lane departure warning and other functions, improve driving safety and comfort. At the same time, lane line detection technology can also provide traffic flow monitoring, traffic accident analysis and other data support for traffic management departments, promoting the development of intelligent transportation systems.

[0069] Currently, common lane line detection methods include feature-based methods, model-based methods and deep learning-based methods. Feature-based methods detect lane lines by extracting their features such as edges, colors, textures, etc. Model-based methods detect lane lines by establishing mathematical models such as straight line models, curve models, etc. Deep learning-based methods use deep learning models such as convolutional neural networks (CNN) to learn lane line features and patterns directly from images, thereby achieving lane line detection.

[0070] Compared with traditional lane line detection methods, deep learning-based detection methods have higher accuracy and robustness. They can automatically learn lane line features and patterns, to some extent, reducing the interference of factors such as light and weather, and can handle complex scenes and road conditions. However, its performance may still be affected under extreme light conditions (such as direct sunlight, backlight) and severe weather conditions (such as heavy rain, thick fog, heavy snow). Therefore, deep learning-based methods perform well in most common scenarios, but are not completely immune to environmental factors. Among them, the deep learning method based on instance segmentation is a relatively new method. This method transforms the lane line detection problem into an instance segmentation problem, i.e. segmenting and identifying each lane line instance in the image. This method can detect multiple lane line instances simultaneously, improving the accuracy and robustness of detection, and can handle complex scenarios such as curves and intersections.

[0071] However, in the known technology, the collected real image is usually processed by a line drawing tool or the like to obtain a ground truth image corresponding to the real image, and in this process, due to the generation principle of the line drawing tool, the ground truth image cannot perfectly restore the real image, so that when the ground truth image is applied to the training process of the lane line recognition model, the lane line detection method based on instance segmentation has the defect of low detection accuracy.

[0072] Therefore, the present application provides a ground truth generation method, a lane line recognition method, a device, an electronic device and a medium to solve the above problems. Specifically, in the present application, when generating the ground truth image of the real image, the geometric feature parameters of at least one lane line in different lane lines are updated, and the ground truth image of the real image is generated according to the updated geometric feature parameters of different lane lines.

[0073] It can be understood that the method of the present application can be applied to the training scene of the lane line recognition model, and the lane line recognition model can be used in intelligent driving, intelligent traffic management, map drawing and updating, driver training and other scenes that need to use the lane line recognition model. The method of the present application can be executed by any electronic device.

[0074] As an example, Figure 1 The application scenario diagram of the ground truth generation method provided by the present application is shown as Figure 1 The method of the present application is applied to the training scene of the lane line recognition model in the vehicle, and is executed by a cloud server interacting with the vehicle controller of the vehicle. The cloud server acquires n real images collected historically and labeled with lane line annotation points to obtain the shape information of the lane lines corresponding thereto, as well as the coordinate information and width information of the annotation points of the lane lines. Further, the cloud server updates the geometric feature parameters of at least one lane line in different lane lines, and generates a ground truth image corresponding to the real image according to the updated geometric feature parameters of different lane lines, for use in the training of the lane line recognition model.

[0075] The cloud server downloads the trained lane line recognition model to the vehicle controller, so that the vehicle controller can process the to-be-segmented image based on the trained lane line recognition model to obtain a segmentation result when the to-be-segmented image is collected.

[0076] Because coordinate information can reflect the distance between the annotation point and the camera, during the above process, the cloud server can update the width information corresponding to the annotation point of at least one lane line based on the distance between the annotation point and the camera, and / or adjust the shape information of at least one lane line based on the width information of the target annotation point, so that the width and / or shape of the lane line in the final ground-truth image better matches the image characteristics. Furthermore, the cloud server uses the ground-truth image obtained based on the above process to train the lane recognition model, which can improve the accuracy of the trained lane recognition model.

[0077] The following describes in detail the technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems using specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The following describes the embodiments of the present application using an electronic device as the execution subject in conjunction with the accompanying drawings.

[0078] This embodiment provides a true value generation method, which is applied to a lane line recognition model. Figure 2 Schematic diagram of the process of generating the truth value provided in this application Figure 1 ,like Figure 2 As shown, the method includes:

[0079] S201. Obtain geometric feature parameters of different lane lines in a real image.

[0080] The geometric feature parameters include the shape information of the lane line, as well as the coordinate information and width information corresponding to the marking points of the lane line.

[0081] It should be noted that in this embodiment, lane marking points are manually annotated. The user inputs a real-world image with lane marking points into the electronic device, which then uses a corresponding recognition algorithm to identify and obtain the coordinate information corresponding to the lane marking points. Specifically, the coordinate information indicates the two-dimensional image coordinates of the marking points in the real-world image. Furthermore, the width information of each marking point can be input in real time through user interaction or obtained from a pre-configured width information library, although this is not limited in this embodiment.

[0082] On this basis, the shape information of the lane line in this embodiment is obtained based on the drawing tool. Specifically, the electronic device inputs the coordinate information and width information of each marking point into the drawing tool. The drawing tool calculates and generates shape information indicating the area occupied by the specific lane line based on these inputs through a specific graphics generation algorithm.

[0083] In actual application, the width indicated by the width information corresponding to the annotation point can also be zero, and / or the area of the lane line indicated by the shape information corresponding to the lane line is zero. That is, in actual application, the electronic device initializes the width information and the shape information to obtain the width information and the shape information before performing the method of the present application. On this basis, the ground truth image corresponding to the real image is generated by the updated width information and shape information. Through this setting, the electronic device does not need to first obtain the width information by using the drawing tool, nor does it need to obtain the width information input by the user or preconfigured, thereby reducing the steps required to generate the ground truth image.

[0084] S202, updating the geometric feature parameters of at least one lane line in different lane lines, and generating a ground truth image corresponding to the real image according to the updated geometric feature parameters of different lane lines.

[0085] In the present embodiment, the coordinate information is specifically used to indicate the distance of the annotation point from the shooting device. It should be understood that, based on the characteristics of the image, the lane line at the annotation point closer to the shooting device is wider, and the lane line at the annotation point farther from the shooting device is narrower. The lane line at the annotation point closer to the image center line is wider, and the lane line at the annotation point farther from the image center line is narrower. The shooting device is used to obtain the real image, and the image center line is specifically the center line of the real image parallel to the length direction of the lane line, i.e. the center line of the real image in the width direction.

[0086] Therefore, as a possible implementation manner, in the present embodiment, the width information corresponding to the annotation point of at least one lane line in different lane lines is updated according to the coordinate information of the annotation point. Specifically, in the present embodiment, for each annotation point on each lane line in the real image, the width information corresponding to the annotation point is updated according to the coordinate information corresponding to the annotation point, so as to update the width information corresponding to the annotation point of each lane line. More specifically, in the present embodiment, the width corresponding to the annotation point farther from the shooting device is smaller, and the width corresponding to the annotation point farther from the image center line is smaller.

[0087] In actual application, the width information of the annotation points of only two lane lines can also be updated, for example, the width information of the two lane lines farthest from the image center line in the real image is updated, and the width information of the annotation points of only three lane lines can also be updated, which is not limited in the present embodiment, as long as the width information of the annotation points of at least one lane line is updated.

[0088] On this basis, the electronic device generates a ground truth image corresponding to the real image according to the width information corresponding to each annotation point and the shape information of the lane line.

[0089] It should be understood that, when the drawing tool receives the marking point and the width information of each lane line, for each two adjacent marking points, specifically, a line connecting the two marking points is taken as a center line, and the width indicated by the width information is expanded to the left and right sides, for the marking start point and the marking end point, when connecting the marking start point and the marking end point with the corresponding adjacent marking points, the shape of the marking start point and the marking end point is a circular arc with the marking start point and the marking end point as the center and the width indicated by the width information as the radius, and the area formed by the circular arc and the horizontal tangent of the marking start point or the marking end point is an actual unnecessary area, which exceeds the start and end range of the real lane line.

[0090] Therefore, as another possible implementation, in the embodiment, the shape information of at least one lane line is updated according to the width information of the target marking point and the horizontal tangent of the target marking point. The target marking point includes the marking start point and / or the marking end point, and the horizontal tangent is a line perpendicular to the center line in the real image direction. Specifically, in the embodiment, for the marking start point and the marking end point of each lane line, the area exceeding the range of the lane line is determined according to the corresponding width information and the corresponding horizontal tangent, so as to update the shape information of at least one lane line.

[0091] In actual application, the shape information of each lane line can be updated only according to the marking start point of each lane line, or the shape information of each lane line can be updated only according to the marking end point of each lane line, or the shape information of two or more lane lines can be updated, which is not limited in the embodiment.

[0092] On this basis, the electronic device generates a ground truth image corresponding to the real image according to the width information corresponding to each marking point and the shape information of the lane line.

[0093] As another possible implementation, in the embodiment, the width information corresponding to the marking point of at least one lane line in different lane lines can also be updated according to the coordinate information of the marking point, and the shape information of at least one lane line can also be updated according to the width information of the target marking point and the horizontal tangent of the target marking point. Further, based on the width information corresponding to each marking point and the shape information of the lane line at this time, a ground truth image corresponding to the real image is generated, which is not limited in the embodiment.

[0094] In the embodiment, when the electronic device obtains the width information corresponding to each marking point and the shape information of the lane line, since the width information can determine the pixel width range of the lane line in the image, and the shape information can define the area range of the lane line in the image, the ground truth image corresponding to the real image can be generated based on the width information and the shape information.

[0095] Specifically, for each lane line, the accurate contour of the lane line is determined according to the region occupied by the lane line indicated by the shape information of the lane line. Further, under the contour, the approximate width region of the lane line in the image is outlined by sequentially expanding the corresponding number of pixels to both sides at the corresponding coordinate positions according to the width information corresponding to the labeled points contained in the lane line, so as to generate a complete lane line ground truth image.

[0096] In actual application, for each lane line, the approximate width region of the lane line in the image can also be first outlined according to the width information corresponding to the labeled points contained in the lane line, and then the intersection processing is performed in combination with the region occupied by the lane line indicated by the shape information, so as to obtain a complete lane line ground truth image, which is not limited in the embodiment.

[0097] In the method provided in the embodiment, the electronic device updates the geometric feature parameters of at least one lane line, can correct the shape deviation caused by the distance between the lane line and the shooting device, so that the geometric features of the lane line presented in the final ground truth image are more consistent with the image features, and then after the ground truth image is applied to the training process of the lane line recognition model, a lane line recognition model with higher accuracy can be obtained.

[0098] Specifically, in the embodiment, the width information is updated according to the coordinate information of the labeled points, which can more truly reflect the actual width change of the lane line at different positions, so that the width features of the lane line in the ground truth image are more consistent with the real scene. Similarly, the electronic device updates the shape information according to the width information and the transverse tangent of the target labeled point, avoids the problem that the lane line exceeds the range of the real lane line, can make the shape of the lane line in the ground truth image more accurate, and reduces the noise and errors caused by inaccurate shape.

[0099] Through the method of the embodiment, the electronic device can make the width features of the lane line in the ground truth image more consistent with the real scene, and / or make the shape of the lane line in the ground truth image more accurate, so as to both improve the accurate representation of the ground truth image to the lane line. The ground truth image obtained based on the method of the embodiment is used for the lane line recognition model, which can improve the detection accuracy and robustness of the lane line recognition model.

[0100] Figure 3 Flowchart of the ground truth generation method provided in the embodiment Figure 2 As shown in Figure 3 the embodiment takes the lane line recognition model used in the intelligent driving scene as an example to explain the process of updating the width information in detail, and the method comprises the following steps:

[0101] S301, type information of different lane lines in a real image is obtained.

[0102] The type information is used to indicate that the lane line is any one of the first lane line and the second lane line. The first lane line is any lane line adjacent to the vehicle, and the second lane line is any lane line that is one lane line away from the vehicle.

[0103] In this embodiment, the real image is specifically an image of a vehicle in motion captured by a road camera and includes up to four lane lines. Specifically, if the method of this embodiment is to be used in a lane line recognition model in a vehicle, it is also necessary to ensure that the centerline of the vehicle is consistent with the centerline of the image. In this embodiment, the lane line adjacent to the vehicle is regarded as the first lane line, and the lane line separated from the vehicle by one lane line is regarded as the second lane line. In other words, with the vehicle as the center, the first lane line on the left or right side of the vehicle is regarded as the first lane line, and the second lane line on the left or right side of the vehicle is regarded as the second lane line.

[0104] On this basis, for each real image, the electronic device determines the type information of the lane line by identifying the positional relationship between the lane line and the vehicle.

[0105] In actual applications, the real image may not be taken by road shooting equipment, and the center line of the vehicle may not be consistent with the center line of the image. For example, it may be taken manually with a camera. This is not limited in this embodiment, as long as it is determined according to the specific application scenario of the lane line recognition model.

[0106] S302: Update the width information corresponding to the marked point of at least one lane line according to the type information and the coordinates of the marked point.

[0107] It should be understood that the width of the lane line at different positions is related to the distance between the lane line and the center line of the image (i.e., the center line of the vehicle). Therefore, in addition to the coordinate points of the marked points, the electronic device in this embodiment also combines the type information of the lane line to update the width information corresponding to the marked points of the lane line.

[0108] Specifically, for the first lane line and the second lane line, as a possible implementation manner, the electronic device keeps the width information of the marking point of the first lane line unchanged.

[0109] On this basis, as a design, this application updates the width information of the first type of marking points for the second lane line so that the width of the first type of marking points is smaller than the width of the second type of marking points, and the width information of the second type of marking points remains unchanged.

[0110] The coordinate information of the first type of marked points indicates that the distance between the coordinate points and the shooting device is greater than a preset value, and the coordinate information of the second type of marked points indicates that the distance between the coordinate points and the shooting device is not greater than the preset value.

[0111] In this embodiment, the image center line of the real image close to one end of the shooting device is regarded as the position of the shooting device, and the coordinate information at the position is (0, 0). The image center line is specifically the vertical coordinate axis of the image coordinate system in the real image. Based on this setting, in this embodiment, the electronic device is configured with a preset value, which is specifically the distance between the vertical coordinate of the first type of marking point and the vertical coordinate of the position of the shooting device, wherein the length direction of the vertical coordinate is the length direction of the center line. In actual application, the preset value can also be the straight-line distance between the first type of marking point and the position of the shooting device, which is not limited in this embodiment.

[0112] Specifically, the preset value is an empirical value based on the image characteristics of historical real images. The electronic device identifies the lane line width of a plurality of historical real images, determines the position where the lane line width changes beyond the preset change degree, and obtains the preset value. The preset change degree can be 25% or 50%, which is determined according to the accuracy requirement, and is not limited in this embodiment. In actual application, the preset value can also be directly input by the user into the electronic device, which is not limited in this embodiment.

[0113] In this embodiment, for the second lane line, the first type of marking point is farther away from the shooting device than the second type of marking point, and the corresponding width should be smaller. Therefore, the electronic device updates the width information of each marking point, so that the width of the first type of marking point is smaller than the width of the second type of marking point, and the width information of the second type of marking point remains unchanged.

[0114] As an example, assuming that the original width information obtained by the electronic device indicates that the width is 16 pixel grids, Figure 4A An example of the true value generation method provided in the present application Figure 1 As shown in Figure 4A For the first lane line adjacent to the vehicle, the marking point thereon maintains the 16 pixel grids indicated by the original width information. For the two second lane lines not adjacent to the vehicle, assuming that the preset value is 645, the marking point with a vertical coordinate greater than 645 is regarded as the first type of marking point, and the width information of the first type of marking point is updated to 8 pixel grids. The marking point with a vertical coordinate not greater than 645 is regarded as the second type of marking point, and the width information of the second type of marking point remains unchanged.

[0115] As another design, for the second lane line, the width information of the first type of marking point and the second type of marking point is updated, so that the width of the first type of marking point is equal to the width of the second type of marking point, and smaller than the width indicated by the width information of the marking point of the first lane line;

[0116] As an example, assuming that the original width information obtained by the electronic device indicates that the width is 16 pixel grids, Figure 4B An example of updating the width information provided in the present application Figure 2As shown in Figure 4B For the first lane line adjacent to the vehicle, the marking points thereon keep the original 16-pixel-grid width information indication. For the two second lane lines not adjacent to the vehicle, the width information of all the marking points thereon is updated to indicate a width of 8 pixel grids.

[0117] As yet another design, for the second lane line, the width information of the first type of marking points and the second type of marking points is updated, so that the width of the first type of marking points is smaller than the width of the second type of marking points, and the width of the second type of marking points is smaller than the width indicated by the width information of the marking points of the first lane line.

[0118] As an example, it is assumed that the original width information acquired by the electronic device indicates a width of 16 pixel grids, Figure 4C Examples of updating the width information provided in the present application Figure 3 As shown in Figure 4C For the first lane line adjacent to the vehicle, the marking points thereon keep the original 16-pixel-grid width information indication. For the two second lane lines not adjacent to the vehicle, assuming that the preset value is 645, the marking points with a longitudinal coordinate greater than 645 are taken as the first type of marking points, and the width information of the first type of marking points is updated to 8 pixel grids. The marking points with a longitudinal coordinate not greater than 645 are taken as the second type of marking points, and the width information of the second type of marking points is updated to 12 pixel grids.

[0119] Through any of the above designs, on the one hand, the lane lines in the ground truth image can be made closer to the real lane lines, so that when the ground truth image is used in the training process of the lane line recognition model, a lane line recognition model with better recognition effect can be obtained. On the other hand, only the width of one type of lane line that has a greater impact on the detection result is updated, which can effectively reduce the workload and thus ensure the generation efficiency.

[0120] As another possible implementation, the width information of the marking points of the first lane line and the second lane line is simultaneously updated. On this basis, for the first lane line, the width information of the third type of marking points is updated, so that the width of the third type of marking points is smaller than the width of the fourth type of marking points, and the width information of the fourth type of marking points remains unchanged. The coordinate information of the third type of marking points indicates that the coordinate point is greater than a preset value from the shooting device, and the coordinate information of the fourth type of marking points indicates that the coordinate point is not greater than the preset value from the shooting device.

[0121] As a design, for the second lane line, the width information of the first type of marking points is updated, so that the width of the first type of marking points is smaller than the width of the second type of marking points, and the width information of the second type of marking points remains unchanged.

[0122] As another design, for the second lane line, the width information of the first type of annotation point and the second type of annotation point is updated, so that the width of the first type of annotation point is smaller than the width of the second type of annotation point, and the width of the second type of annotation point is smaller than or equal to the width of the fourth type of annotation point.

[0123] In this embodiment, the width information of the first lane line and the second lane line is updated at the same time, the width of the corresponding annotation point on the lane line is updated considering the distance of each lane line from the image center line, and further, for each type of lane line, the width information of the annotation point thereon is also updated according to the distance of the annotation point from the shooting device. Based on the above setting, all lane lines in the ground truth image can be as close to the actual situation as possible, and the lane line recognition model is trained using the ground truth image, which is beneficial to further ensure the recognition effect of the lane line recognition model.

[0124] As an example, assuming that the original width information obtained by the electronic device indicates that the width is 16 pixel grids, Figure 4D An example of updating the width information provided in this application is shown in Figure 4 as Figure 4D For the first lane line adjacent to the vehicle, assuming that the preset value is 645, the annotation point with a longitudinal coordinate greater than 645 is the third type of annotation point, and the width information of the third type of annotation point thereon is updated to 12 pixel grids. The annotation point with a longitudinal coordinate not greater than 645 is the fourth type of annotation point, and the width information of the fourth type of annotation point remains unchanged. For the two second lane lines not adjacent to the vehicle, assuming that the preset value is 645, the annotation point with a longitudinal coordinate greater than 645 is the first type of annotation point, and the width information of the first type of annotation point is updated to 8 pixel grids. The annotation point with a longitudinal coordinate not greater than 645 is the second type of annotation point, and the width information of the second type of annotation point is updated to 12 pixel grids.

[0125] It should be understood that, as an example, Figures 4A-4D In the example, only one first type of annotation point, second type of annotation point, or one third type of annotation point, fourth type of annotation point is annotated on each lane line.

[0126] In the method provided in this embodiment, the type information of the lane line is combined, and the distance of each annotation point from the shooting device and the distance of each annotation point from the image center line are considered to update the corresponding width information, so that the lane lines in the ground truth image are more consistent with the actual scene.

[0127] Optionally, when taking the end of the image center line close to the shooting device as the origin of the image coordinate system, the electronic device can also summarize a plurality of preset values according to the lane line widths of a plurality of historical real images, which correspond to a plurality of preset change degrees in the longitudinal coordinate axis direction from the origin. On this basis, when updating the width information of the marking point on each type of lane line, the electronic device sequentially reduces the width corresponding to the marking point of the corresponding lane line according to the plurality of preset values from near to far, so as to further improve the authenticity of the ground truth image.

[0128] Further optionally, the electronic device can also summarize a plurality of first preset values and a plurality of second preset values according to the lane line widths of a plurality of historical real images, which correspond to a plurality of preset change degrees in the longitudinal coordinate axis and a plurality of preset change degrees in the horizontal coordinate axis from the origin.

[0129] On this basis, when updating the width information of the marking point of each type of lane line, the electronic device sequentially reduces the width corresponding to the marking point of the corresponding lane line according to the plurality of first preset values and the plurality of second preset values, so as to further improve the authenticity of the ground truth image.

[0130] Figure 5 Flowchart of the ground truth generation method provided in the present application Figure 3 As shown in Figure 5 the embodiment, the embodiment is based on the foregoing embodiment and details the process of updating the shape information. The method comprises:

[0131] S501, for each lane line, determining a corresponding target rectangular frame according to the width information of the target marking point and the horizontal tangent of the target marking point.

[0132] In the embodiment, for each lane line, the electronic device first acquires the first intersection point and the second intersection point of the horizontal tangent of the target marking point and the shape region indicated by the shape information when determining the target rectangular frame. Then, the electronic device determines the third intersection point based on the first intersection point and the width information, and determines the fourth intersection point based on the second intersection point and the width information. Finally, the electronic device determines the target rectangular frame according to the coordinate information of the first intersection point, the second intersection point, the third intersection point and the fourth intersection point.

[0133] Specifically, the electronic device determines the coordinate information of the first intersection point, the second intersection point, the third intersection point and the fourth intersection point based on the following process:

[0134] acquiring the adjacent marking point of the target marking point, and the target angle between the line connecting the target marking point and the adjacent marking point and the horizontal tangent; determining the coordinate information of the first intersection point, the second intersection point, the third intersection point and the fourth intersection point according to the target angle and the coordinate information of the target marking point.

[0135] It should be understood that one of the first intersection point and the second intersection point is the intersection point of the transverse tangent line of the target annotation point and the circle with the target annotation point as the center and the width indicated by the width information as the radius, and the other is the intersection point of the region boundary indicated by the shape information. For the former, the distance from the target annotation point is specifically the width indicated by the width information, and for the latter, in the embodiment, the distance from the target annotation point is obtained by drawing a perpendicular line to the line connecting the target annotation point and the adjacent annotation point. Specifically, after the perpendicular line is drawn from the intersection point to the line connecting the target annotation point and the adjacent annotation point, the distance of the perpendicular line is the width indicated by the width information, and on this basis, by determining the target included angle between the line connecting the target annotation point and the adjacent annotation point and the transverse tangent line, the distance of the intersection point from the target annotation point can be obtained by using the trigonometric function. In the embodiment, the target included angle is specifically the included angle between the line connecting the first intersection point and the target annotation point and the line connecting the target annotation point and the adjacent annotation point.

[0136] On this basis, since the coordinate information of the target annotation point is known, the coordinate information of the first intersection point and the second intersection point can be obtained. Further, since the line connecting the third intersection point and the fourth intersection point is parallel to the line connecting the first intersection point and the second intersection point, and the length of the perpendicular line between the two lines is the width indicated by the width information, the coordinate information of the third intersection point and the fourth intersection point can be obtained.

[0137] More specifically, as a further illustration, it is assumed that the width indicated by the width information is R, the coordinate information of the start annotation point P0 is (x0, y0), the coordinate information of the end annotation point Q0 is (x1, y1), and the adjacent annotation point of the start annotation point P0 is P1, and the adjacent annotation point of the end annotation point Q0 is Q1.

[0138] On this basis, Figure 6A Examples of updating shape information provided for the present application Figure 1 As shown in the figure, Figure 6A For the start annotation point P0, when the target included angle a1 is an acute angle, if it is further assumed that the first intersection point is represented as A1, the second intersection point is represented as B1, the third intersection point is represented as C1, and the fourth intersection point is represented as D1, and the first intersection point is the intersection point of the transverse tangent line of P0 and the circle with P0 as the center and the width indicated by the width information as the radius, and the distance between the third intersection point and the first intersection point is the width indicated by the width information, then the coordinate information of A1 is (x0-R, y0), the coordinate information of B1 is (x0+R / sina1, y0), the coordinate information of C1 is (x0-R, y0-R), and the coordinate information of D1 is (x0+R / sina1, y0-R).

[0139] As shown in the figure, Figure 6AAs shown, for the end point marked point Q0, when the target angle a2 is an acute angle, if it is further assumed that the first intersection point is represented by A2, the second intersection point is represented by B2, the third intersection point is represented by C2, and the fourth intersection point is represented by D2, and the first intersection point is the intersection of the horizontal tangent of Q0 and the circle with it as the center and the width indicated by the width information as the radius, and the distance between the third intersection point and the first intersection point is the width indicated by the width information, then the coordinate information of A2 is (x1+R, y1), the coordinate information of B2 is (x1-R / sina2, y1), the coordinate information of C2 is (x1+R, y1+R), and the coordinate information of D2 is (x1-R / sina2, y0+R).

[0140] Figure 6B Example of updated shape information provided for this application Figure 2 ,like Figure 6B As shown, for the starting point marked point P0, when the target angle is an obtuse angle, a3 is an acute angle. If we further assume that the first intersection is represented by A3, the second intersection is represented by B3, the third intersection is represented by C3, and the fourth intersection is represented by D3, and the first intersection is the intersection of the horizontal tangent of P0 and the circle with it as the center and the width indicated by the width information as the radius, and the distance between the third intersection and the first intersection is the width indicated by the width information, then the coordinate information of A3 is (x0+R, y0), the coordinate information of B3 is (x0-R / sina, y0), the coordinate information of C3 is (x0+R, y0-R), and the coordinate information of D3 is (x0-R / sina, y0-R).

[0141] like Figure 6B As shown, for the end point marked point Q0, when the target angle is an obtuse angle, a4 is an acute angle. If it is further assumed that the first intersection point is represented by A4, the second intersection point is represented by B4, the third intersection point is represented by C4, and the fourth intersection point is represented by D4, and the first intersection point is the intersection of the horizontal tangent of Q0 and the circle with it as the center and the width indicated by the width information as the radius, and the distance between the third intersection point and the first intersection point is the width indicated by the width information, then the coordinate information of A4 is (x1-R, y1), the coordinate information of B4 is (x1+R / sina, y1), the coordinate information of C4 is (x1-R, y1+R), and the coordinate information of D4 is (x1+R / sina, y0+R).

[0142] Figure 6C Example of updated shape information provided for this application Figure 3 ,like Figure 6CAs shown, for the starting point mark point P0, when the target included angle a5 is a right angle, if further assuming that the first intersection point is represented as A5, the second intersection point is represented as B5, the third intersection point is represented as C5, and the fourth intersection point is represented as D5, and the first intersection point and the second intersection point are respectively the intersection points of the horizontal tangent of P0 on the left and right sides of P0 and the circle with P0 as the center and the width indicated by the width information as the radius, and the distance between the third intersection point and the first intersection point is the width indicated by the width information, then the coordinate information of A5 is (x0-R, y0), the coordinate information of B5 is (x0+R, y0), the coordinate information of C5 is (x0-R, y0-R), and the coordinate information of D5 is (x0+R, y0-R).

[0143] As shown, Figure 6C As shown, for the ending point mark point Q0, when the target included angle a6 is a right angle, if further assuming that the first intersection point is represented as A6, the second intersection point is represented as B6, the third intersection point is represented as C6, and the fourth intersection point is represented as D6, and the first intersection point and the second intersection point are respectively the intersection points of the horizontal tangent of Q0 on the left and right sides of Q0 and the circle with Q0 as the center and the width indicated by the width information as the radius, and the distance between the third intersection point and the first intersection point is the width indicated by the width information, then the coordinate information of A6 is (x1-R, y1), the coordinate information of B6 is (x1+R, y1), the coordinate information of C6 is (x1-R, y1+R), and the coordinate information of D6 is (x1+R, y0+R).

[0144] It should be understood that, Figures 6A-6C In the above embodiment, the black thick line is used to represent the area contour indicated by the shape information acquired by the electronic device at the beginning, the black thin line is the target rectangular frame corresponding to the target mark point, and the dashed line is an auxiliary line for understanding the scheme.

[0145] S502, updating the shape information of the lane line according to the target rectangular frame, so that the shape indicated by the shape information of the lane line does not contain the area in the target rectangular frame.

[0146] It should be understood that, for each lane line, the part of the target rectangular frame that coincides with the area indicated by the shape information is the redundant area, and therefore, in the embodiment, the electronic device needs to identify and propose the part of the redundant area after determining the target rectangular frame, so that the shape of the lane line conforms to the actual situation.

[0147] In the method provided in the embodiment, for the target mark point, the corresponding target rectangular frame can be determined based on the horizontal tangent and the corresponding width information, the part of the target rectangular frame that coincides with the area indicated by the shape information is the redundant area, and the electronic device can eliminate the redundant area by reassigning the redundant area, so that the redundant area in the final ground truth image is not used to represent the lane line, and the lane line in the ground truth image is closer to the actual situation.

[0148] The present application also provides a lane line identification method, which can be applied to intelligent driving, intelligent traffic management, map drawing and updating, driver training and the like, and is executed by a corresponding electronic device. It should be understood that the electronic device in the method embodiment of the present application and the electronic device in the method embodiment of the present application can be the same electronic device or different electronic devices.

[0149] Figure 7 The flowchart of the lane line identification method provided by the present application is shown in FIG. 1. Figure 7 As shown in FIG. 1, the lane line identification method of the present application comprises:

[0150] S701, collecting an image to be segmented.

[0151] Specifically, the image to be segmented contains lane lines. In the present embodiment, the image to be segmented contains at most four lane lines. The electronic device obtains the image to be segmented through a shooting device in the corresponding scene.

[0152] S702, inputting the image to be segmented into a trained lane line identification model to obtain a segmentation result.

[0153] The trained lane line identification model is obtained based on a ground truth image, and the ground truth image is obtained based on any of the method embodiments described above.

[0154] Specifically, the lane line identification model is trained based on the ground truth image generated by the method embodiment described above. The electronic device used for training the lane line identification model can be the same electronic device as the electronic device described above or a different electronic device, which is not limited in the present embodiment.

[0155] It should be understood that the lane line identification model is trained to output the corresponding ground truth image when the real image is input. Based on this, when the electronic device inputs the image to be segmented into the lane line identification model, the segmentation result obtained is the instance segmentation result of each lane line in the image to be segmented, including the position, shape and area occupied by each lane line, etc. Through these information, the position of the vehicle in the lane and the driving direction can be determined, which provides key data support for automatic driving and intelligent traffic and the like.

[0156] In the method provided in the present embodiment, the electronic device identifies the image to be segmented by using the lane line identification model trained by the ground truth image. Since the ground truth image generated by the method embodiment described above is more consistent with the actual scene, the lane line identification model can output a segmentation result with higher accuracy.

[0157] The present application also provides a ground truth generation device, which is applied to a lane line identification model, Figure 8 The structure diagram of the ground truth generation device provided by the present application is shown in FIG. 2.Figure 8 As shown, the device provided by the embodiment includes:

[0158] The acquisition module 81 is configured to acquire geometric feature parameters of different lane lines in the real image; the geometric feature parameters include shape information of the lane lines, and coordinate information and width information corresponding to the marking points of the lane lines;

[0159] The generation module 82 is configured to update the geometric feature parameters of at least one lane line in the different lane lines, and generate a ground truth image corresponding to the real image according to the updated geometric feature parameters of the different lane lines.

[0160] In a possible implementation, the generation module 82 is specifically configured to:

[0161] update the width information corresponding to the marking points of at least one lane line in the different lane lines according to the coordinate information of the marking points;

[0162] generate the ground truth image corresponding to the real image according to the current width information corresponding to each marking point and the shape information of the lane lines.

[0163] In a possible implementation, the generation module 82 is specifically configured to:

[0164] update the shape information of at least one lane line according to the width information of the target marking point and the transverse tangent of the target marking point; the target marking point includes a marking start point and / or a marking end point, and the transverse tangent is a line perpendicular to the center line in the width direction of the real image;

[0165] generate the ground truth image corresponding to the real image according to the current width information corresponding to each marking point and the shape information of the lane lines.

[0166] In a possible implementation, the generation module 82 is specifically configured to:

[0167] acquire type information of the different lane lines in the real image; the type information is used to indicate that the lane line is any one of a first lane line and a second lane line, the first lane line is any lane line adjacent to the vehicle, and the second lane line is any lane line spaced apart from the vehicle by one lane line;

[0168] update the width information corresponding to the marking points of at least one lane line according to the type information and the coordinate points of the marking points.

[0169] In a possible implementation, the generation module 82 is specifically configured to:

[0170] keep the width information of the marking points of the first lane line unchanged;

[0171] For the second lane line, the width information of the first type of annotation point is updated so that the width of the first type of annotation point is smaller than the width of the second type of annotation point, and the width information of the second type of annotation point remains unchanged; the coordinate information of the first type of annotation point indicates that the distance between the coordinate point and the shooting device is greater than the preset value, and the coordinate information of the second type of annotation point indicates that the distance between the coordinate point and the shooting device is not greater than the preset value.

[0172] Or, for the second lane line, the width information of the first type of annotation point and the second type of annotation point is updated so that the width of the first type of annotation point is equal to the width of the second type of annotation point, and is smaller than the width indicated by the width information of the annotation point of the first lane line.

[0173] Or, for the second lane line, the width information of the first type of annotation point and the second type of annotation point is updated so that the width of the first type of annotation point is smaller than the width of the second type of annotation point, and the width of the second type of annotation point is smaller than the width indicated by the width information of the annotation point of the first lane line.

[0174] In a possible implementation, the generating module 82 is specifically configured to:

[0175] For the first lane line, the width information of the third type of annotation point is updated so that the width of the third type of annotation point is smaller than the width of the fourth type of annotation point, and the width information of the fourth type of annotation point remains unchanged; the coordinate information of the third type of annotation point indicates that the distance between the coordinate point and the shooting device is greater than the preset value, and the coordinate information of the fourth type of annotation point indicates that the distance between the coordinate point and the shooting device is not greater than the preset value.

[0176] For the second lane line, the width information of the first type of annotation point is updated so that the width of the first type of annotation point is smaller than the width of the second type of annotation point, and the width information of the second type of annotation point remains unchanged, or the width information of the first type of annotation point and the second type of annotation point is updated so that the width of the first type of annotation point is smaller than the width of the second type of annotation point, and the width of the second type of annotation point is smaller than or equal to the width of the fourth type of annotation point.

[0177] In a possible implementation, the generating module 82 is specifically configured to:

[0178] For each lane line, the corresponding target rectangular frame is determined according to the width information of the target annotation point and the transverse tangent line of the target annotation point;

[0179] The shape information of the lane line is updated according to the target rectangular frame, so that the shape indicated by the shape information does not contain the area in the target rectangular frame.

[0180] In a possible implementation, the generating module 82 is specifically configured to:

[0181] The first intersection point and the second intersection point of the transverse tangent line of the target annotation point and the shape region indicated by the shape information are obtained;

[0182] determine the third intersection point based on the first intersection point and the width information, and determine the fourth intersection point based on the second intersection point and the width information;

[0183] determine the target rectangular frame based on coordinate information of the first intersection point, the second intersection point, the third intersection point and the fourth intersection point.

[0184] In a possible implementation, the generation module 82 is further configured to:

[0185] obtain a target angle between a line connecting the target annotation point and a neighboring annotation point and a transverse tangent line of the target annotation point and the neighboring annotation point;

[0186] determine the coordinate information of the first intersection point, the second intersection point, the third intersection point and the fourth intersection point based on the target angle and the coordinate information of the target annotation point.

[0187] The truth value generation apparatus provided in this embodiment can execute the truth value generation method provided in the method embodiments, and has similar implementation principles and technical effects, which will not be described here again.

[0188] The present application also provides a lane line identification apparatus, Figure 9 A structural schematic diagram of the lane line identification apparatus provided in the present application is shown in FIG. 1. Figure 9 As shown in the figure, the apparatus provided in this embodiment comprises:

[0189] The collection module 91 is configured to collect a to-be-segmented image; the to-be-segmented image contains a vehicle and a lane line.

[0190] The segmentation module 92 is configured to input the to-be-segmented image into a trained lane line identification model to obtain a segmentation result; the trained lane line identification model is obtained based on a truth value image; the truth value image is obtained based on the truth value generation method provided in any one of the preceding embodiments.

[0191] The lane line identification apparatus provided in this embodiment can execute the lane line identification method provided in the method embodiments, and has similar implementation principles and technical effects, which will not be described here again.

[0192] The present application also provides an electronic device, Figure 10 A structural schematic diagram of the electronic device provided in the present application is shown in FIG. 2. Figure 10 As shown in the figure, the electronic device provided in this embodiment comprises a processor 101 and a memory 102. The processor 101 and the memory 102 are connected, for example, through a bus 103. Optionally, the electronic device can further comprise a transceiver 104. It should be noted that the transceiver 104 is not limited to one in actual application, and the structure of the electronic device does not constitute a limitation on the embodiments of the present application.

[0193] The processor 101 can be a Central Processing Unit (CPU), a general-purpose processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other programmable logic device, transistor logic device, hardware component or any combination thereof. It can implement or execute the various exemplary logical blocks, modules and circuits described in connection with the disclosure. The processor 101 can also be a combination of computing functions, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, etc.

[0194] The bus 103 can include a path that transmits information between the above-mentioned components. The bus 103 can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The bus 103 can be divided into an address bus, a data bus, a control bus, etc. For convenience of representation, Figure 10 Only one thick line is used in the figure, but it does not mean that there is only one bus 103 or only one type of bus 103.

[0195] The memory 102 can be a Read Only Memory (ROM) or other type of static storage device that can store static information and instructions, a Random Access Memory (RAM) or other type of dynamic storage device that can store information and instructions, an Electrically Erasable Programmable Read Only Memory (EEPROM), a Compact Disc Read Only Memory (CD-ROM) or other optical disk storage, an optical disk storage (including a compact disk, a laser disk, an optical disk, a digital versatile disk, a Blu-ray disk, etc.), a magnetic disk storage medium or other magnetic storage device, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer, but is not limited thereto.

[0196] The memory 102 is configured to store application program codes for implementing the solutions of the present application, and the processor 101 is configured to control the execution of the application program codes. The processor 101 is configured to execute the application program codes stored in the memory 102 to implement the above-mentioned contents shown in the method embodiments.

[0197] The present application also provides a computer readable storage medium, which can include a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, and various media capable of storing program codes. Specifically, the computer readable storage medium stores program instructions, and the program instructions are used to implement the method in each of the above embodiments.

[0198] The present application also provides a computer program product, which includes a computer program. When the computer program is executed by a processor, the technical solutions of the above method embodiments are implemented. The implementation principles and technical effects are similar, and thus will not be described here.

[0199] Other embodiments of the application will be apparent to those skilled in the art from consideration of the specification and practice of the application disclosed herein. The specification and examples given are intended as illustrative only and not limiting of the true scope and spirit of the application. What is intended to be claimed is set forth in the following claims.

[0200] It should be understood that the application is not limited to the precise construction that has been described above and shown in the accompanying drawings, and that various modifications and changes can be made by those skilled in the art without departing from the scope of the application. The scope of the application is limited only by the appended claims.

Claims

1. A method for generating a true value, characterized in that: The method is applied to a lane line recognition model, and the method includes: Acquire geometric feature parameters of different lane lines in the real image; the geometric feature parameters include shape information of the lane lines, and coordinate information and width information corresponding to the marking points of the lane lines; The geometric feature parameters of at least one lane line among the different lane lines are updated, and a true value image corresponding to the real image is generated based on the updated geometric feature parameters of the different lane lines.

2. The method according to claim 1, characterized in that The updating of the geometric feature parameters of at least one lane line among the different lane lines and generating a true value image corresponding to the real image based on the updated geometric feature parameters of the different lane lines includes: updating width information corresponding to the marked point of at least one lane line among the different lane lines according to the coordinate information of the marked point; A true value image corresponding to the real image is generated according to the width information corresponding to each current marked point and the shape information of the lane line.

3. The method according to claim 1 or 2, characterized in that The updating of the geometric feature parameters of at least one lane line among the different lane lines and generating a true value image corresponding to the real image based on the updated geometric feature parameters of the different lane lines includes: updating the shape information of the at least one lane line according to width information of a target marking point and a transverse tangent of the target marking point; the target marking point includes a marking start point and / or a marking end point, and the transverse tangent is a line perpendicular to a center line of the real image in a width direction; A true value image corresponding to the real image is generated according to the width information corresponding to each current marked point and the shape information of the lane line.

4. The method according to claim 2, characterized in that The updating, based on the coordinate information of the marked point, of the width information corresponding to the marked point of at least one lane line among the different lane lines includes: Acquire type information of different lane lines in a real image; the type information is used to indicate whether the lane line is any one of a first lane line and a second lane line, where the first lane line is any lane line adjacent to the vehicle, and the second lane line is any lane line separated from the vehicle by one lane line; Update the width information corresponding to the marked point of the at least one lane line according to the type information and the coordinate point of the marked point.

5. The method according to claim 4, characterized in that Keeping the width information of the marked point of the first lane line unchanged; and updating the width information corresponding to the marked point of the at least one lane line according to the type information and the coordinate point of the marked point, including: For the second lane line, updating the width information of the first-category annotation point so that the width of the first-category annotation point is smaller than the width of the second-category annotation point, and the width information of the second-category annotation point remains unchanged; the coordinate information of the first-category annotation point indicates that the distance between the coordinate point and the camera is greater than a preset value, and the coordinate information of the second-category annotation point indicates that the distance between the coordinate point and the camera is not greater than the preset value; Alternatively, for the second lane line, the width information of the first and second type of annotation points is updated so that the width of the first and second type of annotation points is equal and smaller than the width indicated by the width information of the annotation points of the first lane line; Alternatively, for the second lane line, the width information of the first and second category annotation points is updated so that the width of the first category annotation points is smaller than the width of the second category annotation points, and the width of the second category annotation points is smaller than the width indicated by the width information of the annotation points of the first lane line.

6. The method according to claim 4, characterized in that The updating of the width information corresponding to the marked point of the at least one lane line according to the type information and the coordinate point of the marked point includes: For the first lane line, updating the width information of the third-category annotation point so that the width of the third-category annotation point is smaller than the width of the fourth-category annotation point, and the width information of the fourth-category annotation point remains unchanged; the coordinate information of the third-category annotation point indicates that the distance between the coordinate point and the camera is greater than a preset value, and the coordinate information of the fourth-category annotation point indicates that the distance between the coordinate point and the camera is not greater than the preset value; For the second lane line, update the width information of the first-category annotation point so that the width of the first-category annotation point is smaller than the width of the second-category annotation point, and the width information of the second-category annotation point remains unchanged. Alternatively, update the width information of the first-category annotation point and the second-category annotation point so that the width of the first-category annotation point is smaller than the width of the second-category annotation point, and the width of the second-category annotation point is less than or equal to the width of the fourth-category annotation point.

7. The method according to claim 3, characterized in that The updating of the shape information of the at least one lane line according to the width information of the target marked point and the transverse tangent of the target marked point includes: For each lane line, determine the corresponding target rectangular frame according to the width information of the target marked point and the transverse tangent of the target marked point; The shape information of the lane line is updated according to the target rectangular frame so that a shape indicated by the shape information of the lane line does not include an area within the target rectangular frame.

8. The method according to claim 7, characterized in that The determining a corresponding target rectangular frame according to the width information of the target marking point and the horizontal tangent of the target marking point includes: Obtaining a first intersection point and a second intersection point of a transverse tangent line of the target annotation point and a shape area indicated by the shape information; determining a third intersection based on the first intersection and the width information, and determining a fourth intersection based on the second intersection and the width information; The target rectangular frame is determined according to the coordinate information of the first intersection point, the second intersection point, the third intersection point, and the fourth intersection point.

9. The method according to claim 8, characterized in that The method further comprises: Acquire adjacent marking points of the target marking point, and a target angle between a line connecting the target marking point and the adjacent marking points and the transverse tangent line; The coordinate information of the first intersection point, the second intersection point, the third intersection point, and the fourth intersection point are determined according to the target angle and the coordinate information of the target marked point.

10. A lane line recognition method, characterized in that: The method comprises: Collecting an image to be segmented; the image to be segmented includes lane lines; The image to be segmented is input into a trained lane line recognition model to obtain a segmentation result; the trained lane line recognition model is trained based on a true value image, and the true value image is obtained based on the method according to any one of claims 1 to 9.

11. A truth value generating device, characterized in that: The device is applied to a lane line recognition model, and the device includes: An acquisition module is used to obtain geometric feature parameters of different lane lines in a real image; the geometric feature parameters include shape information of the lane lines, and coordinate information and width information corresponding to the marking points of the lane lines; A generation module is used to update the geometric feature parameters of at least one lane line among the different lane lines, and generate a true value image corresponding to the real image based on the updated geometric feature parameters of the different lane lines.

12. A lane line recognition device, characterized in that: The device comprises: An acquisition module is used to acquire an image to be segmented; the image to be segmented includes a vehicle and lane lines; A segmentation module is used to input the image to be segmented into a trained lane line recognition model to obtain a segmentation result; the trained lane line recognition model is trained based on a true value image, and the true value image is obtained based on the method described in any one of claims 1 to 9.

13. An electronic device, characterized in that: include: Memory, processor; The memory stores computer-executable instructions; The processor executes the computer-executable instructions stored in the memory, so that the processor performs the method according to any one of claims 1 to 10.

14. A computer-readable storage medium, characterized in that The computer-readable storage medium stores computer-executable instructions, which are used to implement the method according to any one of claims 1 to 10 when executed by a processor.

15. A computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the method according to any one of claims 1 to 10 is implemented.