Camera parameter correction method, device, electronic device and storage medium

By performing multi-model processing on the target image acquired by the camera, determining and correcting the calibration parameters, the calibration parameters change problem caused by aging of camera components is solved, and the accuracy of image processing and shooting effect are improved.

CN112819897BActive Publication Date: 2025-01-10GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202110016581.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-01-07
Publication Date
2025-01-10
Estimated Expiration
2041-01-07

AI Technical Summary

Technical Problem

The aging and collision of camera components lead to changes in the lens and sensor characteristics, and the original calibration parameters are no longer adapted to the new shooting scene, resulting in large deviations in image processing results, affecting the camera shooting effect.

Method used

A camera parameter correction method is adopted to obtain the target image, and perform specific image processing using the first processing model and the second processing model, and compare the processing results to determine whether the preset correction conditions are met. If not, correct the calibration parameters of the camera. To improve image processing effect.

Benefits of technology

By correcting the camera calibration parameters, the accuracy and effect of image processing are improved, and the camera's shooting performance in different scenarios is ensured.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112819897B_ABST
    Figure CN112819897B_ABST
Patent Text Reader

Abstract

The embodiment of the present application discloses a camera parameter correction method, device, electronic device and storage medium, the method comprising: obtaining a target image captured by a camera; performing specific image processing on the target images respectively using a first processing model and a second processing model to obtain a first processing result and a second processing result; determining that a first correction condition is satisfied based on the first processing result and the second processing result, and correcting the calibration parameters of the camera based on the first processing result. In this way, the image processing result of the first processing model is used as an evaluation criterion of the camera's inherent second processing model. When the first processing result and the second processing result meet the correction condition, for example, the difference between the two is large, the calibration parameters of the camera are corrected using the more accurate first processing result, and the image processing is performed using the corrected parameters, which can improve the image processing effect of the camera.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to image processing technology, and in particular to a camera parameter correction method, device, electronic device and storage medium. Background Art

[0002] At present, the calibration parameters of cameras are generally completed at the factory, and the obtained calibration parameters are solidified as the module parameters of the camera. However, with the aging and collision of camera components, the characteristics of the lens and sensor may change, as well as the relative position of the lens, making the original calibration parameters at the factory no longer suitable for the new shooting scene. It is necessary to recalibrate or correct the parameters. Otherwise, when the camera performs image processing based on the original calibration parameters, the image processing results will have a large deviation, affecting the camera's shooting effect. Therefore, solving the problem of changes in camera calibration parameters is an important research direction to improve the camera's shooting effect. Summary of the invention

[0003] In order to solve the above technical problems, the embodiments of the present application hope to provide a camera parameter correction method, device, electronic device and storage medium.

[0004] The technical solution of this application is implemented as follows:

[0005] In a first aspect, a camera parameter correction method is provided, the method comprising:

[0006] Get the target image captured by the camera;

[0007] Performing specific image processing on the target image using a first processing model to obtain a first processing result of the target image;

[0008] Performing specific image processing on the target image using a second processing model to obtain a second processing result of the target image;

[0009] Based on the first processing result and the second processing result, determining whether a preset first correction condition is met;

[0010] It is determined that the first correction condition is satisfied, and calibration parameters of the camera are corrected based on the first processing result.

[0011] In a second aspect, a camera parameter correction device is provided, the device comprising:

[0012] An acquisition unit, used for acquiring a target image captured by a camera;

[0013] A processing unit, configured to perform specific image processing on the target image using a first processing model to obtain a first processing result of the target image; and perform specific image processing on the target image using a second processing model to obtain a second processing result of the target image;

[0014] a judging unit, configured to judge whether a preset first correction condition is satisfied based on the first processing result and the second processing result;

[0015] A correction unit is used to determine whether the first correction condition is satisfied and to correct the calibration parameters of the camera based on the first processing result.

[0016] According to a third aspect, an electronic device is provided, comprising: a processor and a memory configured to store a computer program that can be run on the processor, wherein the processor is configured to execute the steps of the aforementioned method when running the computer program.

[0017] In a fourth aspect, a computer storage medium is provided, on which a computer program is stored, wherein the computer program implements the steps of the aforementioned method when executed by a processor.

[0018] In the embodiments of the present application, a camera parameter correction method, device, electronic device and storage medium are provided, the method comprising: obtaining a target image captured by a camera; performing specific image processing on the target image using a first processing model to obtain a first processing result of the target image; performing specific image processing on the target image using a second processing model to obtain a second processing result of the target image; judging whether a preset first correction condition is satisfied based on the first processing result and the second processing result; determining that the first correction condition is satisfied, and correcting the calibration parameters of the camera based on the first processing result. In this way, the image processing result of the first processing model is used as an evaluation criterion of the inherent second processing model of the camera. When the first processing result and the second processing result meet the correction condition, for example, the difference between the two is large, the calibration parameters of the camera are corrected using the more accurate first processing result, and the image processing is performed using the corrected parameters, which can improve the image processing effect of the camera. BRIEF DESCRIPTION OF THE DRAWINGS

[0019] Figure 1 Schematic diagram of four coordinate systems of the camera in the embodiment of the present application;

[0020] Figure 2 This is a schematic diagram of a first process flow of a camera parameter correction method in an embodiment of the present application;

[0021] Figure 3 This is a schematic diagram of a second process of the camera parameter correction method in an embodiment of the present application;

[0022] Figure 4 Schematic diagram of a third process of the camera parameter correction method in an embodiment of the present application;

[0023] Figure 5 Schematic diagram of the imaging principle of the binocular camera in the embodiment of the present application;

[0024] Figure 6 This is a schematic diagram of imaging of a single point target in the left and right imaging planes of a binocular camera in an embodiment of the present application;

[0025] Figure 7 A schematic diagram of the coordinate transformation relationship between a single point target and an imaging plane in an embodiment of the present application;

[0026] Figure 8 This is a schematic diagram of a fourth process of the camera parameter correction method in an embodiment of the present application;

[0027] Fig. 9 This is a schematic diagram of the corrected convergence curve in the embodiment of the present application;

[0028] Fig.10 This is a schematic diagram of the composition structure of the camera parameter correction device in the embodiment of the present application;

[0029] Fig.11 It is a schematic diagram of the composition structure of the electronic device in the embodiment of the present application. DETAILED DESCRIPTION

[0030] In order to enable a more detailed understanding of the features and technical contents of the embodiments of the present application, the implementation of the embodiments of the present application is described in detail below in conjunction with the accompanying drawings. The attached drawings are for reference only and are not used to limit the embodiments of the present application.

