Method and device for camera calibration, electronic equipment, storage medium and program product

Through piecewise fitting and Bezier curve fitting technology, the camera extrinsic parameters are updated in real time, which solves the problem of low accuracy and efficiency of traditional camera calibration in complex lane scenes, and achieves efficient and accurate camera extrinsic parameter calibration.

CN118570304APending Publication Date: 2024-08-30RUILIAN XINGCHEN (BEIJING) TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310162340.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-02-23
Publication Date
2024-08-30

AI Technical Summary

Technical Problem

Traditional camera calibration methods are difficult to obtain accurate camera extrinsic parameters in real time in complex lane scenes, resulting in low calibration accuracy and efficiency. Especially in curves, ramps and other scenes when the shape of the lane line is complex, it cannot effectively correct the changes in extrinsic parameters.

Method used

By obtaining multiple sets of points on the lane line, perform segmented fitting to generate fitting results corresponding to multiple distance ranges, and update the camera's external parameters based on these results, using Bezier curve fitting and Gauss-Newton method iteration Adjust external parameters to improve accuracy.

Benefits of technology

It improves the efficiency and accuracy of camera calibration without relying on benchmark data, can update camera external parameters in real time, is suitable for complex lane scenes, and improves the applicability and accuracy of camera calibration.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118570304A
    Figure CN118570304A
Patent Text Reader

Abstract

According to the embodiment of the invention, a camera calibration method and device, electronic equipment, a storage medium and a computer program product are provided. The method includes: acquiring a first set of points corresponding to a first lane line and a second set of points corresponding to a second lane line based on an image captured by a camera onboard a vehicle, the first lane line being determined to be associated with the second lane line; generating a first group of segmentation fitting results corresponding to the plurality of distance ranges for the first lane line based on the distance from the first group of points to the vehicle; and updating the external parameters of the camera based on the fitting result of the second group of points and the first group of segments. Based on the above mode, the embodiment of the invention can update the external parameters of the camera in real time, and improves the accuracy of the camera calibration result and the calibration efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] Example embodiments of the present disclosure generally relate to the field of computers, and more particularly to methods, apparatuses, electronic devices, computer storage media, and computer program products for camera calibration. Background Art

[0002] In recent years, various sensors have been applied in the automotive field. For example, sensors installed on the vehicle are used to sense the environment around the vehicle. These sensors may include single / binocular cameras, cameras, laser radars, etc. In order to improve the accuracy of the camera in acquiring environmental data, it is often necessary to calibrate the camera to determine the camera's external parameters (also called external parameters) or internal parameters (also called internal parameters). Summary of the invention

[0003] In a first aspect of the present disclosure, a method for camera calibration is provided. The method comprises: based on an image captured by a camera mounted on a vehicle, obtaining a first set of points corresponding to a first lane line and a second set of points corresponding to a second lane line, the first lane line being determined to be associated with the second lane line; based on the distance from the first set of points to the vehicle, generating a first set of segmented fitting results corresponding to a plurality of distance ranges for the first lane line; and updating the external parameters of the camera based on the second set of points and the first set of segmented fitting results.

[0004] In a second aspect of the present disclosure, a device for camera calibration is provided. The device includes: an acquisition module configured to acquire a first group of points corresponding to a first lane line and a second group of points corresponding to a second lane line based on an image captured by a camera mounted on a vehicle, the first lane line being determined to be associated with the second lane line; a fitting result generation module configured to generate a first group of segmented fitting results corresponding to a plurality of distance ranges for the first lane line based on the distance from the first group of points to the vehicle; and an extrinsic parameter update module configured to update the extrinsic parameters of the camera based on the second group of points and the first group of segmented fitting results.

[0005] In a third aspect of the present disclosure, an electronic device is provided, comprising: a memory and a processor; wherein the memory is used to store one or more computer instructions, wherein the one or more computer instructions are executed by the processor to implement the method according to the first aspect of the present disclosure.

[0006] In a fourth aspect of the present disclosure, a computer-readable storage medium is provided, on which one or more computer instructions are stored, wherein the one or more computer instructions are executed by a processor to implement the method according to the first aspect of the present disclosure.

[0007] In a fifth aspect of the present disclosure, a computer program product is provided, comprising computer executable instructions, wherein the computer executable instructions implement the method according to the first aspect of the present disclosure when executed by a processor.

[0008] According to various embodiments of the present disclosure, the embodiments of the present disclosure can perform segmented fitting according to the lane line data obtained by the camera, and perform external parameter calibration of the camera based on the results of the segmented fitting, thereby not relying on benchmark data and improving the efficiency of calibration. BRIEF DESCRIPTION OF THE DRAWINGS

[0009] The above and other features, advantages and aspects of the embodiments of the present disclosure will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. In the accompanying drawings, the same or similar reference numerals represent the same or similar elements, wherein:

[0010] Figure 1 A schematic diagram showing an example environment in which embodiments according to the present disclosure may be implemented;

[0011] Figure 2 An example block diagram of a camera calibration system according to some embodiments of the present disclosure is shown;

[0012] Figure 3 A schematic diagram showing multiple groups of sampling points for multiple distance ranges according to some embodiments of the present disclosure;

[0013] Figure 4 shows an example block diagram of cross-fit error calculation according to some embodiments of the present disclosure;

[0014] Figure 5 A flowchart showing an example process for camera calibration according to some embodiments of the present disclosure is shown;

[0015] Figure 6 A schematic structural block diagram of an apparatus for camera calibration according to some embodiments of the present disclosure is shown; and

[0016] Figure 7 A block diagram of an electronic device capable of implementing various embodiments of the present disclosure is shown. DETAILED DESCRIPTION

[0017] Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although certain embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as being limited to the embodiments described herein, which are instead provided for a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes and are not intended to limit the scope of protection of the present disclosure.

[0018] In the description of the embodiments of the present disclosure, the term "including" and similar terms should be understood as open inclusion, that is, "including but not limited to". The term "based on" should be understood as "based at least in part on". The term "one embodiment" or "the embodiment" should be understood as "at least one embodiment". The terms "first", "second", etc. may refer to different or the same objects. Other explicit and implicit definitions may also be included below.

[0019] For the convenience of description, several concepts and terms are first defined here.

[0020] As used herein, the term "camera calibration" (also called camera calibration) refers to the mapping of the world coordinate system to the image coordinate system, that is, the process of solving the camera parameters. In order to determine the relationship between the three-dimensional geometric position of a point on the surface of a spatial object and its corresponding point in the image, it is necessary to establish a geometric model of camera imaging. Such geometric model parameters such as intrinsic parameters, extrinsic parameters, and distortion parameters can be called camera parameters.

