Auxiliary driving method, device and equipment and storage medium
By identifying lane lines in driving images and determining extension lines, the problem of accuracy in judging the distance between the vehicle and the lane line is solved, the accuracy of assisted driving is improved, deviation warning is provided, and the risk of accidents is reduced.
Patent Information
- Application Number
- CN202310366349.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-30
- Publication Date
- 2024-10-01
AI Technical Summary
The accuracy of obtaining the distance between the vehicle and the lane line of the lane in the existing technology is poor, which affects the effect of assisted driving.
By identifying the lane lines in the driving image, the first distance between the extension line of the lane line and the image acquisition device installed on the vehicle is determined, errors caused by the installation position and angle are eliminated, and the accuracy of distance judgment is improved.
It improves the accuracy of assisted driving, can accurately reflect the relative position of the target vehicle and the lane line, and provides deviation warnings and trend reminders, reducing the possibility of accidents.
Smart Images

Figure CN118722618A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of autonomous driving, and in particular, to an assisted driving method, device, equipment and storage medium. Background Art
[0002] At present, with the popularization of automobile use, assisted driving has become a current research hotspot. Assisted driving refers to providing auxiliary support to the driver during the process of driving the vehicle, making it easier and safer for the driver to drive the vehicle on the road.
[0003] Assisted driving requires judgment based on the distance between the moving vehicle and the lane line of the lane it is in. However, due to the installation position and angle of the image acquisition device installed on the vehicle, the accuracy of obtaining this distance in the existing technology is poor, which affects the effect of assisted driving. Summary of the invention
[0004] The main purpose of the present disclosure is to provide an assisted driving method, device, equipment and storage medium, aiming to solve the technical problem of poor accuracy in obtaining the distance between a vehicle and the lane line of the lane in the prior art.
[0005] To achieve the above objectives, the present disclosure provides an assisted driving method, comprising:
[0006] Identify a current driving image of a target vehicle and determine at least one lane line of a lane where the target vehicle is located in the current driving image, wherein the driving image is captured by an image acquisition device;
[0007] Determine a first distance of the image acquisition device relative to an extension line of the lane line.
[0008] Optionally, the identifying a current driving image of the target vehicle and determining at least one lane line of a lane where the target vehicle is located in the current driving image includes:
[0009] Identify the current driving image of the target vehicle and determine the lane line feature points of the lane where the target vehicle is located in the current driving image;
[0010] According to the lane line feature points, a first lane line equation of the lane line in a world coordinate system is determined, and then the extension line is obtained.
[0011] Optionally, determining a first distance of the image acquisition device relative to an extension line of the lane line includes:
[0012] Determine a horizontal distance of a position of the image acquisition device relative to the first lane line equation to obtain the first distance.
[0013] Optionally, determining a first lane line equation of the lane line in a world coordinate system according to the lane line feature point includes:
[0014] Fitting the lane line feature points to obtain a second lane line equation of the lane line in a pixel coordinate system;
[0015] The second lane line equation is converted into the world coordinate system to obtain the first lane line equation.
[0016] Optionally, fitting the lane line feature points to obtain a second lane line equation of the lane line in a pixel coordinate system includes:
[0017] Performing segmented fitting on the lane line feature points to obtain a second lane line equation of a preset number of lane line segments of the lane line in the pixel coordinate system;
[0018] The converting the second lane line equation into the world coordinate system to obtain the first lane line equation includes:
[0019] The second lane line equation of each lane line segment in the pixel coordinate system is converted into the world coordinate system to obtain the first lane line equation of each lane line segment.
[0020] Optionally, determining a horizontal distance of a position of the image acquisition device relative to the first lane line equation to obtain the first distance includes:
[0021] Determine the target lane line segment that is closest to the position of the image acquisition device in the horizontal direction;
[0022] Determine a horizontal distance of the position of the image acquisition device relative to the first lane line equation of the target lane line segment to obtain the first distance.
[0023] Optionally, determining a first distance of the image acquisition device relative to an extension line of the lane line includes:
[0024] Acquire the coordinates of a first intersection point between the lane line and a lower edge of a lane line detection area, wherein the lane line detection area is a road image area in the driving image;
[0025] Acquire a second distance between the image acquisition device and a lower edge of the lane detection area;
[0026] Determine the coordinates of a second intersection between the horizontal plane where the image acquisition device is located and the extension line according to the first intersection coordinates, the second distance and the first lane line equation;
[0027] The first distance is determined according to the coordinates of the second intersection point.
[0028] Optionally, the first intersection point coordinates include a first left intersection point coordinate and a first right intersection point coordinate, the first left intersection point coordinate is the coordinate of the intersection between the left lane line and the lower edge of the lane line detection area, and the first right intersection point coordinate is the coordinate of the intersection between the right lane line and the lower edge of the lane line detection area;
[0029] The second intersection coordinates include a second left intersection coordinate and a second right intersection coordinate, the second left intersection coordinate being the coordinate of the intersection between the extension line of the left lane line and the horizontal plane where the image acquisition device is located, and the second right intersection coordinate being the coordinate of the intersection between the extension line of the right lane line and the horizontal plane where the image acquisition device is located;
[0030] The first lane line equation includes a first left lane line equation representing the left lane line and a first right lane line equation representing the right lane line;
[0031] The first distance includes a first left distance and a first right distance, the first left distance is used to represent the distance of the image acquisition device relative to the extension line of the left lane line, and the first right distance is used to represent the distance of the image acquisition device relative to the extension line of the right lane line;
[0032] The step of determining the coordinates of a second intersection between the horizontal plane where the image acquisition device is located and the extension line according to the first intersection coordinates, the second distance, and the first lane line equation includes:
[0033] Determine the sum of the ordinate in the first left intersection coordinate and the second distance as the ordinate in the second left intersection coordinate, and substitute the ordinate in the second left intersection coordinate into the first left lane line equation to obtain the abscissa in the second left intersection coordinate;
[0034] Determine the sum of the ordinate in the first right intersection coordinate and the second distance as the ordinate in the second right intersection coordinate, and substitute the ordinate in the second right intersection coordinate into the first right lane line equation to obtain the abscissa in the second right intersection coordinate;
[0035] The determining the first distance according to the second intersection coordinates includes:
[0036] Determine the first left side distance according to the coordinates of the second left intersection point;
[0037] The first right side distance is determined according to the second right intersection point coordinates.
[0038] Optionally, the method further comprises:
[0039] Determine whether to perform a lane departure warning according to the first distance.
[0040] Optionally, the first distance includes a first left distance and a first right distance, the first left distance is used to represent the distance of the image acquisition device relative to the extension line of the left lane line, and the first right distance is used to represent the distance of the image acquisition device relative to the extension line of the right lane line;
[0041] The determining whether to perform a lane departure warning according to the first distance includes:
[0042] If one of the first left distance and the first right distance is greater than a first preset distance threshold and the other is less than a second preset distance threshold, a first lane departure warning message is generated, and the first lane departure warning message is used to prompt the target vehicle to deviate to a direction corresponding to the other.
[0043] Optionally, determining whether to perform a lane departure warning according to the first distance includes:
[0044] Determine lane departure curvature information corresponding to a plurality of moments according to the first distance corresponding to the current driving image and the first distance corresponding to each frame of a plurality of consecutive frames of historical driving images before the current driving image;
[0045] Whether to perform a lane departure warning is determined according to the lane departure curvature information.
[0046] Optionally, the first distance includes a first left distance and a first right distance, the first left distance is used to represent the distance of the image acquisition device relative to the extension line of the left lane line, and the first right distance is used to represent the distance of the image acquisition device relative to the extension line of the right lane line;
[0047] The lane departure curvature information includes left departure curvature information and right departure curvature information, wherein the left departure curvature information is determined based on the first left side distance corresponding to the current driving image and the first left side distance corresponding to each frame of the historical driving image, and the right departure curvature information is determined based on the first right side distance corresponding to the current driving image and the first right side distance corresponding to each frame of the historical driving image.
[0048] Optionally, determining whether to perform a lane departure warning according to the lane departure curvature information includes:
[0049] If there is left deviation curvature information greater than a preset deviation curvature threshold, second lane departure warning information is generated, where the second lane departure warning information is used to prompt the target vehicle to deviate to the left;
[0050] If the right departure curvature information is greater than the departure curvature threshold, third lane departure warning information is generated, and the third lane departure warning information is used to prompt the target vehicle to deviate to the right.
[0051] Optionally, determining whether to perform a lane departure warning according to the lane departure curvature information includes:
[0052] If one of the left departure curvature information and the right departure curvature information corresponding to the same moment is negative and the other is positive, a fourth lane departure warning information is generated, and the fourth lane departure warning information is used to prompt that the target vehicle has a tendency to deviate to the direction corresponding to the other lane departure curvature information.
[0053] Optionally, the determining whether to perform a lane departure warning according to the lane departure curvature information further includes:
[0054] Determining left deviation rate information according to the left deviation curvature information;
[0055] Determining right deviation rate information according to the right deviation curvature information;
[0056] The fourth lane departure warning information is also used to prompt the deviation rate information corresponding to the other lane.
[0057] Optionally, the determining whether to perform a lane departure warning according to the lane departure curvature information further includes:
[0058] Determining left deviation rate information according to the left deviation curvature information;
[0059] Determining right deviation rate information according to the right deviation curvature information;
[0060] If one of the left departure curvature information and the right departure curvature information corresponding to the same moment is negative and the other is positive, then the time information required for the target vehicle to travel to the alarm critical line in the direction corresponding to the other is determined according to the deviation rate information corresponding to the other, wherein the fourth lane departure warning information is also used to prompt the time information.
[0061] In addition, to achieve the above objectives, the present disclosure also provides a driving assistance device, including:
[0062] A lane line determination module, used to identify a current driving image of a target vehicle and determine at least one lane line of a lane where the target vehicle is located in the current driving image, wherein the driving image is captured by an image acquisition device;
[0063] The first distance determination module is used to determine a first distance between the image acquisition device and the extension line of the lane line.
[0064] In addition, to achieve the above objectives, the present disclosure also provides a non-temporary computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, the steps of the above method provided by the present disclosure are implemented.
[0065] In addition, to achieve the above objectives, the present disclosure also provides an electronic device, including:
[0066] a memory having a computer program stored thereon;
[0067] A processor is used to execute the computer program in the memory to implement the steps of the above method provided by the present disclosure.
[0068] The above-mentioned technical solution proposed in the embodiment of the present application identifies the lane line in the driving image and determines the first distance between the extension line of the lane line and the image acquisition device set on the vehicle. This distance can eliminate the error caused by the installation position and angle of the image acquisition device, making the distance judgment between the target vehicle and the lane line more accurate, thereby improving the accuracy of assisted driving.
[0069] Other features and advantages of the present disclosure will be described in detail in the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0070] The accompanying drawings are used to provide a further understanding of the present disclosure and constitute a part of the specification. Together with the following specific embodiments, they are used to explain the present disclosure but do not constitute a limitation of the present disclosure. In the accompanying drawings:
[0071] Figure 1 A schematic diagram of the distance calculation between the lane line and the target vehicle in the prior art;
[0072] Figure 2 A flowchart of an assisted driving method provided by an embodiment of the present disclosure;
[0073] Figure 3 A schematic diagram of a driving image of an assisted driving method provided by an embodiment of the present disclosure;
[0074] Figure 4 A schematic diagram of the relationship between the lane line and the distance between the target vehicle in an assisted driving method provided in an embodiment of the present disclosure;
[0075] Figure 5 A schematic diagram of functional modules of a driving assistance device provided in an embodiment of the present disclosure;
[0076] Figure 6 The figure is a schematic diagram of the structure of an electronic device involved in an embodiment of the present disclosure.
[0077] Description of Reference Numerals
[0078] 401, sky invalid area; 402, road image area; 403, lower invalid area. DETAILED DESCRIPTION
[0079] The specific implementation of the present disclosure is described in detail below in conjunction with the accompanying drawings. It should be understood that the specific implementation described herein is only used to illustrate and explain the present disclosure, and is not used to limit the present disclosure.
[0080] In the present disclosure, unless otherwise specified, directional words such as "left" and "right" are used with the vehicle's traveling direction as the front.
[0081] At present, with the popularization of automobile use, assisted driving has become a current research hotspot. Assisted driving refers to providing auxiliary support to the driver during the process of driving the vehicle, so that the driver can drive the vehicle more easily and safely on the road. Assisted driving needs to be judged based on the distance between the moving vehicle and the lane line of the lane it is in. However, due to the installation position and angle of the image acquisition device installed on the vehicle, the accuracy of obtaining the distance in the existing technology is poor, which affects the effect of assisted driving.
[0082] To obtain the distance between the vehicle and the lane line of the lane it is in, it is first necessary to detect the lane line in the driving image. The inventors have found that the traditional lane line detection method is greatly affected by the environment, weather, lighting, etc. When there are occlusions, shadows, etc., the background of the driving image is complex, and it is difficult to detect the lane line or the detection effect is poor, which will affect the accuracy of the relative position relationship judgment and the assisted driving effect; secondly, the image acquisition device on the vehicle is generally not installed at the front of the vehicle, so there will be a certain perspective error in the driving image it collects, such as Figure 1 As shown in the figure, the distance between the front of the target vehicle and the left and right edges of the lane line captured in the driving image is the left intersection point (p1 x ,p1 y ) and the right intersection point (p2 x ,p2 y ) 图像However, in fact, the target vehicle has not driven to this position. The front position of the vehicle in the image is closer to the front than the real position. This distance is not the actual distance between the front of the target vehicle and the left and right edges of the lane line. Judging whether there is a deviation based on the distance in the image will result in errors, which will affect the assisted driving effect.
[0083] To this end, the present disclosure provides a solution, which identifies the lane line in the driving image and determines the first distance between the extension line of the lane line and the image acquisition device set on the vehicle. The distance can eliminate the error caused by the installation position and angle of the image acquisition device, so that the distance judgment between the target vehicle and the lane line is more accurate, thereby improving the accuracy of assisted driving; further, by determining the first lane line equation, the actual and accurate relative position relationship between the target vehicle and the lane line of the lane where the vehicle is located is reflected, and according to the first distance, the deviation rate of the target vehicle, the time to reach the pre-warning critical line and other information can also be obtained, so that deviation warning can be carried out and vehicles with deviation trends can be reminded in advance, reducing the possibility of accidents.
[0084] Figure 2 A flowchart of an assisted driving method provided by an embodiment of the present disclosure is shown in FIG. Figure 2 As shown, the method may include the following steps:
[0085] S101: Identify a current driving image of a target vehicle and determine at least one lane line of a lane where the target vehicle is located in the current driving image, wherein the driving image is captured by an image acquisition device.
[0086] In one embodiment of the present disclosure, the image acquisition device refers to a device installed on the target vehicle for obtaining the road conditions during driving, which can be a camera, a driving recorder, etc., and can obtain Figure 3 The driving image shown in the figure cannot fully show the road conditions due to the installation position of the image acquisition device. It can be divided into a sky invalid area 401, a road image area 402 and a lower invalid area 403 according to the content in the image, wherein the road image area 402 contains lane line information used later. The current driving image is identified to determine the lane line of the lane where the vehicle is located. Usually, the lane line includes a left lane line and a right lane line.
[0087] S102: Determine a first distance of the image acquisition device relative to an extension line of the lane line.
[0088] In one embodiment of the present disclosure, Figure 3As shown in the figure, the lower invalid area 403 in the driving image is the part of the road blocked by the front part of the vehicle, and this part of the road is the actual road position of the target vehicle. Therefore, when obtaining the actual distance between the vehicle and the lane line, the driving image should be reflected as calculating the distance between the vehicle and the blocked part of the lane line. Because the lane lines in the actual road are straight lines, the lane lines in the driving image can be extended, and the image acquisition device is used as the point representing the target vehicle for distance calculation, as shown in FIG. Figure 4 As shown, the first distance is the distance between the image acquisition device A and the extension line of the lane line displayed in the current driving image.
[0089] As an optional implementation, S101 may further include: identifying the current driving image of the target vehicle, and determining the lane line feature points of the lane where the target vehicle is located in the current driving image; based on the lane line feature points, determining the first lane line equation of the lane line in the world coordinate system, and then obtaining the extension line.
[0090] In one embodiment of the present disclosure, the lane line of the lane where the target vehicle is located in the driving image is identified by a deep learning model or other means to obtain lane line feature points of the lane to improve the accuracy of feature recognition. The first lane line equation is determined according to the actual distribution of the feature points. The first lane line equation is in the world coordinate system and can accurately reflect the distribution of the lane line of the lane where the target vehicle is located, that is, the first lane line equation can characterize the lane line displayed in the driving image and the lane line partially blocked by the front of the vehicle, that is, the extension line of the lane line is obtained.
[0091] In a feasible implementation, if the quality of the acquired driving image is poor, a sufficient number of feature points cannot be obtained, or the distribution of the feature points is not within a reasonable range, the driving image is judged to be invalid. At this time, the driving image can be replaced for feature recognition, and subsequent deviation judgments are no longer based on the invalid driving image to prevent misjudgment.
[0092] As an optional implementation, S102 may further include: determining a horizontal distance of a position of the image acquisition device relative to the first lane line equation to obtain the first distance.
[0093] In one embodiment of the present disclosure, the first distance is the horizontal distance between the position of the image acquisition device and the first lane line equation, that is, the distance between the image acquisition device and the extension line of the lane line of the lane where the vehicle is located.
[0094] As an optional implementation, determining the first lane line equation of the lane line in the world coordinate system based on the lane line feature points may further include: fitting the lane line feature points to obtain the second lane line equation of the lane line in the pixel coordinate system; converting the second lane line equation to the world coordinate system to obtain the first lane line equation.
[0095] In one embodiment of the present disclosure, the lane line feature points obtained in the driving image and the lane line equation determined based on the lane line feature points are both located in the pixel coordinate system (also called the image coordinate system). Due to the influence of the installation position and angle of the image acquisition device, there is a position deviation between the lane line in the pixel coordinate system and the lane line on the real ground. The lane line equation needs to be converted to the world coordinate system to reflect the actual position and distance relationship between the target vehicle and the lane line. The lane line represented by the first lane line equation and the image acquisition device are both in the world coordinate system. The first distance between the image acquisition device and the lane line determined based on the positional relationship in the same coordinate system is accurate and effective. This distance can effectively improve the accuracy when used for assisted driving.
[0096] The lane line feature points determined by feature recognition are fitted to obtain a second lane line equation. The lane line corresponding to the second lane line equation is in the pixel coordinate system. The lane line is subjected to an inverse perspective transformation to obtain a first lane line equation of the lane line in the world coordinate system.
[0097] For example, the equation of the first lane line in the world coordinate system is obtained according to the following inverse perspective mapping formula:
[0098]
[0099]
[0100] Among them, (u, v) represents the coordinate point in the pixel coordinate system, (X w ,w) represents the coordinate point w corresponding to the point (u,v) in the world coordinate system, θ is the rotation angle between the world coordinate system and the image acquisition device coordinate system (i.e., the camera coordinate system), a is the horizontal distance from the imaging point to the optical center, b is the longitudinal distance from the imaging point to the optical center, h is the height of the center of the image acquisition device coordinate system (i.e., the camera coordinate system) above the ground plane, and f x f is the focal length of the image acquisition device in the horizontal direction divided by the actual physical size of the pixel on the photosensitive chip. y is the focal length of the image acquisition device in the longitudinal direction divided by the actual physical size of the pixel on the photosensitive chip, u0 is the horizontal pixel point of the photosensitive center of the image acquisition device in the pixel coordinate system, v0 is the vertical pixel point of the photosensitive center of the image acquisition device in the pixel coordinate system, and f x 、f y, u0, and v0 are all internal parameters of the image acquisition device and can be obtained through device calibration.
[0101] As an optional implementation, the fitting of the lane line feature points to obtain a second lane line equation of the lane line in a pixel coordinate system includes: performing segmented fitting of the lane line feature points to obtain a second lane line equation of a preset number of lane line segments of the lane line in the pixel coordinate system.
[0102] In one embodiment of the present disclosure, the lane line feature points of the lane where the target vehicle is located obtained during the feature recognition process are discrete, and the discrete points cannot fully represent the actual position of the lane line, and need to be fitted into a line. Segmented fitting can fit the discrete points into multiple complete line segments, and in theory, the more segments, the more accurate the fitting line segments can be, so that the second lane line equations of the multiple line segments obtained are closer to the distribution of lane lines on the real road surface.
[0103] By way of example, this embodiment uses three-segment cubic polynomial curve fitting, that is, the feature points are divided into three parts according to the y value of the feature point coordinates, and curve fitting is performed on the discrete feature points of each part to obtain the curve coefficients, and then the curve equations of multiple line segments are obtained, that is, the second lane line equation.
[0104] At this time, converting the second lane line equation into the world coordinate system to obtain the first lane line equation includes: converting the second lane line equation of each lane line segment in the pixel coordinate system into the world coordinate system respectively to obtain the first lane line equation of each lane line segment.
[0105] It can be understood that the curve equations of the multiple line segments obtained in the above steps are respectively subjected to the inverse perspective transformation as described above to obtain the first lane line equations of each of these lane line segments in the world coordinate system.
[0106] As an optional implementation, determining the horizontal distance of the position of the image acquisition device relative to the first lane line equation to obtain the first distance may further include: determining the target lane line segment closest to the position of the image acquisition device in the horizontal direction; determining the horizontal distance of the first lane line equation of the position of the image acquisition device relative to the target lane line segment to obtain the first distance.
[0107] In one embodiment of the present disclosure, a lane line segment closest to the image acquisition device in the first lane line equation is selected and extended in the horizontal direction of the image acquisition device, and the first distance can be determined based on the equation of the lane line segment.
[0108] Figure 4Schematic diagram of the distance relationship between the lane line and the target vehicle in the driving image, wherein A is the image acquisition device on the target vehicle, L1 is the left lane line, Lr is the right lane line, D1 is the lower edge of the road image area 402, D2 is the extension line of the position of the image acquisition device on the driving image, d0 is the distance between D1 and D2, and is also the actual distance between the image acquisition device and the lane line. This distance is known and determined data when the image acquisition device is installed.
[0109] As an optional implementation, S102 may further include: obtaining the first intersection coordinates between the lane line and the lower edge of the lane line detection area, wherein the lane line detection area is the road image area 402 in the driving image; obtaining the second distance between the image acquisition device and the lower edge of the lane line detection area; determining the second intersection coordinates between the horizontal plane where the image acquisition device is located and the extension line based on the first intersection coordinates, the second distance and the first lane line equation; determining the first distance based on the second intersection coordinates.
[0110] In one embodiment of the present disclosure, the intersection coordinates of the lane line and the lower edge of the lane line detection area (i.e., the road image area 402) can be easily obtained based on the positional relationship in the driving image, and the intersection coordinates are converted to the world coordinate system to obtain the corresponding first intersection coordinates. The second distance is the distance between the image acquisition device and the lower edge of the lane line detection area. The distance is known data d0 and is determined based on the position where the image acquisition device is actually installed on the target vehicle. Knowing the first intersection coordinates, the second distance, and the first lane line equation, the actual intersection coordinates of the lane line and the horizontal plane where the image acquisition device is located in the world coordinate system can be determined, i.e., the second intersection coordinates; based on the second intersection coordinates, the distance between the image acquisition device and the extension line of the lane line, i.e., the first distance, can be determined.
[0111] For example, after obtaining the coordinates of the first intersection, the ordinate is added to the second distance to obtain the ordinate of the second intersection. Substituting it into the first lane line equation, the corresponding abscissa can be obtained. According to the value of the abscissa, the first distance can be obtained.
[0112] As an optional implementation manner, the first intersection coordinates include a first left intersection coordinate and a first right intersection coordinate, the first left intersection coordinate is the coordinate of the intersection between the left lane line and the lower edge of the lane line detection area, and the first right intersection coordinate is the coordinate of the intersection between the right lane line and the lower edge of the lane line detection area; the second intersection coordinates include a second left intersection coordinate and a second right intersection coordinate, the second left intersection coordinate is the coordinate of the intersection between the extension line of the left lane line and the horizontal plane where the image acquisition device is located, and the second right intersection coordinate is the coordinate of the intersection between the extension line of the right lane line and the horizontal plane where the image acquisition device is located; the first lane line equation includes a first left lane line equation representing the left lane line and a first right lane line equation representing the right lane line; the first distance includes a first left distance and a first right distance, the first left distance is used to characterize the distance of the image acquisition device relative to the extension line of the left lane line, and the first right distance is used to characterize the distance of the image acquisition device relative to the extension line of the right lane line.
[0113] For example, Figure 4 As shown, the lane line includes a left lane line L1 represented by a first left lane line equation and a right lane line Lr represented by a first right lane line equation, and the first intersection point coordinates include a first left intersection point coordinate (p1 x ,p1 y ) and the coordinates of the first right intersection point (p2 x ,p2 y ), the second intersection coordinates include the second left intersection coordinates (p1' x ,p1' y ) and the coordinates of the second right intersection point (p2' x ,p2' y ), the first distance includes a first left distance dl and a first right distance dr.
[0114] At this time, determining the coordinates of the second intersection between the horizontal plane where the image acquisition device is located and the extension line according to the first intersection coordinates, the second distance and the first lane line equation includes: determining the sum of the ordinate in the first left intersection coordinates and the second distance as the ordinate in the second left intersection coordinates, and substituting the ordinate in the second left intersection coordinates into the first left lane line equation to obtain the abscissa in the second left intersection coordinates; determining the sum of the ordinate in the first right intersection coordinates and the second distance as the ordinate in the second right intersection coordinates, and substituting the ordinate in the second right intersection coordinates into the first right lane line equation to obtain the abscissa in the second right intersection coordinates.
[0115] In one embodiment of the present disclosure, p1' y=p1 y +d0、p2' y =p2 y +d0, p1' y and p2' y Substitute the first left lane line equation and the first right lane line equation respectively to get p1' x and p2' x .
[0116] At this time, determining the first distance according to the second intersection coordinates includes: determining the first left distance according to the second left intersection coordinates; and determining the first right distance according to the second right intersection coordinates.
[0117] In one embodiment of the present disclosure, the position coordinates of the image acquisition device in the world coordinate system are known, and according to p1' x and p2' x In actual application, the width of the image acquisition device can be ignored, and the first distance is calculated with its center point as the reference point. At the same time, the threshold for determining whether there is a deviation also needs to be set accordingly with the center point of the image acquisition device as the reference point.
[0118] The existing assisted driving systems mainly include lane keeping assist systems, automatic parking assist systems, brake assist systems, reversing assist systems and driving assist systems. Among them, the lane keeping assist system is also called the lane departure warning system. The main function of the lane departure warning system is to actively send a warning alarm to the driver when the vehicle is about to or has deviated from the lane line in which it is located, which can greatly reduce the accident rate. Because the accuracy of obtaining the distance between the vehicle and the lane line in the existing technology is poor, it affects the effect of assisted driving, which is also reflected in affecting the accuracy of lane departure warning.
[0119] As an optional implementation, the method further includes: determining whether to perform a lane departure warning based on the first distance.
[0120] In one embodiment of the present disclosure, based on the first distance between the image acquisition device and the lane line, combined with known data such as the lane line width and the target vehicle width, it is possible to determine whether the target vehicle deviates from the lane line and whether a lane departure warning is required. The lane departure warning includes two situations: an alarm for having deviated from the lane and a reminder for a tendency to deviate from the lane.
[0121] As an optional embodiment, the first distance includes a first left distance and a first right distance, the first left distance is used to characterize the distance of the image acquisition device relative to the extension line of the left lane line, and the first right distance is used to characterize the distance of the image acquisition device relative to the extension line of the right lane line.
[0122] In one embodiment of the present disclosure, as Figure 4 shown, the first distance includes a first left distance dl and a first right distance dr. The first left distance dl represents the distance of the image acquisition device A relative to the left lane line Ll, and the first right distance dr represents the distance of the image acquisition device A relative to the right lane line Lr.
[0123] At this time, determining whether to perform a lane departure warning according to the first distance may further include: if one of the first left distance and the first right distance is greater than a first preset distance threshold and the other is less than a second preset distance threshold, generating a first lane departure warning message, where the first lane departure warning message is used to prompt that the target vehicle deviates in the direction corresponding to the other.
[0124] In one embodiment of the present disclosure, the first preset distance threshold T1 and the second preset distance threshold T2 are determined according to the lane line width, the target vehicle width, the deviation degree limit, etc. Among them, T1 is the critical value for left deviation, and T2 is the critical value for right deviation. If dl > T1 and dr < T2, a first lane departure warning message is generated to perform a lane departure alarm, where the first lane departure warning message is used to indicate that the target vehicle has deviated to the right; if dr > T1 and dl < T2, a first lane departure warning message is generated to perform a lane departure alarm, where the first lane departure warning message is used to indicate that the target vehicle has deviated to the left.
[0125] As an alternative implementation, determining whether to perform a lane departure warning according to the first distance may further include: determining lane departure curvature information corresponding to multiple moments according to the first distance corresponding to the current driving image and the first distance corresponding to each frame of historical driving image in multiple consecutive frames of historical driving images before the current driving image; determining whether to perform a lane departure warning according to the lane departure curvature information.
[0126] In one embodiment of the present disclosure, the image acquisition device can acquire multiple frames of driving images, including the current driving image and multiple frames of historical driving images. According to the above method, the first distance corresponding to multiple moments can be obtained. Given the time and distance, it is easy to know the lane departure curvature corresponding to each moment. According to the lane departure curvature information, it can be determined whether the target vehicle deviates from the lane line and whether a lane departure warning needs to be performed.
[0127] For example, N first distances d corresponding to N frames of images are obtained and stored in array D, where D[0] indicates that it stores the first distance d corresponding to the frame of N consecutive images that is farthest from the current image in terms of time, and D[N] indicates that it stores the first distance d corresponding to the frame of N consecutive images that is closest to the current image in terms of time. Two consecutive frames of images are grouped together, and the average first distance of each group is calculated to improve data accuracy.
[0128] In one embodiment, the selected images are non-repetitive, for example, the images corresponding to sequence number 0 and sequence number 1 are a group, and the images corresponding to sequence number 2 and sequence number 3 are a group, which can be expressed by the following relationship: m[j] = (D[i] + D[i+1]) / 2, i = 0, 2, 4...N-2; j = 0, 1, 2...N / 2-1; In another embodiment, the selected images are repeatable, for example, the images corresponding to sequence number 0 and sequence number 1 are a group, and the images corresponding to sequence number 1 and sequence number 2 are a group, which can be expressed by the following relationship: m[j] = (D[i] + D[i+1]) / 2, i = 0, 1, 2...N-1; j = 0, 1, 2...N-1; In other embodiments, the number of images in each group can also be determined according to the number of frames of driving images actually acquired; In the above embodiment, i is the sequence number of the image in array D, j is the number of groups, and m[j] represents the first distance average value of the jth group.
[0129] The corresponding lane departure curvature v[t] at each time t is: v[t]=m[j+1]-m[j], where t and j have the same value range.
[0130] As an optional implementation, the first distance includes a first left distance and a first right distance, the first left distance is used to characterize the distance of the image acquisition device relative to the extension line of the left lane line, and the first right distance is used to characterize the distance of the image acquisition device relative to the extension line of the right lane line; the lane departure curvature information includes left departure curvature information and right departure curvature information, wherein the left departure curvature information is determined based on the first left distance corresponding to the current driving image and the first left distance corresponding to each frame of the historical driving image, and the right departure curvature information is determined based on the first right distance corresponding to the current driving image and the first right distance corresponding to each frame of the historical driving image.
[0131] In one embodiment of the present disclosure, Figure 4As shown, the first distance includes a first left distance dl and a first right distance dr, the first left distance dl represents the distance of the image acquisition device A relative to the left lane line Ll, and the first left distance average ml[j] is: ml[j]=(Dl[i]+Dl[i+1]) / 2, the first right distance dr represents the distance of the image acquisition device A relative to the right lane line Lr, and the first right distance average mr[j] is: mr[j]=(Dr[i]+Dr[i+1]) / 2; the lane departure curvature v[t] includes a left departure curvature vl[t] and a right departure curvature vr[t], wherein the left departure curvature vl[t] is determined based on multiple first left distances dl corresponding to multiple frames of driving images, vl[t]=ml[j+1]-ml[j], and the right departure curvature vr[t] is determined based on multiple first right distances dr corresponding to multiple frames of driving images, vr[t]=mr[j+1]-mr[j].
[0132] As an optional implementation, determining whether to perform a lane departure warning based on the lane departure curvature information includes: if the left departure curvature information is greater than a preset departure curvature threshold, generating second lane departure warning information, and the second lane departure warning information is used to prompt the target vehicle to deviate to the left; if the right departure curvature information is greater than the departure curvature threshold, generating third lane departure warning information, and the third lane departure warning information is used to prompt the target vehicle to deviate to the right.
[0133] In one embodiment of the present disclosure, a deviation curvature threshold Th is set according to the speed of the target vehicle, the coefficient of the first lane line equation, and other data. If vl[t]>Th, a second lane departure warning message is generated and a lane departure alarm is performed, wherein the second lane departure warning message is used to indicate that the target vehicle deviates to the left; if vr[t]>Th, a third lane departure warning message is generated and a lane departure alarm is performed, wherein the third lane departure warning message is used to indicate that the target vehicle deviates to the right.
[0134] As an optional implementation, determining whether to perform a lane departure warning based on the lane departure curvature information includes: if one of the left departure curvature information and the right departure curvature information corresponding to the same moment is negative and the other is positive, then generating fourth lane departure warning information, and the fourth lane departure warning information is used to prompt the target vehicle that there is a tendency for the target vehicle to deviate in the direction corresponding to the other lane departure curvature information.
[0135] In one embodiment of the present disclosure, if at a certain time t, vl[t]>0 and vr[t]<0, a fourth lane departure warning message is generated, and a lane departure reminder is given. The fourth lane departure warning message is used to prompt that the target vehicle has a tendency to deviate to the left; if at a certain time t, vl[t]<0 and vr[t]>0, a fourth lane departure warning message is generated, and a lane departure reminder is given. The fourth lane departure warning message is used to prompt that the target vehicle has a tendency to deviate to the right. Taking advance warning of lane line deviation reduces the possibility of traffic accidents and reduces the loss of manpower and material resources.
[0136] As an optional implementation, determining whether to perform a lane departure warning based on the lane departure curvature information further includes: determining left departure rate information based on the left departure curvature information; determining right departure rate information based on the right departure curvature information; wherein the fourth lane departure warning information is also used to prompt the deviation rate information corresponding to the other one.
[0137] In one embodiment of the present disclosure, the deviation rate information of the target vehicle may also be determined according to the lane deviation curvature information.
[0138] For example, the left deviation rate mvl is calculated according to the following formula: The right deviation rate mvr is calculated according to the following formula: The fourth lane departure warning information is also used to prompt the target vehicle to deviate to the left or right at a rate of mvl or mvr at time t.
[0139] As an optional implementation, determining whether to perform a lane departure warning based on the lane departure curvature information further includes: determining left departure rate information based on the left departure curvature information; determining right departure rate information based on the right departure curvature information; if one of the left departure curvature information and the right departure curvature information corresponding to the same moment is negative and the other is positive, then determining the time information required for the target vehicle to travel to the warning critical line in the direction corresponding to the other one based on the deviation rate information corresponding to the other one, wherein the fourth lane departure warning information is also used to prompt the time information.
[0140] In one embodiment of the present disclosure, the time when the target vehicle travels to the warning critical line can also be determined based on the lane departure curvature information.
[0141] For example, the left deviation rate mvl is calculated according to the following formula: The right deviation rate mvr is calculated according to the following formula: The time tl when the target vehicle travels to the left warning critical line is: tl = (dl-dlT) / mvl, dlT is the distance from the center line of the lane to the left warning critical line; the time tr when the target vehicle travels to the right warning critical line is: tr = (dr-drT) / mvr, drT is the distance from the center line of the lane to the right warning critical line.
[0142] If at a certain time t, vl[t]>0 and vr[t]<0, the fourth lane departure warning information is generated and a lane departure reminder is given. The fourth lane departure warning information is used to prompt the target vehicle that it has a tendency to deviate to the left and will travel to the left warning critical line after tl time; if at a certain time t, vl[t]<0 and vr[t]>0, the fourth lane departure warning information is generated and a lane departure reminder is given. The fourth lane departure warning information is used to prompt the target vehicle that it has a tendency to deviate to the right and will travel to the right warning critical line after tr time.
[0143] Figure 5 This is a functional module diagram of a driving assistance device provided by an embodiment of the present disclosure. Figure 5 As shown, the auxiliary driving device 200 may include a lane line determination module 201 and a first distance determination module 202 .
[0144] The lane line determination module 201 is used to identify the current driving image of the target vehicle and determine at least one lane line of the lane where the target vehicle is located in the current driving image, wherein the driving image is captured by an image acquisition device;
[0145] The first distance determination module 202 is used to determine a first distance between the image acquisition device and the extension line of the lane line.
[0146] Optionally, the lane line determination module 201 includes:
[0147] A lane line feature point determination submodule is used to identify the current driving image of the target vehicle and determine the lane line feature points of the lane where the target vehicle is located in the current driving image;
[0148] The first lane line equation determination submodule is used to determine the first lane line equation of the lane line in the world coordinate system according to the lane line feature points, and then obtain the extension line.
[0149] Optionally, the first distance determining module 202 includes:
[0150] The first distance determination submodule is used to determine the horizontal distance of the position of the image acquisition device relative to the first lane line equation to obtain the first distance.
[0151] Optionally, the first lane line equation determination submodule includes:
[0152] A second lane line equation acquisition submodule, used for fitting the lane line feature points to obtain a second lane line equation of the lane line in a pixel coordinate system;
[0153] The first coordinate system conversion submodule is used to convert the second lane line equation into the world coordinate system to obtain the first lane line equation.
[0154] Optionally, the second lane line equation acquisition submodule includes:
[0155] A segmented fitting submodule, used for performing segmented fitting on the lane line feature points to obtain a second lane line equation of a preset number of lane line segments of the lane line in the pixel coordinate system;
[0156] The first coordinate system conversion submodule includes:
[0157] The second coordinate system conversion submodule is used to convert the second lane line equation of each lane line segment in the pixel coordinate system into the world coordinate system to obtain the first lane line equation of each lane line segment.
[0158] Optionally, the first distance determining module 202 includes:
[0159] A target lane line segment determination submodule, used to determine the target lane line segment that is closest to the position of the image acquisition device in the horizontal direction;
[0160] The second distance determination submodule is used to determine the horizontal distance of the position of the image acquisition device relative to the first lane line equation of the target lane line segment to obtain the first distance.
[0161] Optionally, the first distance determining module 202 includes:
[0162] A first intersection coordinate acquisition submodule, used to acquire the coordinates of a first intersection between the lane line and a lower edge of a lane line detection area, wherein the lane line detection area is a road image area in the driving image;
[0163] A distance acquisition submodule, used to acquire a second distance between the image acquisition device and the lower edge of the lane detection area;
[0164] A second intersection coordinate acquisition submodule, used to determine the coordinates of a second intersection between the horizontal plane where the image acquisition device is located and the extension line according to the first intersection coordinates, the second distance and the first lane line equation;
[0165] The third distance determination submodule is used to determine the first distance according to the coordinates of the second intersection point.
[0166] Optionally, the first intersection point coordinates include a first left intersection point coordinate and a first right intersection point coordinate, the first left intersection point coordinate is the coordinate of the intersection between the left lane line and the lower edge of the lane line detection area, and the first right intersection point coordinate is the coordinate of the intersection between the right lane line and the lower edge of the lane line detection area;
[0167] The second intersection coordinates include a second left intersection coordinate and a second right intersection coordinate, the second left intersection coordinate being the coordinate of the intersection between the extension line of the left lane line and the horizontal plane where the image acquisition device is located, and the second right intersection coordinate being the coordinate of the intersection between the extension line of the right lane line and the horizontal plane where the image acquisition device is located;
[0168] The first lane line equation includes a first left lane line equation representing the left lane line and a first right lane line equation representing the right lane line;
[0169] The first distance includes a first left distance and a first right distance, the first left distance is used to represent the distance of the image acquisition device relative to the extension line of the left lane line, and the first right distance is used to represent the distance of the image acquisition device relative to the extension line of the right lane line;
[0170] The second intersection coordinate acquisition submodule includes:
[0171] a left intersection point coordinate acquisition submodule, configured to determine the sum of the ordinate in the first left intersection point coordinate and the second distance as the ordinate in the second left intersection point coordinate, and substitute the ordinate in the second left intersection point coordinate into the first left lane line equation to obtain the abscissa in the second left intersection point coordinate;
[0172] a right intersection point coordinate acquisition submodule, configured to determine the sum of the ordinate in the first right intersection point coordinate and the second distance as the ordinate in the second right intersection point coordinate, and substitute the ordinate in the second right intersection point coordinate into the first right lane line equation to obtain the abscissa in the second right intersection point coordinate;
[0173] The third distance determination submodule includes:
[0174] A left distance acquisition submodule, used to determine the first left distance according to the coordinates of the second left intersection point;
[0175] The right side distance acquisition submodule is used to determine the first right side distance according to the coordinates of the second right intersection point.
[0176] Optionally, the driving assistance device 200 further includes:
[0177] The departure warning module is used to determine whether to perform a lane departure warning according to the first distance.
[0178] Optionally, the first distance includes a first left distance and a first right distance, the first left distance is used to represent the distance of the image acquisition device relative to the extension line of the left lane line, and the first right distance is used to represent the distance of the image acquisition device relative to the extension line of the right lane line;
[0179] The deviation warning module comprises:
[0180] The first warning submodule is used to generate a first lane departure warning message if one of the first left distance and the first right distance is greater than a first preset distance threshold and the other is less than a second preset distance threshold, wherein the first lane departure warning message is used to prompt the target vehicle to deviate to a direction corresponding to the other.
[0181] Optionally, the deviation warning module includes:
[0182] a lane departure curvature information acquisition submodule, configured to determine lane departure curvature information corresponding to a plurality of moments according to the first distance corresponding to the current driving image and the first distance corresponding to each frame of a plurality of consecutive frames of historical driving images before the current driving image;
[0183] The second warning submodule is used to determine whether to perform a lane departure warning according to the lane departure curvature information.
[0184] Optionally, the second early warning submodule includes:
[0185] a first lane departure warning information generating submodule, configured to generate second lane departure warning information if there is left departure curvature information greater than a preset departure curvature threshold, wherein the second lane departure warning information is used to prompt the target vehicle to deviate to the left;
[0186] The third warning submodule is used to generate third lane departure warning information if there is the right departure curvature information greater than the departure curvature threshold, and the third lane departure warning information is used to prompt the target vehicle to deviate to the right.
[0187] Optionally, the second early warning submodule further includes:
[0188] The second lane departure warning information generating submodule is used to generate fourth lane departure warning information if one of the left departure curvature information and the right departure curvature information corresponding to the same moment is negative and the other is positive. The fourth lane departure warning information is used to prompt the target vehicle that there is a tendency for the target vehicle to deviate to the direction corresponding to the other lane departure curvature information.
[0189] Optionally, the second early warning submodule further includes:
[0190] A left deviation rate information determination submodule, used to determine left deviation rate information according to the left deviation curvature information;
[0191] a right deviation rate information determination submodule, configured to determine right deviation rate information according to the right deviation curvature information;
[0192] The fourth lane departure warning information is also used to prompt the deviation rate information corresponding to the other lane.
[0193] Optionally, the second early warning submodule further includes:
[0194] A left deviation rate information determination submodule, used to determine left deviation rate information according to the left deviation curvature information;
[0195] a right deviation rate information determination submodule, configured to determine right deviation rate information according to the right deviation curvature information;
[0196] The second lane departure warning information generating submodule is also used to determine the time information required for the target vehicle to travel to the warning critical line in the direction corresponding to the other lane departure curvature information and the right departure curvature information if one of the left departure curvature information and the right departure curvature information corresponding to the same moment is negative and the other is positive, based on the deviation rate information corresponding to the other lane departure curvature information, wherein the fourth lane departure warning information is also used to prompt the time information.
[0197] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.
[0198] It is not difficult to find from the above description that the present embodiment identifies the lane line in the driving image and determines the first distance between the extension line of the lane line and the image acquisition device provided on the vehicle. The distance can eliminate the error caused by the installation position and angle of the image acquisition device, so that the distance judgment between the target vehicle and the lane line is more accurate, thereby improving the accuracy of assisted driving; further, by determining the first lane line equation, the actual and accurate relative position relationship between the target vehicle and the lane line of the lane where the vehicle is located is reflected, and according to the first distance, the deviation rate of the target vehicle, the time to reach the pre-alarm critical line and other information can also be obtained, so that deviation warning can be carried out and vehicles with deviation trends can be reminded in advance, thereby reducing the possibility of accidents.
[0199] Figure 6 FIG. 1 is a schematic diagram of the structure of an electronic device involved in an embodiment of the present disclosure. Figure 6 As shown, the electronic device 300 may include: a processor 301, a memory 302. The electronic device 300 may also include one or more of a multimedia component 303, an input / output (I / O) interface 304, and a communication component 305. For example, the electronic device may be a vehicle.
[0200] The processor 301 is used to control the overall operation of the electronic device 300 to complete all or part of the steps in the above-mentioned assisted driving method. The memory 302 is used to store various types of data to support the operation of the electronic device 300, and these data may include, for example, instructions for any application or method used to operate on the electronic device 300, and application-related data, such as contact data, sent and received messages, pictures, audio, video, etc. The memory 302 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (Static Random Access Memory, referred to as SRAM), electrically erasable programmable read-only memory (Electrically Erasable Programmable Read-Only Memory, referred to as EEPROM), erasable programmable read-only memory (Erasable Programmable Read-Only Memory, referred to as EPROM), programmable read-only memory (Programmable Read-Only Memory, referred to as PROM), read-only memory (Read-Only Memory, referred to as ROM), magnetic memory, flash memory, magnetic disk or optical disk. The multimedia component 303 may include a screen and an audio component. The screen may be, for example, a touch screen, and the audio component is used to output and / or input audio signals. For example, the audio component may include a microphone for receiving external audio signals. The received audio signal may be further stored in the memory 302 or sent through the communication component 305. The audio component also includes at least one speaker for outputting audio signals. The I / O interface 304 provides an interface between the processor 301 and other interface modules, and the other interface modules may be keyboards, mice, buttons, etc. These buttons may be virtual buttons or physical buttons. The communication component 305 is used for wired or wireless communication between the electronic device 300 and other devices. Wireless communication, such as Wi-Fi, Bluetooth, Near Field Communication (NFC), 2G, 3G, 4G, NB-IOT, eMTC, or other 5G, etc., or a combination of one or more of them, is not limited here. Therefore, the corresponding communication component 305 may include: Wi-Fi module, Bluetooth module, NFC module, etc.
[0201] In some embodiments, the electronic device 300 can be implemented by one or more application specific integrated circuits (ASIC), digital signal processors (DSP), digital signal processing devices (DSPD), programmable logic devices (PLD), field programmable gate arrays (FPGA), controllers, microcontrollers, microprocessors or other electronic components to execute the above-mentioned assisted driving method.
[0202] In addition, in one embodiment, the embodiment of the present disclosure further provides a computer-readable storage medium including program instructions, and when the program instructions are executed by the processor, the steps of the above-mentioned assisted driving method are implemented. For example, the computer-readable storage medium can be the above-mentioned memory 302 including program instructions, and the above-mentioned program instructions can be executed by the processor 301 of the electronic device 300 to complete the above-mentioned assisted driving method.
[0203] In addition, in one embodiment, an embodiment of the present disclosure also provides a computer program product, which is a computer program that can be executed by a programmable device, and the computer program has a code portion for executing the above-mentioned assisted driving method when executed by the programmable device.
[0204] The preferred embodiments of the present disclosure are described in detail above in conjunction with the accompanying drawings; however, the present disclosure is not limited to the specific details in the above embodiments. Within the technical concept of the present disclosure, a variety of simple modifications can be made to the technical solution of the present disclosure, and these simple modifications all fall within the protection scope of the present disclosure.
[0205] It should also be noted that the various specific technical features described in the above specific embodiments can be combined in any suitable manner without contradiction. In order to avoid unnecessary repetition, the present disclosure will not further describe various possible combinations.
[0206] In addition, various embodiments of the present disclosure may be arbitrarily combined, and as long as they do not violate the concept of the present disclosure, they should also be regarded as the contents disclosed by the present disclosure.
Claims
1. A driving assistance method, characterized in that: include: Identify a current driving image of a target vehicle and determine at least one lane line of a lane where the target vehicle is located in the current driving image; wherein the driving image is captured by an image acquisition device; Determine a first distance of the image acquisition device relative to an extension line of the lane line.
2. The assisted driving method according to claim 1, characterized in that: The step of identifying a current driving image of the target vehicle and determining at least one lane line of a lane where the target vehicle is located in the current driving image includes: Identify the current driving image of the target vehicle and determine the lane line feature points of the lane where the target vehicle is located in the current driving image; According to the lane line feature points, a first lane line equation of the lane line in a world coordinate system is determined, and then the extension line is obtained.
3. The assisted driving method according to claim 2, characterized in that: The determining a first distance of the image acquisition device relative to an extension line of the lane line comprises: Determine a horizontal distance of a position of the image acquisition device relative to the first lane line equation to obtain the first distance.
4. The assisted driving method according to claim 2, characterized in that: Determining a first lane line equation of the lane line in a world coordinate system according to the lane line feature point includes: Fitting the lane line feature points to obtain a second lane line equation of the lane line in a pixel coordinate system; The second lane line equation is converted into the world coordinate system to obtain the first lane line equation.
5. The assisted driving method according to claim 4, characterized in that: The fitting of the lane line feature points to obtain a second lane line equation of the lane line in a pixel coordinate system includes: Performing segmented fitting on the lane line feature points to obtain a second lane line equation of a preset number of lane line segments of the lane line in the pixel coordinate system; The converting the second lane line equation into the world coordinate system to obtain the first lane line equation includes: The second lane line equation of each lane line segment in the pixel coordinate system is converted into the world coordinate system to obtain the first lane line equation of each lane line segment.
6. The assisted driving method according to claim 5, characterized in that: The step of determining a horizontal distance of a position of the image acquisition device relative to the first lane line equation to obtain the first distance includes: Determine the target lane line segment that is closest to the position of the image acquisition device in the horizontal direction; Determine a horizontal distance of the position of the image acquisition device relative to the first lane line equation of the target lane line segment to obtain the first distance.
7. The assisted driving method according to any one of claims 1 to 6, characterized in that: The determining a first distance of the image acquisition device relative to the extension line of the lane line includes: Acquire the coordinates of a first intersection point between the lane line and a lower edge of a lane line detection area, wherein the lane line detection area is a road image area in the driving image; Acquire a second distance between the image acquisition device and a lower edge of the lane detection area; Determine the coordinates of a second intersection between the horizontal plane where the image acquisition device is located and the extension line according to the first intersection coordinates, the second distance and the first lane line equation; The first distance is determined according to the coordinates of the second intersection point.
8. The assisted driving method according to claim 7, characterized in that: The first intersection coordinates include a first left intersection coordinate and a first right intersection coordinate, the first left intersection coordinate is the coordinate of the intersection between the left lane line and the lower edge of the lane line detection area, and the first right intersection coordinate is the coordinate of the intersection between the right lane line and the lower edge of the lane line detection area; The second intersection coordinates include a second left intersection coordinate and a second right intersection coordinate, the second left intersection coordinate being the coordinate of the intersection between the extension line of the left lane line and the horizontal plane where the image acquisition device is located, and the second right intersection coordinate being the coordinate of the intersection between the extension line of the right lane line and the horizontal plane where the image acquisition device is located; The first lane line equation includes a first left lane line equation representing the left lane line and a first right lane line equation representing the right lane line; The first distance includes a first left distance and a first right distance, the first left distance is used to represent the distance of the image acquisition device relative to the extension line of the left lane line, and the first right distance is used to represent the distance of the image acquisition device relative to the extension line of the right lane line; The step of determining the coordinates of a second intersection between the horizontal plane where the image acquisition device is located and the extension line according to the first intersection coordinates, the second distance, and the first lane line equation includes: Determine the sum of the ordinate in the first left intersection coordinate and the second distance as the ordinate in the second left intersection coordinate, and substitute the ordinate in the second left intersection coordinate into the first left lane line equation to obtain the abscissa in the second left intersection coordinate; Determine the sum of the ordinate in the first right intersection coordinate and the second distance as the ordinate in the second right intersection coordinate, and substitute the ordinate in the second right intersection coordinate into the first right lane line equation to obtain the abscissa in the second right intersection coordinate; The determining the first distance according to the second intersection coordinates includes: Determine the first left side distance according to the coordinates of the second left intersection point; The first right side distance is determined according to the second right intersection point coordinates.
9. The assisted driving method according to claim 1, characterized in that: The method further comprises: Determine whether to perform a lane departure warning according to the first distance.
10. The assisted driving method according to claim 9, characterized in that: The first distance includes a first left distance and a first right distance, the first left distance is used to represent the distance of the image acquisition device relative to the extension line of the left lane line, and the first right distance is used to represent the distance of the image acquisition device relative to the extension line of the right lane line; The determining whether to perform a lane departure warning according to the first distance includes: If one of the first left distance and the first right distance is greater than a first preset distance threshold and the other is less than a second preset distance threshold, a first lane departure warning message is generated, and the first lane departure warning message is used to prompt the target vehicle to deviate to a direction corresponding to the other.
11. The assisted driving method according to claim 10, characterized in that: The determining whether to perform a lane departure warning according to the first distance includes: Determine lane departure curvature information corresponding to a plurality of moments according to the first distance corresponding to the current driving image and the first distance corresponding to each frame of a plurality of consecutive frames of historical driving images before the current driving image; Whether to perform a lane departure warning is determined according to the lane departure curvature information.
12. The assisted driving method according to claim 11, characterized in that: The first distance includes a first left distance and a first right distance, the first left distance is used to represent the distance of the image acquisition device relative to the extension line of the left lane line, and the first right distance is used to represent the distance of the image acquisition device relative to the extension line of the right lane line; The lane departure curvature information includes left departure curvature information and right departure curvature information, wherein the left departure curvature information is determined based on the first left side distance corresponding to the current driving image and the first left side distance corresponding to each frame of the historical driving image, and the right departure curvature information is determined based on the first right side distance corresponding to the current driving image and the first right side distance corresponding to each frame of the historical driving image.
13. The assisted driving method according to claim 12, characterized in that: The determining whether to perform a lane departure warning according to the lane departure curvature information includes: If there is left deviation curvature information greater than a preset deviation curvature threshold, second lane departure warning information is generated, where the second lane departure warning information is used to prompt the target vehicle to deviate to the left; If the right departure curvature information is greater than the departure curvature threshold, third lane departure warning information is generated, and the third lane departure warning information is used to prompt the target vehicle to deviate to the right.
14. The assisted driving method according to claim 12, characterized in that: The determining whether to perform a lane departure warning according to the lane departure curvature information includes: If one of the left departure curvature information and the right departure curvature information corresponding to the same moment is negative and the other is positive, a fourth lane departure warning information is generated, and the fourth lane departure warning information is used to prompt that the target vehicle has a tendency to deviate to the direction corresponding to the other lane departure curvature information.
15. The assisted driving method according to claim 14, characterized in that: The determining whether to perform a lane departure warning according to the lane departure curvature information further includes: Determining left deviation rate information according to the left deviation curvature information; Determining right deviation rate information according to the right deviation curvature information; The fourth lane departure warning information is also used to prompt the deviation rate information corresponding to the other lane.
16. The assisted driving method according to claim 14, characterized in that: The determining whether to perform a lane departure warning according to the lane departure curvature information further includes: Determining left deviation rate information according to the left deviation curvature information; Determining right deviation rate information according to the right deviation curvature information; If one of the left departure curvature information and the right departure curvature information corresponding to the same moment is negative and the other is positive, then the time information required for the target vehicle to travel to the alarm critical line in the direction corresponding to the other is determined according to the deviation rate information corresponding to the other, wherein the fourth lane departure warning information is also used to prompt the time information.
17. A driving assistance device, characterized in that: include: A lane line determination module, used to identify a current driving image of a target vehicle and determine at least one lane line of a lane where the target vehicle is located in the current driving image, wherein the driving image is captured by an image acquisition device; The first distance determination module is used to determine a first distance between the image acquisition device and the extension line of the lane line.
18. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the steps of the method described in any one of claims 1 to 16 are implemented.
19. An electronic device, characterized in that: include: a memory having a computer program stored thereon; A processor, configured to execute the computer program in the memory to implement the steps of the method according to any one of claims 1 to 16.
Citation Information
Cited By
Road traffic behavior anomaly detection method and system based on computer vision
CN119636790A
Method and System for Abnormal Detection of Road Traffic Behaviors Based on Computer Vision
CN119636790B