[0031] Before further describing the embodiments of the present application in detail, the camera calibration parameters involved in the embodiments of the present application are explained.

[0032] In the current work of mobile phone factory, whether in image measurement or machine vision application, the calibration of camera parameters is a very critical link. The accuracy of the calibration results and the stability of the algorithm directly affect the accuracy of the results produced by the camera. Therefore, doing a good job of camera calibration is the prerequisite for doing a good job of subsequent work. Improving the calibration accuracy is the basis for subsequent image algorithms to process images based on the parameters obtained by calibration.

[0033] The purpose of camera calibration is to find out the camera's internal and external parameters (including the position parameters between cameras for multiple cameras) and distortion parameters. After calibrating the camera, we usually want to do two things: one is to correct the distortion of each lens, which varies from lens to lens, and generate a corrected image; the other is to reconstruct the 3D scene based on the obtained image.

[0034] The camera calibration process can be simply described as using a calibration board, such as Figure 1 As shown, image processing involves four coordinate systems: the world coordinate system (Ow-XwYwZw) describes the camera position; the camera coordinate system (Oc-XcYcZc) has the camera optical center as the origin Oc; the image coordinate system (o-xy) describes the imaging plane, with the midpoint of the imaging plane as the origin o; the pixel coordinate system (uv) has the origin at the upper left corner of the image, with pixels as units, and the coordinates of each pixel (u, v) are the number of columns and rows of the pixel in the array respectively; the point P (Xw, Yw, Zw) is a point in the world coordinate system, that is, a real point in life, and the point p (x, y) is the imaging point of the image in the image coordinate system, with the coordinates in the pixel coordinate system being (u, v). f is the focal length of the camera, f = ||o-Oc||.

[0035] The three-dimensional point Pi in the world coordinate system and the corresponding two-dimensional point pi in the image coordinate system, the transformation of these three-dimensional points to two-dimensional points can be obtained through a series of matrix transformations using the camera intrinsic parameters K, the camera extrinsic parameters (including the rotation matrix R and the offset vector T), and the distortion parameter D.

[0036] The transformation from the world coordinate system to the camera coordinate system is a rigid body transformation, that is, the object will not be deformed, only rotation and translation are required, which is described by the camera external parameters R and T. The transformation from the camera coordinate system to the image coordinate system is a perspective projection relationship, from 3D to 2D.

[0037] Under most conditions, these parameters must be obtained through experiments and calculations. The process of solving the parameters is called camera calibration (or camera calibration). Currently, the commonly used camera calibration methods are: traditional camera calibration method, active vision camera calibration method, and camera self-calibration method.

[0038] The traditional camera calibration method requires the use of a calibration object with known size. By establishing the correspondence between the points on the calibration object with known coordinates and its image points, a certain algorithm is used to obtain the internal and external parameters of the camera model. According to the different calibration objects, they can be divided into three-dimensional calibration objects and planar calibration objects. Three-dimensional calibration objects can be calibrated by a single image, and the calibration accuracy is high, but the processing and maintenance of high-precision three-dimensional calibration objects are more difficult. Planar calibration objects are simpler to make than three-dimensional calibration objects, and the accuracy is easy to guarantee, but two or more images must be used during calibration. The traditional camera calibration method always requires calibration objects during the calibration process, and the manufacturing accuracy of the calibration object will affect the calibration results. At the same time, some occasions are not suitable for placing calibration objects, which also limits the application of traditional camera calibration methods.

[0039] The self-calibration algorithm mainly uses the constraints of camera motion. The camera motion constraints are too strong, so it is not practical in practice. The use of scene constraints mainly uses some parallel or orthogonal information in the scene. The intersection of parallel lines in space on the camera image plane is called the vanishing point, which is a very important feature in projective geometry. Therefore, many scholars have studied the camera self-calibration method based on vanishing points. The self-calibration method is flexible and can calibrate the camera online. However, since it is based on absolute quadratic curves or surfaces, the algorithm has poor robustness.

[0040] The camera calibration method based on active vision refers to calibrating the camera when some of the camera's motion information is known. This method does not require a calibration object, but it needs to control the camera to do some special movements. The camera's internal parameters can be calculated using the particularity of this movement. The advantage of the camera calibration method based on active vision is that the algorithm is simple and a linear solution can often be obtained, so it has high robustness. The disadvantage is that the system cost is high, the experimental equipment is expensive, the experimental conditions are high, and it is not suitable for occasions where the motion parameters are unknown or uncontrollable.

[0041] The embodiment of the present application proposes a camera parameter correction method, the main idea of ​​which is to correct the original calibration parameters of the camera to solve the problem that the characteristics of the lens and sensor change due to aging and collision of camera components, making the original factory calibration parameters no longer suitable for the new shooting scene.

[0042] Figure 2 FIG. 1 is a schematic diagram of a first process of a camera parameter correction method according to an embodiment of the present application. Figure 2 As shown, the method specifically includes:

[0043] Step 201: Acquire a target image captured by a camera;

[0044] In some embodiments, the method further comprises: pre-caching the target image.

[0045] In some embodiments, acquiring the target image captured by the camera includes: when the camera is in an idle state, acquiring a cached target image to perform a calibration parameter correction operation.

[0046] It should be noted that in order to obtain more accurate results without strong timeliness requirements, the image data at a certain moment can be cached, and when system resources are sufficient or idle, two image processing methods (i.e., the first processing model and the second processing model) can be used to perform specific image processing on the same frame of image data, such as calculating image depth information; then the two calculated depth information are compared; and whether to perform parameter correction is determined based on the comparison results.

[0047] In some embodiments, when re-making the correction judgment, the method further includes: acquiring the target image re-captured by the camera; and performing specific image processing on the re-captured target image using the first processing model and the second processing model respectively.

[0048] That is to say, the correction process of the camera calibration parameters can also process a new frame based on one correction, and then perform iterative correction again (that is, the image processed by each correction will also be updated (for example, after generating a new stage correction parameter, a new frame of image data is collected as the processing object), and one image will not be processed all the time) (it is also an iterative convergence process) until the results of the two processing methods are consistent, and then the camera calibration parameters at the time of consistency are used as new calibration parameters; finally, the correction of the camera-related calibration parameters is completed.

[0049] Of course, it is also possible to continuously process a frame of image and iteratively correct the parameters.

[0050] Step 202: performing specific image processing on the target image using a first processing model to obtain a first processing result of the target image;

[0051] Here, the specific image processing process of the first processing model is not related to the calibration parameters of the camera. It can be understood that the input variables of the first processing model include the target image to be processed, but do not include the calibration parameters.