[0021] As used herein, the term "extrinsic parameter" describes the transformation from the world coordinate system to the camera coordinate system. In other words, the extrinsic parameter matrix describes the point in the world coordinate system, which is transformed into the point in the camera coordinate system after translation and rotation transformation. The extrinsic parameter matrix is ​​described by the rotation matrix R and the translation matrix t, where R and t are the extrinsic parameters of the camera. The extrinsic parameters will change as the camera moves.

[0022] As used herein, the term "vehicle coordinate system" (also referred to as vehicle body coordinate system) is used to describe the relative positional relationship between objects around the vehicle (e.g., lane lines) and the vehicle. The y-axis of the vehicle coordinate system points in the direction of vehicle travel, while the x-axis points perpendicular to the direction of vehicle travel, and the plane in which the x-axis and the y-axis are located is parallel to the ground.

[0023] As used herein, the term "pitch angle" (also called pitch angle) generally refers to the rotation angle of an object around the x-axis. The "pitch angle" is a commonly used external parameter of a camera, which is used to indicate the angle of the camera in the vertical direction.

[0024] As used herein, the term "Bezier curve" is a mathematical curve applied to two-dimensional graphics applications, which consists of line segments and nodes. A Bezier curve is a method of describing a curve using two-dimensional straight lines. "Bezier curve fitting" is a fitting method that uses a curve to fit multiple straight line segments.

[0025] As used in this article, the term "Gauss-Newton method" is an iterative method for least squares of regression parameters in a nonlinear regression model. This method uses Taylor series expansion to approximately replace the nonlinear regression model, and then through multiple iterations and multiple corrections of the regression coefficients, the regression coefficients are continuously approached to the optimal regression coefficients of the nonlinear regression model, and finally the residual sum of squares of the original model is minimized.

[0026] As used herein, the term "vanishing point" refers to a point in perspective projection where the projections of a bunch of parallel lines parallel to the projection plane can remain parallel, while the projections of parallel lines not parallel to the projection plane can converge to a point, which is called a vanishing point. The vanishing point can be regarded as the projection of a point at infinity on the projection plane.

[0027] As described above, during the driving process, the vehicle's posture will change due to various reasons, and the change in vehicle posture will cause the camera's external parameters to change. Therefore, it is necessary to calculate, correct and compensate for the change in external parameters caused by the change in vehicle posture, that is, to correct the external parameters to obtain accurate external parameters.

[0028] Traditionally, changes in external parameters can be corrected through online calibration methods. As an example, the camera mounted on the vehicle obtains an image frame of the road, and uses lane line perception technology to determine the lane lines from the image frames. The deviation of the intersection of the lane lines, that is, the vanishing point of the lane lines, is further calculated, and the changes in external parameters (for example, the deviation of the pitch angle) are calculated in combination with the camera parameters, and then the changes in external parameters are corrected. However, the vehicle faces various conditions during driving, resulting in inaccurate lane lines obtained by the on-board camera. Therefore, it is impossible to obtain accurate changes in camera external parameters in real time, reducing the accuracy of camera calibration. At the same time, traditional camera calibration schemes cannot be applied to other complex lane scenes such as curves and ramps.

[0029] In view of this, an embodiment of the present disclosure provides a solution for camera calibration. According to the solution, a first set of segmented fitting results is generated based on the distance from a first set of points corresponding to a first lane line to a vehicle. The first set of segmented fitting results corresponds to a plurality of distance ranges for the first lane line. Further, based on a second set of points and the first set of segmented fitting results, the external parameters of the camera are updated.

[0030] Based on this approach, the embodiments of the present disclosure can perform segmented fitting based on the lane line data obtained by the camera, and perform external parameter calibration of the camera based on the results of segmented fitting, thereby not relying on reference data and improving the efficiency of calibration. In addition, the embodiments of the present disclosure can update the external parameters of the camera in real time, improving the accuracy and efficiency of the camera calibration results.

[0031] Some example embodiments of the present disclosure will be described below with continued reference to the accompanying drawings.

[0032] See first Figure 1 , which shows a schematic diagram of an example environment in which embodiments according to the present disclosure may be implemented.

[0033] like Figure 1 As shown, in the environment 100, the environment 100 may include an electronic device 110. In general, the electronic device 110 may obtain image information of an image 130 captured by a camera mounted on a vehicle 120, and update the external parameters of the camera based on such image information, thereby obtaining updated external parameters 140 of the camera.

[0034] Such a camera may be deployed, for example, at an appropriate location of the vehicle 120 to capture images of the surrounding environment of the vehicle 120. For example, a camera may be deployed in front of the vehicle 120 to capture images in front of the vehicle 120 while the vehicle 120 is traveling; a camera may be deployed in the rear of the vehicle 120 to capture images in the rear of the vehicle 120 while the vehicle 120 is traveling. The present disclosure is not intended to limit the arrangement of the cameras.

[0035] In some embodiments, when the vehicle is in motion, the onboard camera may capture multiple discrete static images, or may also capture a continuous video stream. Exemplarily, the electronic device 110 may periodically update the camera's extrinsic parameters based on the video frames in the video stream. For example, the electronic device 110 may update the camera's extrinsic parameters frame by frame, thereby improving the accuracy of the camera's extrinsic parameters.

[0036] In some embodiments, considering the positional relationship of lane lines in the image, the updated extrinsic parameter may be, for example, the pitch angle of the camera.

[0037] It should be understood that the electronic device 110 can be any suitable electronic device, such as a computer, a vehicle-mounted device, etc. In some embodiments, at least a portion of the electronic device 110 can be coupled to the vehicle-mounted camera. Alternatively, the electronic device 110 can also be separated from the vehicle-mounted camera. For example, at least a portion of the electronic device 110 can be a server, a mainframe computer, an edge node, a computing device in a cloud environment, etc. For example, the electronic device 110 can be a server controlled and coordinated by a cloud operating system in a cloud environment, providing operations such as data processing through a virtual machine or a similar method.

[0038] It should be understood that the structure and functionality of environment 100 are described for exemplary purposes only and does not imply any limitation on the scope of the present disclosure.

[0039] The specific process of camera calibration according to the embodiments of the present disclosure is further described below.

[0040] Figure 2A schematic block diagram of a camera calibration system 200 according to an embodiment of the present disclosure is shown. The camera calibration system 200 may be implemented in the electronic device 110 alone, or may be implemented in the electronic device 110 and one or more remote devices in a coordinated manner.

[0041] In the following, for the convenience of discussion, Figure 1 Taking the example image 130 as an example, the process of the camera calibration system 200 processing the image 130 to obtain the target extrinsic parameter 230 is explained. It should be understood that the image 130 is only a simplified schematic diagram, and the image actually captured may contain more elements in the environment.