[0052] It should be noted that the image processing process of the first processing model is not only unrelated to the calibration parameters, but also has a higher accuracy in image processing. Therefore, the first processing result can be used as an evaluation criterion for the image processing effect of the second processing model. If the second processing result is close to or consistent with the first processing result, it can be determined that the image processing accuracy of the second processing model is higher and there is no need to correct the calibration parameters; otherwise, the calibration parameters need to be corrected.

[0053] Exemplarily, the first processing model is a neural network model established based on a neural network algorithm.

[0054] In some embodiments, the use of the first processing model to perform specific image processing on the target image to obtain a first processing result of the target image includes: using the first processing model to perform specific image processing on the target image to obtain an initial processing result of the target image; obtaining a first processing result of a related image; wherein the related image is correlated with the target image; and using the first processing result of the related image to correct the initial processing result to obtain the first processing result of the target image.

[0055] Here, in order to improve the accuracy of the first processing result, after the first processing model outputs the initial processing result of the target image, the initial processing result can be corrected according to the processing results of the related images.

[0056] Here, the related images may be adjacent frames, nearby frames, or other frames having the same shooting content as the target image. Since the processing results of the related images are the same or similar, they can be used to evaluate or correct the processing results of the target image.

[0057] Exemplarily, for example, the depth information of the target image is corrected using the depth information of adjacent frames.

[0058] Step 203: performing specific image processing on the target image using a second processing model to obtain a second processing result of the target image;

[0059] Here, the specific image processing process of the second processing model is related to the calibration parameters of the camera. It can be understood that the input variables of the first processing model include the target image to be processed and the calibration parameters.

[0060] In some embodiments, the feature image processing includes at least one of the following: image depth information calculation, image blur processing, image noise reduction processing, and image correction processing.

[0061] In some embodiments, the calibration parameters include at least one of the following: position parameters between lenses, camera intrinsic parameters, camera extrinsic parameters, and camera distortion parameters.

[0062] It should be noted that in practical applications, calibration parameters related to image processing effects can be corrected using image processing results. When the second processing model performs specific image processing, an image processing result may be affected by one or more calibration parameters. Therefore, an image processing result is used to correct the corresponding calibration parameters. For example, the position parameters between the lenses affect the depth information. By comparing the depth information obtained by the two modules, the position parameters between the lenses can be corrected; the camera distortion parameters affect the image correction processing. By comparing the image correction results obtained by the two modules, the camera distortion parameters can be corrected, and so on.

[0063] Step 204: Based on the first processing result and the second processing result, determine whether a preset first correction condition is satisfied;

[0064] Here, the first correction condition is used to determine whether the error between the first processing result and the second processing result is within the allowable first error range. If it is within the allowable first error range, it is determined that the calibration parameters do not need to be corrected; if it exceeds the allowable first error range, it is determined that the calibration parameters need to be corrected.

[0065] In some embodiments, the determining whether a preset first correction condition is met includes: determining a first error value between the first processing result and the second processing result; when the first error value is greater than or equal to a first error threshold, determining that the first correction condition is met; when the first error value is less than the first error threshold, determining that the first correction condition is not met.

[0066] Here, the first error value may be determined based on pixel information in the two results. For example, when the processing result is depth information, the error value is obtained based on depth information of the same pixel point in the two results.

[0067] In some embodiments, when the feature image processing is image depth information calculation, the first processing result and the second processing result are image depth information;

[0068] The determining of the first error value between the first processing result and the second processing result includes: blurring the target image based on the first processing result to obtain a first blurring result; blurring the target image based on the second processing result to obtain a second blurring result; and determining the first error value between the first blurring result and the blurred second blurring result.

[0069] It should be noted that, since the blur processing result can better reflect the image processing effect, the blur processing result can be compared to determine whether the calibration information needs to be corrected.

[0070] Step 205: Determine whether the first correction condition is satisfied, and correct the calibration parameters of the camera based on the first processing result.

[0071] Here, the calibration parameters may be original calibration parameters at the time of leaving the factory or correction parameters obtained during the last correction.

[0072] Here, since the first processing result has higher accuracy, the calibration parameters of the camera can be reversely corrected according to the first processing result.

[0073] In some embodiments, the correcting the calibration parameters of the camera based on the first processing result includes: obtaining first correction parameters of the camera based on the first processing result; re-performing a first correction judgment operation based on the first correction parameters until it is determined that the first correction condition is not met; using the first correction parameters corresponding to when the first correction condition is not met as second correction parameters; and correcting the calibration parameters using the second correction parameters.

[0074] Here, the first correction judgment operation indicates re-executing step 201 to step 205 until it is determined that the first correction condition is not satisfied, at which time it can be considered that the error between the current first processing result and the second processing result is within the allowable error range.

[0075] In some embodiments, the method further includes: determining that the first correction condition is not satisfied, if there is a correction operation, using the current first correction parameter as the second correction parameter, and correcting the calibration parameter using the second correction parameter; if there is no correction operation, keeping the calibration parameters of the camera unchanged.

[0076] It should be noted that the camera parameter correction method provided in the embodiments of the present application can be applied to electronic devices with camera functions, and the electronic devices may include mobile phones, tablet computers, laptop computers, PDAs, portable media players (PMPs), wearable devices, cameras, etc.

[0077] By adopting the above technical solution, the image processing result of the first processing model is used as an evaluation criterion of the camera's inherent second processing model. When the first processing result and the second processing result meet the correction conditions, for example, there is a large difference between the two, the more accurate first processing result is used to correct the calibration parameters of the camera, and the corrected parameters are used for image processing, which can improve the image processing effect of the camera.

[0078] In order to better reflect the purpose of this application, based on the above embodiments of this application, the parameter correction process is further illustrated by examples. Figure 3 As shown, the method specifically includes:

[0079] Step 301: Acquire a target image captured by a camera;

[0080] In some embodiments, the method further comprises: pre-caching the target image.

[0081] In some embodiments, acquiring the target image captured by the camera includes: when the camera is in an idle state, acquiring a cached target image to perform a calibration parameter correction operation.

[0082] In some embodiments, when re-making the correction judgment, the method further includes: acquiring the target image re-captured by the camera; and performing specific image processing on the re-captured target image using the first processing model and the second processing model respectively.

[0083] Step 302: performing specific image processing on the target image using a first processing model to obtain a first processing result of the target image;

[0084] Here, the specific image processing process of the first processing model is not related to the calibration parameters of the camera. It can be understood that the input variables of the first processing model include the target image to be processed, but do not include the calibration parameters.

[0085] It should be noted that the first processing result can be used as an evaluation criterion for the image processing effect of the second processing model. If the second processing result is close to or consistent with the first processing result, it can be determined that the image processing accuracy of the second processing model is higher, and there is no need to correct the calibration parameters; otherwise, the calibration parameters need to be corrected. The image processing process of the first processing model is not only unrelated to the calibration parameters, but also has a higher accuracy for image processing. Exemplarily, the first processing model is a neural network model established based on a neural network algorithm.

[0086] Step 303: configuring the forward input parameters of the second processing model when performing forward operation;

[0087] It should be noted that, when the first correction determination operation is performed for the first time, the method includes: obtaining calibration parameters of the camera; and using the calibration parameters as positive input parameters of the second processing model.

[0088] That is to say, when the second processing model starts to execute the first correction judgment operation, it uses the camera's original calibration parameters to perform image processing. During the first correction judgment operation, if the first correction condition is never met, that is, the second processing model always has a more accurate image processing result using the original calibration parameters, then the forward input parameters are always the original calibration parameters.

[0089] In some embodiments, the method further includes: when a first correction condition is satisfied, obtaining a first correction parameter of the camera based on the first processing result; and using the first correction parameter as a forward input parameter of the second processing model.

[0090] It should be noted that when performing the correction operation, if the first correction condition is met, it means that the original calibration parameters need to be corrected, and the first correction parameters will be obtained. In order to verify the accuracy of the first correction parameters, the first correction parameters need to be used as the forward input parameters of the second processing model for actual verification. Therefore, the first correction judgment operation needs to be re-performed. At this time, the first correction parameters need to be temporarily used as the forward input parameters, and the second processing model performs forward operations to perform specific image processing on the input image.

[0091] It should be noted that the first correction parameter of the first correction judgment operation is only temporarily used as a positive input parameter. At this time, the calibration parameters of the camera are still the original calibration parameters or the correction parameters obtained in the last correction. Before the corrected calibration parameters are confirmed, if the camera is in working state, the second processing model still performs normal image processing operations based on the calibration parameters.

[0092] The first correction judgment operation can be performed when the camera is in an idle state, for example, the camera is in a sleep mode for offline operation, so as to avoid occupying normal processing resources of the camera.

[0093] Step 304: performing specific image processing on the target image using a second processing model to obtain a second processing result of the target image;

[0094] Here, the specific image processing process of the second processing model is related to the calibration parameters of the camera. It can be understood that the input variables of the first processing model include the target image to be processed and the calibration parameters.

[0095] Step 305: Based on the first processing result and the second processing result, determine whether a preset first correction condition is satisfied; if yes, execute step 307; if no, execute step 306;

[0096] In some embodiments, the determining whether a preset first correction condition is met includes: determining a first error value between the first processing result and the second processing result; when the first error value is greater than or equal to a first error threshold, determining that the first correction condition is met; when the first error value is less than the first error threshold, determining that the first correction condition is not met.

[0097] Step 306: determining that the first correction condition is not satisfied, taking the current first correction parameter as the second correction parameter, and correcting the calibration parameter using the second correction parameter;

[0098] Step 306 can be understood as: determining that the first correction condition is not satisfied, and using the current forward input parameter of the second processing model as the second correction parameter.

[0099] It should be noted that, during the first correction judgment operation, if the first correction condition is not satisfied, that is, the second processing model always has a more accurate image processing result using the original calibration parameters, then the forward input parameters are always the original calibration parameters. At this time, the forward input parameters are the calibration parameters of the camera, and step 306 can be replaced by: determining that the first correction condition is not satisfied, and keeping the calibration parameters of the camera unchanged.

[0100] It should be noted that during the first correction judgment operation, if the first correction condition is met, the first correction parameter is obtained, and after obtaining the first correction parameter that finally makes the first processing result and the second processing result close to each other through multiple iterative corrections, the first correction parameter finally obtained is used as the second correction parameter to correct the calibration parameter of the camera. At this time, the forward input parameter is the first correction parameter.

[0101] In some embodiments, using the second correction parameter to correct the calibration parameter includes: using the second correction parameter to replace the calibration parameter. In other words, using the second correction parameter obtained by the first correction judgment operation to directly replace the current calibration parameter.

[0102] In other embodiments, the calibration parameters are corrected using the second correction parameter, including: performing a second correction judgment operation based on the second correction parameter until it is determined that the second correction condition is not met; using the second correction parameter corresponding to when the second correction condition is not met as a third correction parameter; and correcting the calibration parameters using the third correction parameter.

[0103] Here, the second correction condition is used to determine whether the error between the third processing result and the standard processing result obtained when the second processing model uses the second correction parameter to perform image processing is within the allowable second error range. If it is within the allowable second error range, it is determined that there is no need to correct the calibration parameters. If it exceeds the allowable second error range, it is determined that the calibration parameters need to be corrected. Here, the first error range and the second error range can be the same, and the second error range can also be smaller than the first error range, so as to ensure that the corrected calibration parameters are more accurate.

[0104] That is to say, the second correction parameter obtained by the first correction judgment operation can be further verified, and the current calibration parameter is replaced only after the verification is passed, so as to further improve the accuracy of the calibration parameter and the image processing effect. This point will be further illustrated in the next embodiment.

[0105] Step 307: Determine whether the first correction condition is satisfied, and obtain a first correction parameter of the camera based on the first processing result;

[0106] In some embodiments, the first processing result is used as a reverse input parameter of the second processing model; the second processing model is reversely operated based on the reverse input parameter, and a first correction parameter is reversely output.

[0107] In other words, the original output parameters of the second processing model become known quantities, and the input parameters become unknown quantities. The input parameters can be obtained through reverse calculation.

[0108] Step 308: Use the first correction parameter as a positive input parameter of the second processing model and return to step 303.

[0109] That is to say, after obtaining the first correction parameter, in order to verify the accuracy of the first correction parameter, the first correction parameter needs to be used as a forward input parameter of the second processing model for actual verification, so the first correction judgment operation needs to be re-performed. At this time, the first correction parameter needs to be temporarily used as a forward input parameter, and the second processing model performs a forward operation to perform specific image processing on the input image.

[0110] By adopting the above technical solution, the image processing result of the first processing model is used as an evaluation criterion of the camera's inherent second processing model. When the first processing result and the second processing result meet the correction conditions, for example, there is a large difference between the two, the more accurate first processing result is used to correct the calibration parameters of the camera, and the corrected parameters are used for image processing, which can improve the image processing effect of the camera.

[0111] In order to better reflect the purpose of this application, based on the above embodiments of this application, the parameter correction process is further illustrated by examples. Figure 4 As shown, the method specifically includes:

[0112] Step 301: Acquire a target image captured by a camera;

[0113] Step 302: performing specific image processing on the target image using a first processing model to obtain a first processing result of the target image;