[0042] As an example, image 130 may include a first lane line 210 and a second lane line 220. First lane line 210 is determined to be associated with second lane line 220. Exemplarily, an image processing module (which may be deployed at electronic device 110 or other electronic devices) may recognize first lane line 210 and second lane line 220 based on image 130, and identify them as a pair of associated lane lines.

[0043] In some embodiments, the image processing module can determine that the first lane line 210 and the second lane line 220 have a predetermined spatial relationship. For example, the first lane line 210 and the second lane line 220 can be marked as parallel lane lines, or marked as lane lines on both sides of the same lane, etc.

[0044] It should be understood that the image processing module can use any appropriate image processing technology to identify lane lines and determine the association relationship between lane lines. The present disclosure is not intended to limit the specific processing technology of the image processing module. In addition, in this embodiment, the number and shape of lane lines included in the image 130 can be determined according to the actual scene of the target area, and the present disclosure does not make specific limitations in this regard.

[0045] Accordingly, the image processing module may provide the electronic device 110 with information of the first lane line 210 and the second lane line 220 that are determined to be associated. Such information may include, for example, a first group of points corresponding to the first lane line 210, such as lane line point 230-1, lane line point 230-2, and lane line point 230-3 (individually or collectively referred to as the first group of points 230). In addition, the information may also include a second group of points corresponding to the second lane line 220, such as lane line point 240-1, lane line point 240-2, and lane line point 240-3 (individually or collectively referred to as the second group of points 240).

[0046] The following specifically introduces an exemplary structure for implementing the camera calibration system 200. Figure 2As shown, the camera calibration system 200 may include multiple modules or components, and each module / component may be implemented by hardware, software, firmware, or any combination thereof.

[0047] For example, the camera calibration system 200 may include a sampling module 201, which may be configured to sample a plurality of lane line points in an image to obtain a plurality of groups of sampling points 205. The specific implementation details of the sampling will be described below in conjunction with Figure 3 Detailed introduction.

[0048] The camera calibration system 200 may include a fitting module 206, which may be configured to fit the multiple groups of sampling points 205, obtain multiple segmented fitting results corresponding to the multiple groups of sampling points 205, and determine the fitting error based on at least the multiple segmented fitting results. The specific implementation details of the fitting module 206 will be described below in conjunction with Figure 4 Detailed introduction.

[0049] In addition, the camera calibration system 200 may include an updating module 209 , which may be configured to update the extrinsic parameters of the camera according to the fitting error.

[0050] The following will introduce a specific implementation of the sampling module 201. Exemplarily, the sampling module 201 may include a distance determination module 202, which may be configured to determine the distance from the first set of points to the vehicle.

[0051] Before determining the distance from the first group of points to the vehicle, in order to improve computational efficiency, the first group of points 230 corresponding to the first lane line 210 in the image captured by the camera (also referred to as the image domain) may be sorted. For example, the first group of points may be sorted using a quick sorting method. Specifically, the distance segmentation module 202 may sort the first group of points according to the coordinates of the first group of points in the image domain. Such an order may be, for example, an order of arrangement of coordinate values ​​from small to large. For example, the distance segmentation module 202 may sort the first group of points according to the y coordinates of the first group of points in the image domain. According to the camera imaging principle, if the y coordinates of two points on a straight line in the image domain have a size relationship, then the two points also have a corresponding size relationship in the vehicle body domain space.

[0052] In some embodiments, the distance determination module 202 may use the initial external parameters 2042 to convert the first group of points 230 from image coordinates to vehicle body coordinates. Specifically, the distance determination module 202 may use the initial external parameters of the camera and determine the second group of coordinates of the first group of points 230 in the vehicle coordinate system based on the first group of coordinates in the image. Such a first group of coordinates may be a two-dimensional coordinate. Such a second group of coordinates may be a three-dimensional coordinate. In other words, the first group of coordinates in the image are matrix-transformed using the initial external parameters of the camera to obtain the second group of coordinates of the first group of points 230 in the vehicle coordinate system.

[0053] In a scenario of continuous external parameter updates, such initial external parameters 204 may represent external parameters determined based on the last update.

[0054] Further, the distance determination module 202 may also be configured to determine the distance from the first group of points 230 to the vehicle based on the second group of coordinates. For example, the distance determination module 202 may determine the value of the second group of coordinates on a predetermined coordinate axis of the vehicle coordinate system as the distance from the first group of points to the vehicle. Such a predetermined coordinate axis may be, for example, the y-axis of the vehicle coordinate system. Such a y-axis may correspond to the vehicle's heading direction, or the vehicle's driving direction. It should be understood that, depending on the different ways in which the vehicle body coordinate axis is set, such a predetermined coordinate axis may also be other axes of the vehicle coordinate system, such as the x-axis.

[0055] The sampling module 201 may further include a segmented sampling module 203 , which may be configured to generate multiple groups of sampling points for multiple distance ranges based on the first group of points 230 , that is, multiple groups of sampling points corresponding to the first lane line 210 .

[0056] Such a distance range refers to the range of the distance from the first group of points 230 to the vehicle. For example, taking the value of the y-axis of the vehicle body coordinate system as an example of the distance from the first group of points 230 to the vehicle, such a distance range may include multiple y-axis value ranges, for example, 0 to 10 meters, 10 meters to 20 meters, etc. In some embodiments, each distance range may have the same distance span, for example, ten meters.

[0057] Similarly, the distance segmentation module 203 can also be configured to generate multiple groups of sampling points for multiple distance ranges based on the second group of points 240, that is, multiple groups of sampling points corresponding to the second lane line 220. In other words, according to such a sampling method, the lane line is divided into multiple distance segments according to the multiple groups of sampling points, so as to facilitate fitting of each distance segment.

[0058] As an example, Figure 3 A schematic diagram showing multiple groups of sampling points for multiple distance ranges according to some embodiments of the present disclosure is shown. Figure 3 A first lane line 310-1 and a second lane line 310-2 are shown, which may also be collectively referred to as an associated pair of lane lines 310. Lane line points on the first lane line 310-1, such as lane line point 330-1, lane line point 330-2, ... lane line point 330-8 (individually or collectively referred to as a first group of points 330). Lane line points on the second lane line, such as lane line point 320-1, lane line point 320-2, ... lane line point 320-8 (individually or collectively referred to as a second group of points 320).