[0114] Step 303: configuring the forward input parameters of the second processing model when performing forward operation;

[0115] Step 304: performing specific image processing on the target image using a second processing model to obtain a second processing result of the target image;

[0116] Step 305: Based on the first processing result and the second processing result, determine whether a preset first correction condition is satisfied; if yes, execute step 307; if no, execute step 306;

[0117] Step 306: determining that the first correction condition is not satisfied, and using the current first correction parameter as the second correction parameter;

[0118] Correcting the calibration parameter using the second correction parameter may specifically include:

[0119] Step 401: Acquire a standard image and a corresponding standard processing result;

[0120] Here, the standard image and the corresponding standard processing result can be pre-stored in the camera storage unit, and serve as a standard for verifying the correction parameters when the current calibration parameters need to be corrected.

[0121] Step 402: using the second correction parameter as a positive input parameter of the second processing model;

[0122] At this time, the second correction parameter needs to be temporarily used as a forward input parameter, and the second processing model performs a forward operation to perform specific image processing on the input standard image.

[0123] Step 403: performing specific image processing on the standard image using the second processing model to obtain a third processing result of the standard image;

[0124] Step 404: Based on the third processing result and the standard processing result, determine whether the second correction condition is satisfied; if yes, execute step 405; if no, execute step 406;

[0125] Here, the second correction condition is used to determine whether the error between the third processing result and the standard processing result obtained when the second processing model uses the second correction parameter to perform image processing is within the allowable second error range. If it is within the allowable second error range, it is determined that there is no need to correct the calibration parameters. If it exceeds the allowable second error range, it is determined that the calibration parameters need to be corrected. Here, the first error range and the second error range can be the same, and the second error range can also be smaller than the first error range, so as to ensure that the corrected calibration parameters are more accurate.

[0126] In some embodiments, the judging whether the second correction condition is met includes: determining a second error value between the third processing result and the standard processing result; when the second error value is greater than or equal to a second error threshold, determining that the second correction condition is met; when the second error value is less than the second error threshold, determining that the second correction condition is not met.

[0127] Step 405: determine that the second correction condition is satisfied, use the second correction parameter as a positive input parameter, and return to step 303;

[0128] Here, returning to step 303 can be understood as re-performing the first correction determination operation and the second correction determination operation based on the second correction parameter until it is determined that the second correction condition is not satisfied.

[0129] Step 406: Correct the calibration parameter using the third correction parameter.

[0130] In some embodiments, the correcting the calibration parameter using the third correction parameter includes: replacing the calibration parameter with the third correction parameter.

[0131] Step 307: Determine whether the first correction condition is satisfied, and obtain a first correction parameter of the camera based on the first processing result;

[0132] Step 308: Use the first correction parameter as a positive input parameter of the second processing model and return to step 303.

[0133] By adopting the above technical solution, the image processing result of the first processing model is used as an evaluation criterion of the camera's inherent second processing model. When the first processing result and the second processing result meet the correction conditions, for example, there is a large difference between the two, the more accurate first processing result is used to correct the calibration parameters of the camera, and the corrected parameters are used for image processing, which can improve the image processing effect of the camera.

[0134] The following is a further explanation using a dual-camera as an example.

[0135] like Figure 5 As shown, for a dual-camera, when calculating depth information, two cameras (with consistent camera parameters) with an appropriate distance between them and parallel optical axes are considered (analogous to human eyes), and the same object point M (for the convenience of discussion, it is assumed that the object point M is located to the left of the left camera). When imaging with the two cameras, M1 is the image point of the object point M in the image plane of the right camera, M2 is the image point of the object point M in the image plane of the left camera, O1 is the optical center of the right camera, and O2 is the optical center of the left camera.

[0136] Take it out separately Figure 5 From the perspective of the left and right imaging planes, Figure 6 As shown, I1 and I2 are the centers of the left and right image planes (i.e., the projections of the optical centers of the left and right cameras on the image planes, respectively). The coordinate systems are established with I1 and I2 as the coordinate centers. From geometric knowledge, we know that O1O2 is parallel to I1I2, which can be expressed as O1O2||I1I2, O1O2||M1M2, so M1M2||I1I2.

[0137] Looking at the plane MM1M2 alone ( Figure 5 Shaded part), it is easy to know that ΔMO1O2 is similar to ΔMM1M2, so according to the triangle similarity principle: MO1 / MM1=O1O2 / M1M2.

[0138] Assume that the horizontal coordinate components of M1 and M2 in the corresponding image plane are x1 and x2, respectively, then:

[0139] M1M2=I2I1+x2-x1

[0140] If the distance between the optical centers of the two cameras is defined as the baseline distance, denoted as b=I1I2, (x2-x1) is the parallax of the same object point on the two image planes, denoted as d. The above formula can be simplified to:

[0141] M1M2=b+d

[0142] Then further derive the formula:

[0143] MO1 / MM1=MO1 / (MO1+O1M1)=b / (b+d)

[0144] can be simplified to:

[0145] MO1 / O1M1=b / d

[0146] Now let's look at the correspondence between the object point M and its image point M1 on the image plane of the right camera. Take the optical center O1 of the right camera as the coordinate origin, as follows: Figure 7 The world coordinate system is established as shown.

[0147] The coordinate transformation relationship between the camera imaging coordinate system and the world coordinate system where the optical center is located. Through this image, we can easily obtain the depth of field information Z:

[0148] Z / O1I1=MO1 / O1M1=b / d

[0149] Z = (b*f) / d (f: focal length of the camera). From this, we can restore the depth of field information of the target M.

[0150] like Figure 8 As shown, the method for revising the calibration parameters of the dual-camera may specifically include:

[0151] Step 801: Turn on the camera;

[0152] Step 802: Start image acquisition, cache the acquired image data, and prepare for offline depth information calculation;

[0153] Here, the image format may be a RAW format.

[0154] Step 803: Send the collected image data to the front-end NN network for depth information calculation;

[0155] Here, the NN network can be regarded as the first processing model, namely the neural network (NN).

[0156] The focus of the processing based on the front-end NN network is to use the characteristics of the algorithm in the NN network that is not affected by the camera calibration parameters (the camera calibration parameters are not used) to calculate more accurate depth information corresponding to the image.

[0157] It should be noted that there are many ways to calculate depth information using the NN network. It can be based on principles similar to AI or deep learning blur, or it can be based on the blur effect of historical frames. The purpose is to obtain more accurate image depth information, which is conducive to the subsequent correction of the camera calibration information through comparison.

[0158] Step 804: blurring the image according to the depth information obtained by the NN network to obtain a first blurring result;

[0159] Step 805: Obtain camera calibration parameters as forward input parameters of the traditional image algorithm;

[0160] Step 806: sending the collected image data to a traditional image algorithm to calculate depth information;

[0161] Here, the traditional image algorithm can be regarded as the algorithm applied by the second processing model. The traditional depth information calculation algorithm based on dual-camera data calculates the depth information of the data frame at the same time (using the calibration parameters of the camera).

[0162] Step 807: blurring the image according to the depth information obtained by the traditional image algorithm to obtain a second blurring result;

[0163] Here, the depth information obtained by the two methods is used to blur the image using the same blurring algorithm.

[0164] Step 808: Compare the first blurring result with the second blurring result;

[0165] Step 809: Determine whether the error of the comparison result is less than d; if yes, execute step 810; if no, return to step 802;

[0166] Analyze the accuracy of the blur results obtained based on the two depth information (generally speaking, due to the change of camera calibration parameters, the accuracy of the traditional method will be lower than that obtained by the NN network method); reversely correct the camera calibration parameters based on the more accurate depth information, so that the depth information calculated by the traditional method based on the new calibration parameters gradually approaches the result calculated based on the NN;

[0167] Here, when the error is greater than or equal to d, it is necessary to first perform a reverse correction to obtain a correction parameter, and then use the correction parameter to re-perform a correction judgment.

[0168] Step 810: using the corrected camera calibration parameters as camera calibration parameters;

[0169] Step 811: applying the camera calibration parameters to subsequent image algorithm processing;

[0170] Step 812: Record video, take photo or preview.

[0171] In the process of using depth information to correct parameters, since the main purpose is to obtain more accurate results and there is no strong timeliness requirement, the image data at a certain moment can be cached, and when the system resources are sufficient or idle, two methods (front-end NN network and back-end traditional image algorithm using camera calibration parameters) are used to calculate the depth information of the same data (based on the given accuracy standard); then the depth information obtained by the two calculations are compared, and the image is blurred based on the depth information obtained by the two methods (the image after blurring can also be analyzed to determine which parameter based blurring effect is more accurate); according to the comparison results, the camera calibration parameters (such as the position information between the lenses) are reversely corrected, and then the depth information and blur are reprocessed according to the corrected calibration information until the accuracy is close to the standard result;

[0172] Of course, the correction process of the camera calibration parameters can also be carried out by processing a new frame based on one correction, and then iteratively correcting it again (that is, the image processed by each correction will also be updated (for example, after generating a new stage correction parameter, a new frame of image data will be collected as the processing object), and one image will not be processed all the time) (it is also an iterative convergence process) until the results of the two processing methods are consistent, and then the camera calibration parameters at the time of consistency are used as new calibration parameters; finally, the correction of the camera-related calibration parameters is completed.

[0173] Fig. 9 Schematic diagram of the corrected convergence curve in the embodiment of the present application, such as Fig. 9 As shown, the horizontal axis is the number of iterations, and the vertical axis is the calibration parameter. As the number of iterations increases, the calibration parameters obtained are getting closer and closer to the accurate values.

[0174] As the camera components age and collide, the characteristics of the lens and sensor may change, and the relative position of the lens may change, resulting in the mismatch between the original camera calibration parameters and the camera sensor characteristics. Therefore, when the camera is working, the front-end NN network can be used to calculate the depth information of the corresponding frame in a high-precision offline manner at a fixed time (such as the first frame each time it is turned on) (the calculation method and calculation parameters can be fixed according to the standard after the two calculation methods are corrected at the factory (which is conducive to using this as the original accuracy standard for subsequent corrections)); at the same time, the dual-camera data is used to calculate the depth information of the first frame based on the original camera calibration information, and finally the depth information obtained by the two calculation methods is compared. The depth information obtained by the NN network is used as a reference to feedback and correct the calibration parameters of the original camera; the camera then uses the corrected calibration parameters to calculate the depth information of subsequent frames until the error between the two reaches a certain range, and the camera calibration information is considered to be corrected. Note that both the high-precision processing of the depth information by the front end and the subsequent step-by-step correction process can be performed offline, in order to obtain accurate depth information without affecting the overall working performance of the camera (such as frame rate).

[0175] It should be noted that the embodiments of the present application can not only use depth information to correct the calibration parameters, but also can correct the original calibration parameters by comparing with other image processing results. For example, the original image distortion parameters can be corrected by comparing the image distortion processing results. The calibration parameters of the camera are prone to deviations as the usage time increases. According to the comparison of the two different processing methods, the parameters are adjusted in reverse to finally obtain calibration parameters that are more suitable for the current camera.

[0176] In practical applications, the calibration parameters can be corrected each time the camera is turned on, or a time can be set to correct the parameters every certain period of time (such as several days or months) to save system resources and reduce the impact on camera use.

[0177] It should be noted that the correction method provided in the embodiment of the present application can also be applied to the parameter revision of a monocular or multi-eye camera, and is not limited to a binocular camera.

[0178] To implement the method of the embodiment of the present application, based on the same inventive concept, the embodiment of the present application also provides a camera parameter correction device, such as Fig.10 As shown, the device comprises:

[0179] An acquisition unit 1001 is used to acquire a target image captured by a camera;

[0180] The processing unit 1002 is configured to perform specific image processing on the target image using a first processing model to obtain a first processing result of the target image; and perform specific image processing on the target image using a second processing model to obtain a second processing result of the target image;

[0181] A judging unit 1003, configured to judge whether a preset first correction condition is satisfied based on the first processing result and the second processing result;

[0182] The correction unit 1004 is used to determine whether the first correction condition is satisfied, and correct the calibration parameters of the camera based on the first processing result.

[0183] In some embodiments, the specific image processing process of the first processing model is not related to the calibration parameters of the camera, and the specific image processing process of the second processing model is related to the calibration parameters of the camera.

[0184] In some embodiments, the first processing model is a neural network model established based on a neural network algorithm.

[0185] In some embodiments, the processing unit 1002 is further used to configure forward input parameters when the second processing model performs forward operations.

[0186] In some embodiments, the processing unit 1002 is further configured to obtain calibration parameters of the camera; and use the calibration parameters as forward input parameters of the second processing model.

[0187] In some embodiments, the correction unit 1004 is further configured to obtain a first correction parameter of the camera based on the first processing result;

[0188] The processing unit 1002 is further configured to re-perform the first correction determination operation based on the first correction parameter until it is determined that the first correction condition is not satisfied;

[0189] The correction unit 1004 is further configured to use the first correction parameter corresponding to the condition that the first correction condition is not satisfied as the second correction parameter; and use the second correction parameter to correct the calibration parameter.