[0059] The following is an example of the first group of points to illustrate the process of sampling the first group of points. The segmented sampling module 203 can, for example, determine multiple distance ranges, and sample lane line points according to the determined multiple distance ranges. In some embodiments, multiple distance ranges have the same distance span. Such a distance span refers to the absolute value of the difference between the maximum value and the minimum value of the distance range. Such a sampling method is also called equidistant sampling. With reference to the above example, the first distance range and the second distance range can have the same distance span. For example, the first distance range is 10m-20m, the second distance range is 30m-40m, and the first distance range and the second distance range have the same distance span of 10m. It should be understood that multiple distance ranges can have different distance spans. For example, the first distance range is 10m-20m, the second distance range is 30m-50m, the distance span corresponding to the first distance range is 10m, and the distance span corresponding to the second distance range is 20m. It should be understood that the distance ranges and distance spans described above are only examples, and this embodiment is not limited here.

[0060] For example, Figure 3 As shown, according to the matching of the distance and the distance range, the segmented sampling module 203 can, for example, sample the lane line point 320-1, the lane line point 320-2, the lane line point 320-3, and the lane line point 320-4 as a first group of sampling points 350 corresponding to the first distance range. The segmented sampling module 203 can, for example, also sample the lane line point 320-5, the lane line point 320-6, the lane line point 320-7, and the lane line point 320-8 as a second group of sampling points 370 corresponding to the second distance range. It should be understood that if the electronic device 110 detects that there are more lane line points on the first lane line from the image, the distance sampling module 203 can continue to perform group sampling according to the distances from these lane line points to the vehicle to obtain more groups of sampling points, and this embodiment is not limited in this regard.

[0061] The segmented sampling module 203 may also be configured to perform sampling according to the number of sampling points for the first group of points to obtain multiple groups of sampling points. If the distance span corresponding to each group of sampling points is the same, considering that among the multiple groups of sampling points corresponding to the same distance span, the lane line points in a group of sampling points that are closer to the vehicle may be densely distributed, and the lane line points in a group of sampling points that are farther from the lane may be sparsely distributed.

[0062] In order to facilitate the subsequent fitting calculation based on each group of sampling points and improve the accuracy of the fitting, in some embodiments, each group of sampling points in the multiple groups of sampling points has the same number of sampling points. In the above example, for example, the first group of sampling points 350 has a first number of sampling points in a first distance range (e.g., 10m-20m), and the second group of sampling points 370 has a second number of sampling points in a second distance range (e.g., 30m-40m). The first number is the same as the second number, refer to Figure 3 In the example of , the first number and the second number are both 4.

[0063] As an example, the distance sampling module 203 can pre-set a number of sampling points n, and compare the number m of the points to be sampled (for example, the first group of points) with the preset number of sampling points n (m, n is an integer). If the number m of the points to be sampled (for example, m=8) is less than n (for example, n=10), all the points to be sampled are determined as a group of sampling points (for example, the number of sampling points in a group is m=8). If the number m of the points to be sampled (for example, m=26) is greater than n (for example, n=10), at least one group of sampling points is selected from the m points to be sampled according to the same distance span, and the number of sampling points in each group is n. The number of multiple groups of sampling points is calculated by rounding the value of m / n. For example, 26 / 10=2.6, 2.6 is rounded to 2, so it can be determined that 2 groups of sampling points are taken.

[0064] It can be understood that the second group of points can be sampled in the same manner as the first group of points, so the sampling process of the second group of points will not be described in detail. Figure 3 As shown, the second group of points, such as lane line points 320 - 1 , ... lane line points 320 - 8 (collectively or individually referred to as second group of points 320 ), are sampled to obtain first group of sampling points 340 and second group of sampling points 360 .

[0065] The above only provides an example of sampling multiple lane line points in an image by the sampling module 201 to obtain multiple groups of sampling points. It should be understood that the sampling module 201 can be implemented in any appropriate manner. The present disclosure is not intended to limit the specific implementation of the sampling module 201.

[0066] Return to continue reference Figure 2 , the specific implementation of the fitting module 206 will be described below. In some embodiments, the fitting module 206 may include a segmented fitting module 207, which may be configured to fit multiple groups of sampling points respectively to determine a first group of segmented fitting results corresponding to multiple distance ranges. For example, multiple groups of sampling points corresponding to multiple distance ranges corresponding to the first lane line are fitted respectively to obtain multiple segmented fitting results. In other words, the first group of segmented fitting results includes multiple corresponding segmented fitting results corresponding to the distance segments.

[0067] As an example, refer to Figure 3 , the fitting module 206 can fit the first group of sampling points 350 to determine the first segmented fitting result corresponding to the first distance range, and fit the second group of sampling points 370 to determine the second segmented fitting result corresponding to the second distance range. The first segmented fitting result and the second segmented fitting result can be used as the first group of segmented fitting results corresponding to the first lane line 310-1. It should be understood that if more groups of sampling points are sampled on the lane line, the fitting is continued for more groups of sampling points to obtain multiple segmented fitting results. This solution does not make specific limitations on this aspect. Accordingly, Figure 3 In the example of FIG. 3 , the fitting module 206 may also perform fitting on multiple groups of sampling points of the second lane line 310 - 2 , such as the first group of sampling points 340 and the second group of sampling points 360 , respectively, to obtain multiple segmented fitting results.

[0068] In complex road scenarios such as curves or ramps, the shape of the lane line can be a curve. In some embodiments, multiple segmented fitting results can be, for example, straight line fitting results, and the fitting module 206 can also use an appropriate fitting method (for example, a fitting method based on a Bezier curve) to fit the straight line fitting of each segment of the lane line to obtain the final curve fitting result for the lane line. In other words, the fitting module 206 can model the lane line as a Bezier curve. For example, the Bezier curve fitting module 206 can model the first lane line and / or the second lane line as a Bezier curve. The Bezier curve fitting method can effectively fit non-straight lane lines, adapt to more complex lane scenes such as curves and ramps, and greatly increase the applicable scenarios and accuracy of online calibration.

[0069] Considering that the first lane line and the second lane line are marked as parallel, if the camera's external parameters are accurate, the distances from the lane line points on the second lane line to the first lane line should be equal. Therefore, the distances from the lane line points on the second lane line to the multiple segmented fitting results corresponding to the first lane line should be equal, or the distances from the lane line points on the first lane line to the multiple segmented fitting results corresponding to the second lane line should be equal.

[0070] According to the above principle, the curve fitting module 206 may be able to use the fitting error between the second group of points and the fitting result of the first lane line to evaluate and / or adjust the external parameters of the camera. In some embodiments, when multiple segmented fitting results (which may be straight line fitting results or curve fitting results) are used as corresponding lane line fitting results, such a fitting error may indicate the average of the distance distribution between the second group of points (or the second group of sampling points) and the corresponding segmented fitting results.

[0071] In other embodiments, when a curve fitting result obtained based on multiple straight line segment fitting results is determined as the corresponding lane line fitting result, such fitting error can indicate the averageness of the distance distribution between the second group of points (or the second group of sampling points) and the curve fitting result.

[0072] Specifically, such a fitting error can be obtained by calculating multiple distances from the second set of points (or the second set of sampling points) to the fitting result, and determining the absolute values ​​of the differences between the multiple distances and the average distance, and then determining the fitting error according to the sum of the multiple absolute values. It should be understood that the larger the sum of the absolute values, the less accurate the camera's extrinsic parameters. Therefore, the camera's extrinsic parameters can be adjusted based on the goal of reducing the fitting error.

[0073] In some embodiments, the fitting module 206 may include a fitting error determination module 208, which may be configured to determine a first set of fitting errors for the first set of segmented fitting results based on the second set of points and the first set of segmented fitting results. In other words, the fitting module 206 determines the first set of fitting errors for the first set of segmented fitting results based on the first set of segmented fitting results corresponding to the first lane line and the second set of points corresponding to the second lane line. It should be understood that the fitting module 206 may also determine the second set of fitting errors for the second set of segmented fitting results based on the second set of segmented fitting results corresponding to the second lane line and the first set of points corresponding to the first lane line.

[0074] Further, the fitting error determination module 208 can be configured to determine, for the corresponding segmented fitting results in the first group of segmented fitting results corresponding to the corresponding distance segments, multiple points in the second group of points corresponding to the corresponding distance segments; determine multiple distances from the multiple points to the corresponding segmented fitting results; and determine the corresponding fitting errors for the corresponding segmented fitting results based on the multiple distances.

[0075] As an example, Figure 4 An example block diagram of cross-fitting error calculation according to some embodiments of the present disclosure is shown. The first group of segmented fitting results 410 corresponding to the first lane line may include the first segmented fitting result corresponding to the first distance range (also referred to as the first distance segment), the second segmented fitting result corresponding to the second distance range (also referred to as the second distance segment) ... the Nth segmented fitting result corresponding to the Nth distance range. The second group of points 420 corresponding to the second lane line may include the first group of sampling points of the first distance range (also referred to as the first distance segment), the second group of sampling points of the second distance range (also referred to as the second distance segment) ... the Nth group of sampling points of the Nth distance range. The N distance segments on the first lane line correspond to the N distance segments on the second lane line.

[0076] Specifically, the following describes the process of verifying the segmented fitting results corresponding to the first distance segment in the first group of segmented fitting results. In some embodiments, in box 430, the fitting error determination module 208 determines the first group of sampling points of the first distance segment from the second group of points, and then determines multiple distances from multiple points in the first group of sampling points to the first segmented fitting result of the first lane line, and determines the corresponding fitting error (also called the first fitting error) of the first segmented fitting result based on the multiple distances. Similarly, the fitting error determination module 208 can calculate the second fitting error corresponding to the first lane line...the Nth fitting error, and these N fitting errors are called the first group of fitting errors corresponding to the first lane line.

[0077] Further, the fitting error determination module 208 can determine the final fitting error 440 based on the first set of fitting errors. For example, the fitting error module 208 can determine the fitting error 440 based on the sum of the first set of fitting errors.

[0078] In some other embodiments, as discussed above, the fitting module 206 can obtain a curve fitting result for the lane line based on the results of fitting multiple straight line segments, for example, using Bezier curve fitting. Accordingly, the fitting error determination module 208 can determine multiple groups of sampling points corresponding to multiple distance ranges, and calculate the distances from such multiple groups of sampling points to the curve fitting result, thereby determining multiple fitting errors corresponding to multiple distance segments, or directly determining the final fitting error 440.

[0079] Similar to the calculation process of the first set of fitting errors 440 corresponding to the first lane line, in some embodiments, the fitting error determination module 208 can be configured to generate a second set of segmented fitting results corresponding to multiple distance ranges for the second lane line based on the distance from the second set of points to the vehicle. Further, the fitting error module 208 can also be configured to determine a second set of fitting errors for the second set of segmented fitting results based on the first set of points and the second set of segmented fitting results.

[0080] The above only provides an example of fitting multiple groups of sampling points in an image and determining the segmented fitting results and fitting errors through the fitting module 206. It should be understood that the fitting module 206 can be implemented in any appropriate manner. The present disclosure is not intended to limit the specific implementation of the fitting module 206.

[0081] In this way, the lane line points are grouped and sampled, and multiple groups of sampling points corresponding to multiple distance segments are fitted, ensuring that the segmented fitting results corresponding to each distance segment contribute consistently to the overall fitting result, avoiding large fitting errors due to data distribution, and effectively improving the fitting accuracy and precision.