[0190] In some embodiments, the correction unit 1004 is specifically configured to use the first processing result as a reverse input parameter of the second processing model; perform reverse operation on the second processing model based on the reverse input parameter, and reversely output a first correction parameter.

[0191] In some embodiments, the processing unit 1002 is specifically configured to use the first correction parameter as a positive input parameter of the second processing model when re-performing the first correction judgment operation based on the first correction parameter.

[0192] In some embodiments, the correction unit 1004 is specifically used to perform a second correction judgment operation based on the second correction parameter until it is determined that the second correction condition is not met; use the second correction parameter corresponding to when the second correction condition is not met as the third correction parameter; and use the third correction parameter to correct the calibration parameter.

[0193] In some embodiments, the correction unit 1004 is further configured to, when performing the second correction judgment operation based on the second correction parameter, obtain a standard image and a corresponding standard processing result; use the second correction parameter as a positive input parameter of the second processing model; perform specific image processing on the standard image using the second processing model to obtain a third processing result of the standard image;

[0194] The correction unit 1004 is further configured to determine whether the second correction condition is satisfied based on the third processing result and the standard processing result;

[0195] The correction unit 1004 is further configured to determine whether the second correction condition is satisfied, and re-perform the first correction determination operation and the second correction determination operation based on the second correction parameter until it is determined that the second correction condition is not satisfied.

[0196] In some embodiments, the correction unit 1004 is specifically used to determine a second error value between the third processing result and the standard processing result; when the second error value is greater than or equal to a second error threshold, it is determined that the second correction condition is met; when the second error value is less than the second error threshold, it is determined that the second correction condition is not met.

[0197] In some embodiments, the correction unit 1004 is specifically configured to replace the calibration parameter with the third correction parameter.

[0198] In some embodiments, the acquisition unit 1001 is further configured to acquire the target image recaptured by the camera when the first correction judgment operation is performed again;

[0199] The processing unit 1002 is further configured to perform specific image processing on the re-captured target image using the first processing model and the second processing model respectively.

[0200] In some embodiments, the processing unit 1002 is specifically used to perform specific image processing on the target image using a first processing model to obtain an initial processing result of the target image; obtain a first processing result of a related image; wherein the related image is correlated with the target image; and use the first processing result of the related image to correct the initial processing result to obtain the first processing result of the target image.

[0201] In some embodiments, the judgment unit 1003 is specifically used to determine a first error value between the first processing result and the second processing result; when the first error value is greater than or equal to a first error threshold, it is determined that the first correction condition is met; when the first error value is less than the first error threshold, it is determined that the first correction condition is not met.

[0202] In some embodiments, the feature image processing includes at least one of the following: image depth information calculation, image blur processing, image noise reduction processing, and image correction processing.

[0203] In some embodiments, when the feature image processing is image depth information calculation, the first processing result and the second processing result are image depth information;

[0204] The judgment unit 1003 is specifically used to blur the target image based on the first processing result to obtain a first blur processing result; blur the target image based on the second processing result to obtain a second blur processing result; and determine a first error value between the first blur processing result and the blurred second blur processing result.

[0205] In some embodiments, the apparatus further comprises a storage unit for pre-caching the target image;

[0206] The acquisition unit 1001 is specifically configured to acquire a cached target image when the camera is in an idle state, so as to perform a calibration parameter correction operation.

[0207] In some embodiments, the calibration parameters include at least one of the following: position parameters between lenses, camera intrinsic parameters, camera extrinsic parameters, and camera distortion parameters.

[0208] Based on the hardware implementation of each unit in the above device, the embodiment of the present application also provides an electronic device, such as Fig.11 As shown, the electronic device includes: a processor 1101 and a memory 1102 configured to store a computer program that can be run on the processor;

[0209] The processor 1101 is configured to execute the method steps in the aforementioned embodiment when running a computer program.

[0210] Of course, in practical applications, Fig.11 As shown, the various components in the electronic device are coupled together via a bus system 1103. It is understood that the bus system 1103 is used to realize the connection and communication between these components. In addition to the data bus, the bus system 1103 also includes a power bus, a control bus, and a status signal bus. However, for the sake of clarity, Fig.11Various buses are labeled as bus system 1103.

[0211] In practical applications, the processor may be at least one of an application-specific integrated circuit (ASIC), a digital signal processing device (DSPD), a programmable logic device (PLD), a field-programmable gate array (FPGA), a controller, a microcontroller, and a microprocessor. It is understandable that for different devices, the electronic device used to implement the functions of the processor may also be other, and the embodiments of the present application do not specifically limit this.

[0212] The above-mentioned memory can be a volatile memory (volatile memory), such as a random access memory (RAM); or a non-volatile memory (non-volatile memory), such as a read-only memory (ROM), a flash memory, a hard disk (HDD) or a solid-state drive (SSD); or a combination of the above-mentioned types of memory, and provide instructions and data to the processor.

[0213] By using the above-mentioned device or electronic device, by adding a first processing model to the camera, the image processing result of the first processing model is used as an evaluation criterion of the camera's inherent second processing model. When the first processing result and the second processing result meet the correction conditions, for example, the difference between the two is large, the more accurate first processing result is used to correct the calibration parameters of the camera, and the corrected parameters are used for image processing, which can improve the image processing effect of the camera.

[0214] In an exemplary embodiment, the embodiment of the present application further provides a computer-readable storage medium, such as a memory including a computer program, and the computer program can be executed by a processor of an electronic device to complete the steps of the aforementioned method.

[0215] It should be understood that the terms used in the present application are only for the purpose of describing specific embodiments, but are not intended to limit the present application. The singular forms of "a", "said" and "the" used in the present application and the appended claims are also intended to include plural forms, unless the context clearly indicates other meanings. It should also be understood that the term "and / or" used in this article refers to and includes any or all possible combinations of one or more associated listed items. The expressions "having", "may have", "include" and "include", or "may include" and "may include" in this application can be used to indicate the presence of corresponding features (e.g., elements such as numerical values, functions, operations or components), but the presence of additional features is not excluded.

[0216] It should be understood that although the terms first, second, third, etc. may be used in this application to describe various information, such information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other and are not necessarily used to describe a specific order or sequence. For example, without departing from the scope of the present invention, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information.

[0217] The technical solutions described in the embodiments of the present application can be combined arbitrarily without conflict.

[0218] In the several embodiments provided in the present application, it should be understood that the disclosed methods, devices and equipment can be implemented in other ways. The embodiments described above are only schematic. For example, the division of units is only a logical function division. There may be other division methods in actual implementation, such as: multiple units or components can be combined, or can be integrated into another system, or some features can be ignored or not executed. In addition, the coupling, direct coupling, or communication connection between the components shown or discussed can be through some interfaces, and the indirect coupling or communication connection of devices or units can be electrical, mechanical or other forms.

[0219] The units described above as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units; some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.

[0220] In addition, all functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may be a separate unit, or two or more units may be integrated into one unit; the above-mentioned integrated units may be implemented in the form of hardware or in the form of hardware plus software functional units.

[0221] The above description is only a specific implementation manner of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application.

Claims

1. A camera parameter correction method, characterized in that: The method comprises: Get the target image captured by the camera; Performing image processing on the target image using a first processing model to obtain a first processing result of the target image, wherein the image processing process of the first processing model is irrelevant to the calibration parameters of the camera; Performing image processing on the target image using a second processing model to obtain a second processing result of the target image, wherein the image processing process of the second processing model is related to the calibration parameters of the camera; Based on the first processing result and the second processing result, determining whether a preset first correction condition is met; Determining that the first correction condition is satisfied, and obtaining a first correction parameter of the camera based on the first processing result; re-performing the first correction determination operation based on the first correction parameter until it is determined that the first correction condition is not satisfied; using the first correction parameter corresponding to when the first correction condition is not satisfied as the second correction parameter; The calibration parameter is corrected using the second correction parameter.

2. The method according to claim 1, characterized in that The first processing model is a neural network model established based on a neural network algorithm.

3. The method according to claim 1, characterized in that Before performing image processing on the target image using the second processing model, the method further includes: Configure the forward input parameters of the second processing model when performing forward operation.

4. The method according to claim 3, characterized in that The method further comprises: Obtaining calibration parameters of the camera; The calibration parameters are used as forward input parameters of the second processing model.

5. The method according to claim 1, characterized in that The obtaining a first correction parameter of the camera based on the first processing result includes: Using the first processing result as a reverse input parameter of the second processing model; The second processing model is reversely operated based on the reverse input parameter to reversely output the first correction parameter.

6. The method according to claim 1, characterized in that The re-performing the first correction judgment operation based on the first correction parameter includes: The first correction parameter is used as a forward input parameter of the second processing model.

7. The method according to claim 1, characterized in that The step of correcting the calibration parameter by using the second correction parameter comprises: performing a second correction determination operation based on the second correction parameter until it is determined that the second correction condition is not satisfied; using the second correction parameter corresponding to when the second correction condition is not satisfied as the third correction parameter; The calibration parameter is corrected using the third correction parameter.

8. The method according to claim 7, characterized in that The performing a second correction judgment operation based on the second correction parameter includes: Obtain standard images and corresponding standard processing results; using the second correction parameter as a positive input parameter of the second processing model; performing image processing on the standard image using the second processing model to obtain a third processing result of the standard image; Based on the third processing result and the standard processing result, determining whether the second correction condition is satisfied; It is determined that the second correction condition is satisfied, and the first correction determination operation and the second correction determination operation are re-performed based on the second correction parameter until it is determined that the second correction condition is not satisfied.

9. The method according to claim 8, characterized in that The determining whether the second correction condition is satisfied includes: determining a second error value between the third processing result and the standard processing result; When the second error value is greater than or equal to a second error threshold, determining that the second correction condition is satisfied; When the second error value is less than the second error threshold, it is determined that the second correction condition is not satisfied.

10. The method according to claim 7, characterized in that The step of correcting the calibration parameter by using the third correction parameter comprises: The calibration parameter is replaced by the third correction parameter.

11. The method according to claim 1, characterized in that: When the first correction judgment operation is performed again, the method further includes: Acquire a target image recaptured by the camera; The first processing model and the second processing model are used to perform image processing on the re-captured target image respectively.

12. The method according to claim 1, characterized in that The step of performing image processing on the target image using the first processing model to obtain a first processing result of the target image includes: Performing image processing on the target image using the first processing model to obtain an initial processing result of the target image; Acquire a first processing result of a related image; wherein the related image is correlated with the target image; The initial processing result is corrected using the first processing result of the related image to obtain the first processing result of the target image.

13. The method according to claim 1, characterized in that The determining whether the preset first correction condition is satisfied includes: determining a first error value between the first processing result and the second processing result; When the first error value is greater than or equal to a first error threshold, determining that the first correction condition is satisfied; When the first error value is less than the first error threshold, it is determined that the first correction condition is not satisfied.

14. The method according to claim 13, characterized in that The image processing includes at least one of the following: image depth information calculation, image blur processing, image noise reduction processing, and image correction processing.

15. The method according to claim 14, characterized in that When the image processing is image depth information calculation, the first processing result and the second processing result are image depth information; The determining a first error value between the first processing result and the second processing result includes: Performing blur processing on the target image based on the first processing result to obtain a first blur processing result; Performing blur processing on the target image based on the second processing result to obtain a second blur processing result; A first error value between the first blurring result and the second blurring result is determined.

16. The method according to claim 1, characterized in that The method further comprises: Pre-caching the target image; The step of acquiring a target image captured by a camera comprises: When the camera is in idle state, the cached target image is obtained to perform calibration parameter correction operations.

17. The method according to claim 1, characterized in that The calibration parameters include at least one of the following: position parameters between lenses, camera intrinsic parameters, camera extrinsic parameters, and camera distortion parameters.

18. A camera parameter correction device, characterized in that: The device comprises: An acquisition unit, used for acquiring a target image captured by a camera; a processing unit, configured to perform image processing on the target image using a first processing model to obtain a first processing result of the target image; and perform image processing on the target image using a second processing model to obtain a second processing result of the target image; the image processing process of the first processing model is irrelevant to the calibration parameters of the camera, and the image processing process of the second processing model is relevant to the calibration parameters of the camera; a judging unit, configured to judge whether a preset first correction condition is satisfied based on the first processing result and the second processing result; A correction unit, configured to determine whether the first correction condition is satisfied, and obtain a first correction parameter of the camera based on the first processing result; The processing unit is further configured to re-perform the first correction determination operation based on the first correction parameter until it is determined that the first correction condition is not satisfied; The correction unit is further used to use the first correction parameter corresponding to the condition that the first correction condition is not satisfied as the second correction parameter; and use the second correction parameter to correct the calibration parameter.

19. An electronic device, characterized in that: The electronic device comprises: a processor and a memory configured to store a computer program capable of running on the processor, Wherein, the processor is configured to execute the steps of the method described in any one of claims 1 to 17 when running the computer program.

20. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 17 are implemented.

Citation Information

Patent Citations

  • Calibration method and system for panoramic camera, computer device and storage medium

    CN109166152A