[0082] Return to continue reference Figure 2 In some embodiments, the updating module 209 can be configured to update the image according to the fitting error (e.g., Figure 4 The camera's external parameters are updated based on the determined fitting error 440. In some examples, the update module 209 can be configured to iteratively update the camera's external parameters using the Gauss-Newton method, so that the external parameters can be adjusted based on the goal of reducing the fitting error. Specifically, after sampling, the pitch parameter, such as the gradient of the pitch angle, is calculated, and the update module 209 can update the pitch angle according to the gradient of the pitch angle. Then, the change in the pitch angle is calculated, which can make the cross-fitting error of the lane line smaller.

[0083] In some embodiments, considering the timeliness requirement of the extrinsic parameter update, the update module 209 can calculate whether the number of times the extrinsic parameter is iteratively adjusted reaches a threshold number of times, or whether the fitting error is less than a threshold error. In some embodiments, in response to the number of times the extrinsic parameter is iteratively adjusted reaching a threshold number of times or the fitting error is less than a threshold error, the update module 209 can stop the iteration and determine the updated extrinsic parameter as the target extrinsic parameter of the camera.

[0084] Based on this approach, the embodiments of the present disclosure can, for example, ensure that the time required for extrinsic parameter iteration is less than or equal to the time required for image frame acquisition, thereby achieving the effect of iteratively updating the extrinsic parameters frame by frame in real time.

[0085] It should be understood that the calculation method for updating the camera's extrinsic parameters based on the fitting error in the update module 209 described above may also include any other appropriate update iterative calculation method, such as an update algorithm based on gradient backpropagation.

[0086] In some embodiments, as described above with reference to Figure 1 As discussed, the image 130 may, for example, include a first image frame in a video stream captured by a camera, and the extrinsic parameter determined based on the first image frame is the first extrinsic parameter. Further, the electronic device 110 may also update the first extrinsic parameter of the camera based on a second image frame in the video stream, wherein the time difference between the second image frame and the first image frame is less than a threshold. In this way, the embodiments of the present disclosure can realize dynamic updating of the camera extrinsic parameter based on the acquired image in real time during the operation of the vehicle, thereby improving the accuracy of the camera extrinsic parameter.

[0087] Based on this approach, the embodiments of the present disclosure can perform segmented fitting based on the lane line data obtained by the camera, and perform external parameter calibration of the camera based on the results of segmented fitting, thereby not relying on reference data and improving the efficiency of calibration. In addition, the embodiments of the present disclosure can update the external parameters of the camera in real time, improving the accuracy and efficiency of the camera calibration results.

[0088] Example Process

[0089] Figure 5 FIG. 5 is a flowchart of an example process 500 for camera calibration according to various embodiments of the present disclosure. For example, the process 500 may be performed by: Figure 1 The electronic device 110 shown is implemented.

[0090] like Figure 5 As shown, in box 510, the electronic device 110 obtains a first group of points corresponding to a first lane line and a second group of points corresponding to a second lane line based on an image captured by a camera mounted on the vehicle, and the first lane line is determined to be associated with the second lane line.

[0091] In block 520 , the electronic device 110 generates a first set of segment fitting results corresponding to a plurality of distance ranges for the first lane line based on the distances from the first set of points to the vehicle.

[0092] In block 530 , the electronic device 110 updates the extrinsic parameters of the camera based on the second set of points and the first set of segment fitting results.

[0093] In some embodiments, the first lane marking and the second lane marking are identified as parallel lane markings.

[0094] In some embodiments, the electronic device 130 may also include: utilizing the initial external parameters of the camera and based on the first set of coordinates of the first group of points in the image, determining a second set of coordinates of the first group of points in the vehicle coordinate system; and determining the distance from the first group of points to the vehicle based on the second set of coordinates.

[0095] In some embodiments, determining the distance from the first set of points to the vehicle based on the second set of coordinates includes: determining the value of the second set of coordinates on a predetermined coordinate axis of the vehicle coordinate system as the distance from the first set of points to the vehicle.

[0096] In some embodiments, the multiple distance ranges have the same distance span.

[0097] In some embodiments, generating a first set of segmented fitting results corresponding to multiple distance ranges for a first lane line includes: generating multiple sets of sampling points for multiple distance ranges based on the first set of points; and fitting the multiple sets of sampling points separately to determine the first set of segmented fitting results corresponding to the multiple distance ranges.

[0098] In some embodiments, each group of sampling points in the plurality of groups of sampling points has the same number of sampling points.

[0099] In some embodiments, updating the extrinsic parameters of the camera includes: determining a first set of fitting errors for the first set of segmented fitting results based on the second set of points and the first set of segmented fitting results; and updating the extrinsic parameters of the camera based on the first set of fitting errors.

[0100] In some embodiments, determining a first set of fitting errors for a first group of segmented fitting results includes: for corresponding segmented fitting results corresponding to corresponding distance segments in the first group of segmented fitting results: determining a plurality of points in a second group of points corresponding to corresponding distance segments; determining a plurality of distances from the plurality of points to the corresponding segmented fitting results; and determining corresponding fitting errors for the corresponding segmented fitting results based on the plurality of distances.

[0101] In some embodiments, the first group of segmented fitting results includes a first group of straight line fitting results, and determining a first group of fitting errors for the first group of segmented fitting results includes: determining a curve fitting result for the first lane line based on the first group of straight line fitting results; and determining a first group of fitting errors for the first group of segmented fitting results based on the second group of points and curve fitting results.

[0102] In some embodiments, updating the camera's external parameters includes: generating a second set of segmented fitting results corresponding to multiple distance ranges for the second lane line based on the distance from the second set of points to the vehicle; and determining a second set of fitting errors for the second set of segmented fitting results based on the first set of points and the second set of segmented fitting results; and updating the camera's external parameters based on at least the first set of fitting errors and the second set of fitting errors.

[0103] In some embodiments, the image includes a first image frame in a video stream captured by a camera, and the external parameter determined based on the first image frame is a first external parameter, and the method also includes: updating the first external parameter of the camera based on a second image frame in the video stream, and the time difference between the second image frame and the first image frame is less than a threshold.

[0104] In some embodiments, updating the external parameters of the camera includes: determining a fitting error based on the second set of points and the first set of segmented fitting results; and updating the external parameters of the camera using a Gauss-Newton method according to the fitting error.

[0105] In some embodiments, the electronic device 110 may further include: in response to the number of times the extrinsic parameter is iteratively adjusted reaching a threshold number or the fitting error is less than a threshold error, determining a target extrinsic parameter of the camera based on the updated extrinsic parameter.

[0106] In some embodiments, the external parameter is a pitch parameter of the camera.

[0107] Example devices and equipment

[0108] The embodiments of the present disclosure also provide corresponding devices for implementing the above methods or processes. Figure 6 A schematic structural block diagram of a device 600 for camera calibration according to some embodiments of the present disclosure is shown.

[0109] like Figure 6As shown, the device 600 includes: an acquisition module 610, configured to acquire a first group of points corresponding to a first lane line and a second group of points corresponding to a second lane line based on an image captured by a camera mounted on a vehicle, wherein the first lane line is determined to be associated with the second lane line; a fitting result generation module 620, configured to generate a first group of segmented fitting results corresponding to a plurality of distance ranges for the first lane line based on the distance from the first group of points to the vehicle; and an extrinsic parameter updating module 630, configured to update the extrinsic parameters of the camera based on the second group of points and the first group of segmented fitting results.

[0110] In some embodiments, the first lane marking and the second lane marking are identified as parallel lane markings.

[0111] In some embodiments, the device 600 is also configured to utilize the initial external parameters of the camera and determine a second set of coordinates of the first group of points in the vehicle coordinate system based on the first set of coordinates of the first group of points in the image; and determine the distance from the first group of points to the vehicle based on the second set of coordinates.

[0112] In some embodiments, the apparatus 600 is further configured to determine the values ​​of the second set of coordinates on predetermined coordinate axes of the vehicle coordinate system as the distances from the first set of points to the vehicle.

[0113] In some embodiments, the multiple distance ranges have the same distance span.

[0114] In some embodiments, the fitting result generation module 620 is further configured to generate multiple groups of sampling points for multiple distance ranges based on the first group of points; and fit the multiple groups of sampling points respectively to determine a first group of segmented fitting results corresponding to the multiple distance ranges.

[0115] In some embodiments, each group of sampling points in the plurality of groups of sampling points has the same number of sampling points.

[0116] In some embodiments, the extrinsic parameter update module 630 is further configured to determine a first set of fitting errors for the first set of segmented fitting results based on the second set of points and the first set of segmented fitting results; and update the extrinsic parameters of the camera based on the first set of fitting errors.

[0117] In some embodiments, the external parameter update module 630 is also configured to: determine, for the corresponding segmented fitting results corresponding to the corresponding distance segments in the first group of segmented fitting results: determine multiple points in the second group of points corresponding to the corresponding distance segments; determine multiple distances from the multiple points to the corresponding segmented fitting results; and determine the corresponding fitting errors for the corresponding segmented fitting results based on the multiple distances.

[0118] In some embodiments, the first group of segmented fitting results includes a first group of straight line fitting results, and the external parameter update module 630 is also configured to: determine a curve fitting result for the first lane line based on the first group of straight line fitting results; and determine a first group of fitting errors for the first group of segmented fitting results based on the second group of points and curve fitting results.

[0119] In some embodiments, the extrinsic parameter update module 630 is also configured to generate a second set of segmented fitting results corresponding to multiple distance ranges for the second lane line based on the distance from the second set of points to the vehicle; and determine a second set of fitting errors for the second set of segmented fitting results based on the first set of points and the second set of segmented fitting results; and update the camera's extrinsic parameters based on at least the first set of fitting errors and the second set of fitting errors.

[0120] In some embodiments, the image includes a first image frame in a video stream captured by a camera, and the external parameter determined based on the first image frame is a first external parameter. The device 600 is also configured to update the first external parameter of the camera based on a second image frame in the video stream, and the time difference between the second image frame and the first image frame is less than a threshold.

[0121] In some embodiments, the extrinsic parameter update module 630 is further configured to determine a fitting error based on the second set of points and the first set of segmented fitting results; and update the extrinsic parameters of the camera using the Gauss-Newton method according to the fitting error.

[0122] In some embodiments, the apparatus 600 is further configured to determine a target extrinsic parameter of the camera based on the updated extrinsic parameter in response to the number of times the extrinsic parameter is iteratively adjusted reaching a threshold number or the fitting error being less than a threshold error.

[0123] In some embodiments, the external parameter is a pitch parameter of the camera.

[0124] The units included in the device 600 can be implemented in various ways, including software, hardware, firmware or any combination thereof. In some embodiments, one or more units can be implemented using software and / or firmware, such as machine executable instructions stored on a storage medium. In addition to or as an alternative to machine executable instructions, some or all of the units in the device 600 can be implemented at least in part by one or more hardware logic components. As an example and not a limitation, exemplary types of hardware logic components that can be used include field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like. In addition, in some embodiments, multiple functions implemented by a unit (or module) can be implemented by subunits or other independent units included therein. For example, in the case where the status interface associated with the energy replenishment site is presented by the presentation module 620, and the status interface presents the first three-dimensional model associated with the energy replenishment site, the presentation module 620 can be further implemented or implemented by other presentation modules independent of the presentation module 620. In response to receiving a status viewing request, the status information corresponding to each energy replenishment facility is presented using the first three-dimensional model, and the present disclosure is not limited to this.

[0125] Figure 7 1 shows a block diagram of an electronic device / server 700 in which one or more embodiments of the present disclosure may be implemented. It should be understood that Figure 7 The electronic device / server 700 shown is merely exemplary and should not constitute any limitation on the functionality and scope of the embodiments described herein.

[0126] like Figure 7 As shown, the electronic device / server 700 is in the form of a general electronic device. The components of the electronic device / server 700 may include, but are not limited to, one or more processors or processing units 710, a memory 720, a storage device 730, one or more communication units 740, one or more input devices 750, and one or more output devices 760. The processing unit 710 may be an actual or virtual processor and is capable of performing various processes according to a program stored in the memory 720. In a multi-processor system, multiple processing units execute computer executable instructions in parallel to improve the parallel processing capability of the electronic device / server 700.

[0127] The electronic device / server 700 typically includes a plurality of computer storage media. Such media can be any available media accessible to the electronic device / server 700, including but not limited to volatile and non-volatile media, removable and non-removable media. The memory 720 can be a volatile memory (e.g., register, cache, random access memory (RAM)), a non-volatile memory (e.g., a read-only memory (ROM), an electrically erasable programmable read-only memory (EEPROM), flash memory) or some combination thereof. The storage device 730 can be a removable or non-removable medium, and can include a machine-readable medium, such as a flash drive, a disk, or any other medium, which can be used to store information and / or data (e.g., training data for training) and can be accessed within the electronic device / server 700.

[0128] The electronic device / server 700 may further include additional removable / non-removable, volatile / non-volatile storage media. Figure 7 As shown in , a disk drive for reading or writing from a removable, non-volatile disk (e.g., a "floppy disk") and an optical drive for reading or writing from a removable, non-volatile optical disk may be provided. In these cases, each drive may be connected to the bus (not shown) by one or more data media interfaces. The memory 720 may include a computer program product 725 having one or more program modules that are configured to perform various methods or actions of various embodiments of the present disclosure.

[0129] The communication unit 740 implements communication with other electronic devices through a communication medium. Additionally, the functions of the components of the electronic device / server 700 can be implemented with a single computing cluster or multiple computing machines that can communicate through a communication connection. Therefore, the electronic device / server 700 can operate in a networked environment using a logical connection with one or more other servers, a network personal computer (PC), or another network node.

[0130] The input device 750 may be one or more input devices, such as a mouse, keyboard, tracking ball, etc. The output device 770 may be one or more output devices, such as a display, a speaker, a printer, etc. The electronic device / server 700 may also communicate with one or more external devices (not shown) through the communication unit 740 as needed, such as a storage device, a display device, etc., communicate with one or more devices that allow a user to interact with the electronic device / server 700, or communicate with any device that allows the electronic device / server 700 to communicate with one or more other electronic devices (e.g., a network card, a modem, etc.). Such communication may be performed via an input / output (I / O) interface (not shown).

[0131] According to an exemplary implementation of the present disclosure, a computer-readable storage medium is provided, on which one or more computer instructions are stored, wherein the one or more computer instructions are executed by a processor to implement the method described above.

[0132] Various aspects of the present disclosure are described herein with reference to the flowcharts and / or block diagrams of the methods, devices (systems) and computer program products implemented according to the present disclosure. It should be understood that each box in the flowchart and / or block diagram and the combination of each box in the flowchart and / or block diagram can be implemented by computer-readable program instructions.

[0133] These computer-readable program instructions can be provided to a processing unit of a general-purpose computer, a special-purpose computer, or other programmable data processing device, thereby producing a machine, so that when these instructions are executed by the processing unit of the computer or other programmable data processing device, a device that implements the functions / actions specified in one or more boxes in the flowchart and / or block diagram is generated. These computer-readable program instructions can also be stored in a computer-readable storage medium, and these instructions cause the computer, programmable data processing device, and / or other equipment to work in a specific manner, so that the computer-readable medium storing the instructions includes a manufactured product, which includes instructions for implementing various aspects of the functions / actions specified in one or more boxes in the flowchart and / or block diagram.

[0134] Computer-readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other device so that a series of operating steps are performed on the computer, other programmable data processing apparatus, or other device to produce a computer-implemented process, thereby causing the instructions executed on the computer, other programmable data processing apparatus, or other device to implement the functions / actions specified in one or more boxes in the flowchart and / or block diagram.

[0135] The flow chart and block diagram in the accompanying drawings show the possible architecture, function and operation of the system, method and computer program product according to multiple implementations of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a part of a module, program segment or instruction, and a part of a module, program segment or instruction includes one or more executable instructions for realizing the logical function of the specification. In some implementations as replacements, the function marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two continuous square boxes can actually be executed substantially in parallel, and they can sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be realized by a special hardware-based system that performs the function or action of the specification, or can be realized by a combination of special hardware and computer instructions.

[0136] The above descriptions of various implementations of the present disclosure are exemplary, non-exhaustive, and not limited to the disclosed implementations. Many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described implementations. The selection of terms used herein is intended to best explain the principles of the implementations, practical applications, or improvements to the technology in the marketplace, or to enable other persons of ordinary skill in the art to understand the implementations disclosed herein.

Claims

1. A method for camera calibration, comprising: Based on an image captured by a camera mounted on the vehicle, acquiring a first set of points corresponding to a first lane line and a second set of points corresponding to a second lane line, the first lane line being determined to be associated with the second lane line; Based on the distances from the first group of points to the vehicle, generating a first group of segment fitting results corresponding to a plurality of distance ranges for the first lane line; and Based on the second group of points and the first group of segment fitting results, the external parameters of the camera are updated. 2 . The method according to claim 1 , wherein the first lane marking and the second lane marking are identified as parallel lane markings.

3. The method according to claim 1, further comprising: Determining a second set of coordinates of the first set of points in a vehicle coordinate system using initial extrinsic parameters of the camera and based on a first set of coordinates of the first set of points in the image; as well as Based on the second set of coordinates, the distance from the first set of points to the vehicle is determined.

4. The method of claim 3, wherein determining the distance from the first set of points to the vehicle based on the second set of coordinates comprises: The values ​​of the second set of coordinates on the predetermined coordinate axis of the vehicle coordinate system are determined as the distance from the first set of points to the vehicle. The method of claim 1 , wherein the plurality of distance ranges have the same distance span.

6. The method according to claim 1, wherein generating a first set of segment fitting results corresponding to a plurality of distance ranges for the first lane line comprises: Based on the first group of points, generating multiple groups of sampling points for the multiple distance ranges; as well as The multiple groups of sampling points are fitted respectively to determine the first group of segmented fitting results corresponding to multiple distance ranges. The method according to claim 6 , wherein each group of sampling points in the plurality of groups of sampling points has the same number of sampling points.

8. The method according to claim 1, wherein updating the external parameters of the camera comprises: determining a first set of fitting errors for the first set of segmented fitting results based on the second set of points and the first set of segmented fitting results; as well as Based on the first set of fitting errors, the extrinsic parameters of the camera are updated.

9. The method of claim 8, wherein determining a first set of fitting errors for the first set of segmented fitting results comprises: For the corresponding segmented fitting results corresponding to the corresponding distance segments in the first group of segmented fitting results: determining a plurality of points in the second set of points corresponding to the respective distance segments; Determine a plurality of distances from the plurality of points to the corresponding segmented fitting results; as well as Based on the plurality of distances, a corresponding fitting error for the corresponding segmented fitting result is determined.

10. The method of claim 8, wherein the first set of segmented fitting results comprises a first set of straight line fitting results, and determining a first set of fitting errors for the first set of segmented fitting results comprises: Determining a curve fitting result for the first lane line based on the first set of straight line fitting results; as well as The first set of fitting errors for the first set of segmented fitting results is determined based on the second set of points and the curve fitting results.

11. The method according to claim 8, wherein updating the external parameters of the camera comprises: Based on the distances from the second group of points to the vehicle, generating a second group of segment fitting results corresponding to the multiple distance ranges for the second lane line; as well as determining a second set of fitting errors for the second set of segmented fitting results based on the first set of points and the second set of segmented fitting results; and The extrinsic parameters of the camera are updated based at least on the first set of fitting errors and the second set of fitting errors.

12. The method according to claim 1, wherein the image comprises a first image frame in a video stream captured by the camera, and the extrinsic parameter determined based on the first image frame is a first extrinsic parameter, the method further comprising: Based on a second image frame in the video stream, the first extrinsic parameter of the camera is updated, and a time difference between the second image frame and the first image frame is less than a threshold.

13. The method according to claim 1, wherein updating the external parameters of the camera comprises: determining a fitting error based on the second set of points and the first set of segmented fitting results; as well as According to the fitting error, the extrinsic parameters of the camera are updated using the Gauss-Newton method.

14. The method according to claim 13, further comprising: In response to the number of times the extrinsic parameter is iteratively adjusted reaching a threshold number or the fitting error being less than a threshold error, a target extrinsic parameter of the camera is determined based on the updated extrinsic parameter. The method according to claim 1 , wherein the external parameter is a pitch parameter of the camera.

16. A device for camera calibration, comprising: an acquisition module configured to acquire, based on an image captured by a camera mounted on the vehicle, a first set of points corresponding to a first lane line and a second set of points corresponding to a second lane line, the first lane line being determined to be associated with the second lane line; A fitting result generating module, configured to generate a first group of segmented fitting results corresponding to a plurality of distance ranges for the first lane line based on the distance from the first group of points to the vehicle; as well as The extrinsic parameter updating module is configured to update the extrinsic parameters of the camera based on the second group of points and the first group of segment fitting results.

17. An electronic device comprising: Memory and processor; The memory is used to store one or more computer instructions, wherein the one or more computer instructions are executed by the processor to implement the method according to any one of claims 1 to 15.

18. A computer-readable storage medium having one or more computer instructions stored thereon, wherein the one or more computer instructions are executed by a processor to implement the method according to any one of claims 1 to 15.

19. A computer program product comprising computer executable instructions, wherein the computer executable instructions, when executed by a processor, implement the method according to any one of claims 1 to 15.