Model conversion method, device and equipment for vehicle-mounted camera

By building a virtual space calibration board and a virtual camera in the virtual space, the second imaging model parameters are obtained using fitting technology to achieve quick conversion between different camera models, solving the problem of cumbersome model conversion in the existing technology and improving efficiency.

CN120070594APending Publication Date: 2025-05-30CHERY AUTOMOBILE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510232172.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-28
Publication Date
2025-05-30

AI Technical Summary

Technical Problem

In the prior art, the conversion process of vehicle-mounted camera models is cumbersome and manual calibration is required to obtain model parameters of other camera models.

Method used

By constructing a virtual space calibration board and a virtual camera in the virtual space, using the first imaging model to collect and convert multiple three-dimensional spatial points, fit according to the three-dimensional and two-dimensional coordinates, the second imaging model parameters are obtained, thereby establishing a second imaging model and achieving quick conversion between different camera models.

Benefits of technology

Fast conversion between different camera models can be achieved without manual calibration, simplifying the model conversion process and improving efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120070594A_ABST
    Figure CN120070594A_ABST
Patent Text Reader

Abstract

The invention provides a vehicle-mounted camera model conversion method, and belongs to the field of camera calibration. A virtual space calibration board and a virtual camera using a first imaging model are constructed in a virtual space; a plurality of three-dimensional space points on a virtual space calibration plate are collected by a virtual camera, a corresponding two-dimensional image projection is obtained through conversion by a first imaging model, and fitting is carried out according to a plurality of three-dimensional coordinates of the plurality of three-dimensional space points of the virtual space calibration plate and a plurality of two-dimensional coordinates of a two-dimensional image. And performing reverse solution to obtain a second imaging model parameter, thereby establishing a second imaging model by using the second imaging model parameter, realizing quick conversion between the first imaging model and the second imaging model, and realizing model conversion without performing manual calibration on a camera.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of camera calibration, and particularly to a method and device for converting a vehicle-mounted camera model. Background Art

[0002] With the progress of technology and the rapid development of the automotive manufacturing industry, more and more vehicle models are equipped with vehicle-mounted cameras, so as to display reverse images or 360-degree panoramic images on the central control screen, and even used to achieve higher-level assisted driving.

[0003] In order to obtain the projection relationship between the three-dimensional coordinate system and the two-dimensional picture coordinate system of the vehicle-mounted camera, so as to analyze the images collected by the vehicle-mounted camera, it is necessary to obtain the camera model parameters. Typical models include the pinhole model and the equidistant fisheye model.

[0004] Camera module manufacturers generally provide camera model parameters, but usually only provide one type of camera model parameters. If the automotive manufacturer uses other camera models, the camera needs to be manually calibrated to obtain the model parameters of other camera models, and the calibration process is very cumbersome. Summary of the Invention

[0005] In view of this, this application provides a method, device and vehicle for converting a vehicle-mounted camera model, which can realize the rapid conversion between different camera models.

[0006] On the one hand, this application provides a method for converting a vehicle-mounted camera model, and the method includes:

[0007] Construct a virtual space calibration board and a virtual camera in the virtual space, and the virtual camera adopts a first imaging model.

[0008] Determine the multiple three-dimensional coordinates corresponding to multiple three-dimensional space points in the virtual space calibration board.

[0009] Use the virtual camera to collect images of multiple three-dimensional space points, and use the first imaging model to convert the multiple three-dimensional coordinates to obtain corresponding two-dimensional images, and the two-dimensional images include multiple two-dimensional coordinates corresponding to the multiple three-dimensional coordinates.

[0010] Perform fitting according to the multiple three-dimensional coordinates and the multiple two-dimensional coordinates to obtain the second imaging model parameters.

[0011] Establish a second imaging model using the second imaging model parameters.

[0012] Optionally, using the virtual camera to collect images of multiple three-dimensional space points, and using the first imaging model to convert the multiple three-dimensional coordinates to obtain corresponding two-dimensional images includes:

[0013] Convert multiple three-dimensional coordinates using the first projection formula included in the first imaging model to obtain corresponding two-dimensional images.

[0014] Perform fitting based on multiple three-dimensional coordinates and multiple two-dimensional coordinates to obtain second imaging model parameters including:

[0015] Obtain the second projection formula corresponding to the second imaging model, where the independent variable in the second projection formula is the three-dimensional coordinate, the dependent variable is the two-dimensional coordinate, and the coefficient is the second imaging model parameter, and the coefficient is an unknown quantity.

[0016] Substitute multiple three-dimensional coordinates and multiple two-dimensional coordinates into the second projection formula to obtain the coefficient, and use the coefficient as the second imaging model parameter.

[0017] Optionally, constructing a virtual space calibration board and a virtual camera in the virtual space includes:

[0018] Construct a virtual camera and a first virtual space calibration board in the virtual space.

[0019] Construct a virtual camera and a second virtual space calibration board in the virtual space.

[0020] Construct a virtual camera and a third virtual space calibration board in the virtual space.

[0021] Where the distances between the first virtual space calibration board, the second virtual space calibration board, and the third virtual space calibration board and the virtual camera are different.

[0022] Optionally, each virtual space calibration board among multiple virtual space calibration boards is composed of multiple unit calibration boards arranged in an array, and each unit calibration board among the multiple unit calibration boards is composed of a black and white checkerboard, and the intersection points in the middle of four adjacent grids in the black and white checkerboard are three-dimensional space points.

[0023] Optionally, after establishing the second imaging model using the second imaging model parameters, the method further includes:

[0024] Construct a virtual space correction board in the virtual space.

[0025] Determine the multiple three-dimensional coordinates corresponding to the multiple three-dimensional space points in the virtual space correction board.

[0026] Respectively convert multiple three-dimensional coordinates using the first imaging model and the second imaging model to obtain corresponding first two-dimensional images and second two-dimensional images respectively.

[0027] Compare the multiple two-dimensional icons corresponding to the multiple three-dimensional coordinates in the first two-dimensional image and the second two-dimensional image respectively to determine the error value.

[0028] When the error value is greater than the first preset value, update the first imaging model parameters adopted by the first imaging model.

[0029] On the other hand, the present application also provides a vehicle-mounted camera model conversion device, which is characterized in that the device includes:

[0030] A construction module, configured to construct a virtual space calibration board and a virtual camera in a virtual space, and the virtual camera adopts a first imaging model.

[0031] A determination module, configured to determine a plurality of three-dimensional coordinates corresponding to a plurality of three-dimensional space points in the virtual space calibration board.

[0032] A conversion module, configured to collect images of the plurality of three-dimensional space points by using the virtual camera, and convert the plurality of three-dimensional coordinates by using the first imaging model to obtain corresponding two-dimensional images, and the two-dimensional images include a plurality of two-dimensional coordinates corresponding to the plurality of three-dimensional coordinates.

[0033] A fitting module, configured to perform fitting according to the plurality of three-dimensional coordinates and the plurality of two-dimensional coordinates to obtain second imaging model parameters.

[0034] An establishment module, configured to establish a second imaging model by using the second imaging model parameters.

[0035] Optionally, the conversion module is configured to:

[0036] Convert the plurality of three-dimensional coordinates by using the first projection formula included in the first imaging model to obtain corresponding two-dimensional images.

[0037] The fitting module is configured to:

[0038] Obtain a second projection formula corresponding to the second imaging model, where the independent variable in the second projection formula is the three-dimensional coordinate, the dependent variable is the two-dimensional coordinate, and the coefficient is the second imaging model parameter, and the coefficient is an unknown quantity.

[0039] Substitute the plurality of three-dimensional coordinates and the plurality of two-dimensional coordinates into the second projection formula to obtain the coefficient, and use the coefficient as the second imaging model parameter.

[0040] Optionally, the construction module is further configured to:

[0041] Construct a virtual camera and a first virtual space calibration board in the virtual space;

[0042] Construct a virtual camera and a second virtual space calibration board in the virtual space;

[0043] Construct a virtual camera and a third virtual space calibration board in the virtual space,

[0044] The distances between the first virtual space calibration board, the second virtual space calibration board, and the third virtual space calibration board and the virtual camera are different.

[0045] Optionally, each virtual space calibration board among the multiple virtual space calibration boards is composed of multiple unit calibration boards arranged in an array, and each unit calibration board among the multiple unit calibration boards is composed of a black-and-white chessboard grid. The intersection points in the middle of four adjacent grids in the black-and-white chessboard grid are three-dimensional space points.

[0046] Optionally, the device further includes a calibration module configured to:

[0047] After establishing the second imaging model using the second imaging model parameters, construct a virtual space correction board in the virtual space.

[0048] Determine the multiple three-dimensional coordinates corresponding to the multiple three-dimensional space points in the virtual space correction board.

[0049] Respectively use the first imaging model and the second imaging model to convert the multiple three-dimensional coordinates, and respectively obtain the corresponding first two-dimensional image and second two-dimensional image.

[0050] Compare the multiple two-dimensional icons corresponding to the multiple three-dimensional coordinates in the first two-dimensional image and the second two-dimensional image respectively, and determine the error value.

[0051] When the error value is greater than the first preset value, update the first imaging model parameters adopted by the first imaging model.

[0052] On the other hand, the present application also provides a vehicle-mounted camera model conversion device, including a processor, a memory, and a computer program stored on the memory and executable on the processor. It is characterized in that when the computer program is executed by the processor, it implements the vehicle-mounted camera model conversion method in the first aspect.

[0053] By using the vehicle-mounted camera model conversion method, device and vehicle provided by the present application, construct a virtual space calibration board and a virtual camera using the first imaging model in the virtual space, collect multiple three-dimensional space points on the virtual space calibration board using the virtual camera and convert them using the first imaging model to obtain the corresponding two-dimensional image projections, perform fitting based on the multiple three-dimensional coordinates of the multiple three-dimensional space points of the virtual space calibration board and the multiple two-dimensional coordinates of the two-dimensional image, and inversely solve to obtain the second imaging model parameters, so as to establish the second imaging model using the second imaging model parameters, realize the fast conversion between the first imaging model and the second imaging model, and there is no need to manually calibrate the camera to achieve model conversion. Description of the Drawings

[0054] To more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, without creative efforts, other drawings can be obtained based on these drawings.

[0055] Figure 1 It is a flowchart of the vehicle-mounted camera model conversion method provided by the embodiment of the present application;

[0056] Figure 2 It is another flowchart of the vehicle-mounted camera model conversion method provided by the embodiment of the present application;

[0057] Figure 3a It is a schematic diagram of the virtual space of the vehicle-mounted camera model conversion method provided by the embodiment of the present application;

[0058] Figure 3b It is another schematic diagram of the virtual space of the vehicle-mounted camera model conversion method provided by the embodiment of the present application;

[0059] Figure 3c It is another schematic diagram of the virtual space of the vehicle-mounted camera model conversion method provided by the embodiment of the present application;

[0060] Figure 4 It is a schematic diagram of the unit calibration board of the virtual space of the vehicle-mounted camera model conversion method provided by the embodiment of the present application;

[0061] Figure 5 It is an architecture diagram of the vehicle-mounted camera model conversion device provided by the embodiment of the present application;

[0062] Figure 6 It is an architecture diagram of the vehicle-mounted camera model conversion device provided by the embodiment of the present application. Detailed implementation manners

[0063] The following will clearly and completely describe the technical solutions in the embodiments of the present application in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are some, rather than all, of the embodiments of the present application. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present application without creative efforts fall within the scope of protection of the present application.

[0064] To obtain the projection relationship between the camera coordinate system and the image coordinate system, camera model parameters are required. To obtain camera model parameters, the camera needs to be calibrated. There are many types of camera models, and the typical ones are the pinhole model and the equidistant fisheye model. Camera module manufacturers generally provide camera model parameters, but only one type of camera model parameters is provided. When the camera model provided by the manufacturer is inconsistent with the required camera model, the current mainstream method is to re - calibrate the camera. For example, if the manufacturer provides equidistant fisheye model parameters, but the user can only use pinhole model parameters, it is necessary to re - collect the calibration board data for calibration. In the case of no perfect calibration equipment and environment, camera calibration is a rather cumbersome process.

[0065] Generally, users do not have perfect calibration equipment and calibration environment, and preparing the calibration board and collecting data is a rather cumbersome process, consuming a lot of time and effort.

[0066] An embodiment of this application provides a method for converting a vehicle - mounted camera model, as Figure 1 shown, the method includes steps S101, S102, S103, S104, and S105, where:

[0067] In step S101, a virtual space calibration board and a virtual camera are constructed in the virtual space, and the virtual camera adopts a first imaging model.

[0068] In step S102, multiple three - dimensional coordinates corresponding to multiple three - dimensional space points in the virtual space calibration board are determined.

[0069] In step S103, the virtual camera is used to collect images of multiple three - dimensional space points, and the first imaging model is used to convert multiple three - dimensional coordinates to obtain corresponding two - dimensional images, where the two - dimensional images include multiple two - dimensional coordinates corresponding to multiple three - dimensional coordinates.

[0070] In step S104, fitting is performed according to multiple three - dimensional coordinates and multiple two - dimensional coordinates to obtain second imaging model parameters.

[0071] In step S105, a second imaging model is established using the second imaging model parameters.

[0072] In some alternative embodiments, using the virtual camera to collect images of multiple three - dimensional space points and using the first imaging model to convert multiple three - dimensional coordinates to obtain corresponding two - dimensional images includes:

[0073] Using the first projection formula included in the first imaging model to convert multiple three - dimensional coordinates to obtain corresponding two - dimensional images.

[0074] Fitting according to multiple three - dimensional coordinates and multiple two - dimensional coordinates to obtain second imaging model parameters includes:

[0075] Obtain the second projection formula corresponding to the second imaging model. The independent variable in the second projection formula is the three-dimensional coordinate, the dependent variable is the two-dimensional coordinate, and the coefficients are the second imaging model parameters, where the coefficients are unknowns.

[0076] Substitute multiple three-dimensional coordinates and multiple two-dimensional coordinates into the second projection formula to obtain the coefficients, and use the coefficients as the second imaging model parameters.

[0077] In some alternative embodiments, constructing a virtual space calibration board and a virtual camera in the virtual space includes:

[0078] Construct a virtual camera and a first virtual space calibration board in the virtual space;

[0079] Construct a virtual camera and a second virtual space calibration board in the virtual space;

[0080] Construct a virtual camera and a third virtual space calibration board in the virtual space,

[0081] where the distances between the first virtual space calibration board, the second virtual space calibration board, and the third virtual space calibration board and the virtual camera are different.

[0082] In some alternative embodiments, each virtual space calibration board among the multiple virtual space calibration boards is composed of multiple unit calibration boards arranged in an array. Each unit calibration board among the multiple unit calibration boards is composed of a black and white checkerboard, and the intersection points in the middle of four adjacent grids in the black and white checkerboard are three-dimensional space points.

[0083] In some alternative embodiments, after establishing the second imaging model using the second imaging model parameters, the method further includes:

[0084] Construct a virtual space correction board in the virtual space.

[0085] Determine the multiple three-dimensional coordinates corresponding to the multiple three-dimensional space points in the virtual space correction board.

[0086] Respectively use the first imaging model and the second imaging model to transform the multiple three-dimensional coordinates, and respectively obtain the corresponding first two-dimensional image and second two-dimensional image.

[0087] Compare the multiple two-dimensional icons corresponding to the multiple three-dimensional coordinates in the first two-dimensional image and the second two-dimensional image respectively, and determine the error value.

[0088] When the error value is greater than the first preset value, update the first imaging model parameters used by the first imaging model.

[0089] By using the vehicle-mounted camera model conversion method provided in this application, a virtual space calibration board and a virtual camera using a first imaging model are constructed in a virtual space. The virtual camera is used to collect multiple three-dimensional space points on the virtual space calibration board, and the corresponding two-dimensional image projections are obtained through conversion using the first imaging model. Fitting is performed based on the multiple three-dimensional coordinates of the multiple three-dimensional space points of the virtual space calibration board and the multiple two-dimensional coordinates of the two-dimensional image, and the parameters of the second imaging model are obtained by inverse solution. Thus, the second imaging model is established using the parameters of the second imaging model, realizing the rapid conversion between the first imaging model and the second imaging model, without the need to manually calibrate the camera to achieve model conversion.

[0090] An embodiment of this application also provides a vehicle-mounted camera model conversion method, as Figure 2 shown, the method includes steps S201, S202, S203, S204, S205, and S206, where:

[0091] In step S201, a virtual space calibration board and a virtual camera are constructed in a virtual space, and the virtual camera uses a first imaging model.

[0092] It can be understood that the virtual space calibration board and the virtual camera can be constructed in a 3D drawing software, or the construction of the virtual space calibration board and the virtual camera can be directly achieved through programming. The virtual camera faces the virtual space calibration board.

[0093] In some optional embodiments, when the first imaging model is a pinhole model, the parameters include internal parameters and distortion coefficients. The internal parameters include focal lengths fx and fy and the image center points ux and uy. The distortion coefficients include radial distortion parameters k1, k2, k3, k4, k5, and k6, and tangential distortion parameters p1 and p2. The fisheye equidistant model also includes internal parameters and distortion coefficients. The internal parameters include focal length f and image center points ux and uy. The distortion coefficients include k1, k2, k3, and k4.

[0094] In step S202, determine the multiple three-dimensional coordinates corresponding to the multiple three-dimensional space points in the virtual space calibration board.

[0095] In some optional embodiments, constructing a virtual space calibration board and a virtual camera in a virtual space includes:

[0096] Construct a virtual camera and a first virtual space calibration board in the virtual space;

[0097] Construct a virtual camera and a second virtual space calibration board in the virtual space;

[0098] Construct a virtual camera and a third virtual space calibration board in the virtual space,

[0099] The distances between the first virtual space calibration board, the second virtual space calibration board, and the third virtual space calibration board and the virtual camera are different.

[0100] In some alternative embodiments, three virtual space calibration boards can be constructed in the virtual space, and the distances between these three virtual space calibration boards and the virtual camera are 4 meters, 6 meters, and 8 meters respectively.

[0101] It can be understood that, as Figure 3a shown, a first virtual space calibration board 301a and a virtual camera 302 can be constructed in the virtual space 3. The distance between the first virtual space calibration board 301a and the virtual camera 302 can be a first distance, and the first distance can be 4 meters.

[0102] It can be understood that the first virtual space calibration board 301a is composed of 60 unit calibration boards 303 arranged in an array. The statement that the distance between the brawling virtual space calibration board 301a and the virtual camera 302 is the first distance can refer to the distance between the central unit calibration board 303 of the first virtual space calibration board 301a and the virtual camera 302 being the first distance, or it can also mean that the distance between each unit calibration board 303 of the first virtual space calibration board 301a and the virtual camera 302 is the first distance, that is, the first virtual space calibration board 301a is arc-shaped.

[0103] As Figure 3b shown, a second virtual space calibration board 301b and a virtual camera 302 can be constructed in the virtual space 3. The distance between the second virtual space calibration board 301b and the virtual camera 302 can be a second distance, and the second distance can be 6 meters.

[0104] As Figure 3c shown, a third virtual space calibration board 301c and a virtual camera 302 can be constructed in the virtual space 3. The distance between the third virtual space calibration board 301c and the virtual camera 302 can be a third distance, and the third distance can be 8 meters.

[0105] In some alternative embodiments, each unit calibration board among the multiple unit calibration boards is composed of a black and white checkerboard as Figure 4 shown, and the intersection points in the middle of four adjacent grids in the black and white checkerboard are three-dimensional space points.

[0106] In some alternative embodiments, as Figure 4As shown, each unit calibration board 303 is composed of 6 * 7 = 42 black and white checkerboards. The size of each grid is 5 cm. The intersection points in the middle of four adjacent grids in the black and white checkerboards are three-dimensional space points. Therefore, each unit calibration board has 5 * 6 = 30 three-dimensional space points. Since each virtual space calibration board is composed of 60 unit calibration boards arranged in an array, each virtual space calibration board includes 60 * 30 = 1800 three-dimensional space points. Further, since 3 virtual space calibration boards are constructed in the virtual space, and the distances between these 3 virtual space calibration boards and the virtual camera are 4 meters, 6 meters, and 8 meters respectively, there are a total of 3 * 60 * 30 = 6400 three-dimensional space points in the virtual space.

[0107] In some alternative embodiments, each virtual space calibration board can also be composed of 100 unit calibration boards arranged in an array. Therefore, each virtual space calibration board includes 100 * 30 = 3000 three-dimensional space points. Further, since 3 virtual space calibration boards are constructed in the virtual space, and the distances between these 3 virtual space calibration boards and the virtual camera are 4 meters, 6 meters, and 8 meters respectively, there are a total of 3 * 100 * 30 = 9000 three-dimensional space points in the virtual space. All the three-dimensional space points fall within the shooting range of the virtual camera.

[0108] In step S203, the first projection formula included in the first imaging model is used to convert multiple three-dimensional coordinates to obtain the corresponding two-dimensional image, and the two-dimensional image includes multiple two-dimensional coordinates corresponding to the multiple three-dimensional coordinates.

[0109] It can be understood that the first projection formula is used to perform projection transformation on the multiple three-dimensional coordinates corresponding to multiple three-dimensional space points to obtain the two-dimensional coordinates included in the two-dimensional image in the camera. The first imaging model parameters adopted by the first imaging model are determined. In other words, the coefficients in the first projection formula included in the first imaging model are determined. By inputting the multiple three-dimensional coordinates corresponding to multiple three-dimensional space points into the first projection formula, the projection transformation can be performed using the first projection formula to obtain the two-dimensional coordinates included in the two-dimensional image in the camera.

[0110] In step S204, the second projection formula corresponding to the second imaging model is obtained. The independent variable in the second projection formula is the three-dimensional coordinate, the dependent variable is the two-dimensional coordinate, and the coefficient is the second imaging model parameter, where the coefficient is an unknown quantity.

[0111] It can be understood that since it is necessary to transform the first imaging model to obtain the second imaging model, the second imaging model parameters of the second imaging model are uncertain. In other words, the coefficients used in the second projection formula corresponding to the second imaging model are unknown quantities.

[0112] In step S205, multiple three-dimensional coordinates and multiple two-dimensional coordinates are substituted into the second projection formula to obtain coefficients, and the coefficients are used as the second imaging model parameters.

[0113] It can be understood that since the ultimate goal of using the second imaging model is also to perform projection transformation on three-dimensional coordinates to obtain the two-dimensional coordinates of the two-dimensional image in the camera, therefore, substituting the determined multiple three-dimensional coordinates and multiple two-dimensional coordinates obtained by using the first imaging model into the second projection formula of the second imaging model can inversely deduce and fit the unknown coefficients in the second projection formula of the second imaging model, that is, the second imaging model parameters.

[0114] In step S206, a second imaging model is established using the second imaging model parameters.

[0115] It can be understood that after establishing the second imaging model using the second imaging model parameters, the camera can use the second imaging model, so that even when the camera model provided by the manufacturer is inconsistent with the required camera model, the second imaging model and the camera can be used to achieve the conversion and recognition of three-dimensional images.

[0116] In some optional embodiments, the error of the established second imaging model can also be determined and calibrated. After establishing the second imaging model using the second imaging model parameters, the method further includes:

[0117] Construct a virtual space correction plate in the virtual space.

[0118] Determine the multiple three-dimensional coordinates corresponding to the multiple three-dimensional space points in the virtual space correction plate;

[0119] The multiple three-dimensional coordinates are respectively transformed using the first imaging model and the second imaging model to obtain corresponding first two-dimensional images and second two-dimensional images.

[0120] Compare the multiple two-dimensional icons corresponding to the multiple three-dimensional coordinates in the first two-dimensional image and the second two-dimensional image respectively to determine the error value.

[0121] When the error value is greater than the first preset value, update the first imaging model parameters used by the first imaging model.

[0122] By using the vehicle-mounted camera model conversion method provided in this application, a virtual space calibration board and a virtual camera using a first imaging model are constructed in a virtual space. The virtual camera is used to collect multiple three-dimensional space points on the virtual space calibration board and convert them into corresponding two-dimensional image projections using the first imaging model. Fitting is performed based on the multiple three-dimensional coordinates of the multiple three-dimensional space points on the virtual space calibration board and the multiple two-dimensional coordinates of the two-dimensional image, and the second imaging model parameters are obtained by reverse solution. Thus, a second imaging model is established using the second imaging model parameters, realizing a fast conversion between the first imaging model and the second imaging model without manually calibrating the camera to achieve model conversion.

[0123] An embodiment of this application also provides a vehicle-mounted camera model conversion device, as Figure 5 shown. The device includes:

[0124] A construction module 501, configured to construct a virtual space calibration board and a virtual camera in a virtual space, where the virtual camera uses a first imaging model.

[0125] A determination module 502, configured to determine the multiple three-dimensional coordinates corresponding to the multiple three-dimensional space points in the virtual space calibration board.

[0126] A conversion module 503, configured to collect images of the multiple three-dimensional space points using the virtual camera, and convert the multiple three-dimensional coordinates using the first imaging model to obtain corresponding two-dimensional images, where the two-dimensional images include multiple two-dimensional coordinates corresponding to the multiple three-dimensional coordinates.

[0127] A fitting module 504, configured to perform fitting based on the multiple three-dimensional coordinates and the multiple two-dimensional coordinates to obtain the second imaging model parameters.

[0128] An establishment module 505, configured to establish a second imaging model using the second imaging model parameters.

[0129] In some alternative embodiments, the conversion module 503 is configured to:

[0130] Convert the multiple three-dimensional coordinates using the first projection formula included in the first imaging model to obtain corresponding two-dimensional images.

[0131] The fitting module 504 is configured to:

[0132] Obtain a second projection formula corresponding to the second imaging model, where the independent variable in the second projection formula is the three-dimensional coordinate, the dependent variable is the two-dimensional coordinate, and the coefficient is the second imaging model parameter, and the coefficient is an unknown quantity.

[0133] Substitute the multiple three-dimensional coordinates and the multiple two-dimensional coordinates into the second projection formula to obtain the coefficient, and use the coefficient as the second imaging model parameter.

[0134] In some alternative embodiments, the building module 501 is further configured to:

[0135] Construct a virtual camera and a first virtual space calibration board in the virtual space;

[0136] Construct a virtual camera and a second virtual space calibration board in the virtual space;

[0137] Construct a virtual camera and a third virtual space calibration board in the virtual space,

[0138] wherein the distances between the first virtual space calibration board, the second virtual space calibration board, and the third virtual space calibration board and the virtual camera are different.

[0139] In some alternative embodiments, each virtual space calibration board among the multiple virtual space calibration boards is composed of a plurality of unit calibration boards arranged in an array, each unit calibration board among the plurality of unit calibration boards is composed of a black-and-white chessboard, and the intersection points in the middle of four adjacent grids in the black-and-white chessboard are three-dimensional space points.

[0140] In some alternative embodiments, the device further includes a calibration module 506, which is configured to:

[0141] After establishing a second imaging model using the second imaging model parameters, construct a virtual space correction board in the virtual space.

[0142] Determine the multiple three-dimensional coordinates corresponding to the multiple three-dimensional space points in the virtual space correction board.

[0143] Respectively convert the multiple three-dimensional coordinates using the first imaging model and the second imaging model to obtain corresponding first two-dimensional images and second two-dimensional images respectively.

[0144] Compare the multiple two-dimensional icons corresponding to the multiple three-dimensional coordinates in the first two-dimensional image and the second two-dimensional image respectively to determine the error value.

[0145] When the error value is greater than the first preset value, update the first imaging model parameters adopted by the first imaging model.

[0146] By using the in-vehicle camera model conversion device provided in this application, a virtual space calibration board and a virtual camera using the first imaging model are constructed in the virtual space. The virtual camera is used to collect multiple three-dimensional space points on the virtual space calibration board, and the corresponding two-dimensional image projections are obtained by converting using the first imaging model. Fitting is performed based on the multiple three-dimensional coordinates of the multiple three-dimensional space points on the virtual space calibration board and the multiple two-dimensional coordinates of the two-dimensional image, and the second imaging model parameters are obtained by inverse solution, so as to establish the second imaging model using the second imaging model parameters, realizing the fast conversion between the first imaging model and the second imaging model, without the need to manually calibrate the camera to achieve model conversion.

[0147] As Figure 6 shown in the figure, an in-vehicle camera model conversion device 60 is further provided in an embodiment of this application, including a processor 601, a memory 602, and a computer program stored on the memory 602 and operable on the processor 601. When the computer program is executed by the processor 601, an in-vehicle camera model conversion method is implemented. The method includes:

[0148] Construct a virtual space calibration board and a virtual camera in the virtual space, and the virtual camera uses the first imaging model.

[0149] Determine the multiple three-dimensional coordinates corresponding to the multiple three-dimensional space points in the virtual space calibration board.

[0150] Use the virtual camera to collect images of the multiple three-dimensional space points, and use the first imaging model to convert the multiple three-dimensional coordinates to obtain the corresponding two-dimensional image, and the two-dimensional image includes multiple two-dimensional coordinates corresponding to the multiple three-dimensional coordinates.

[0151] Perform fitting based on the multiple three-dimensional coordinates and the multiple two-dimensional coordinates to obtain the second imaging model parameters.

[0152] Establish the second imaging model using the second imaging model parameters.

[0153] In some alternative embodiments, using the virtual camera to collect images of the multiple three-dimensional space points and using the first imaging model to convert the multiple three-dimensional coordinates to obtain the corresponding two-dimensional image includes:

[0154] Use the first projection formula included in the first imaging model to convert the multiple three-dimensional coordinates to obtain the corresponding two-dimensional image.

[0155] Performing fitting based on the multiple three-dimensional coordinates and the multiple two-dimensional coordinates to obtain the second imaging model parameters includes:

[0156] Obtain the second projection formula corresponding to the second imaging model. The independent variable in the second projection formula is the three-dimensional coordinate, the dependent variable is the two-dimensional coordinate, and the coefficient is the second imaging model parameter, where the coefficient is an unknown quantity.

[0157] Substitute multiple three-dimensional coordinates and multiple two-dimensional coordinates into the second projection formula to obtain coefficients, and use the coefficients as the second imaging model parameters.

[0158] In some alternative embodiments, constructing a virtual space calibration board and a virtual camera in a virtual space includes:

[0159] Construct a virtual camera and a first virtual space calibration board in the virtual space;

[0160] Construct a virtual camera and a second virtual space calibration board in the virtual space;

[0161] Construct a virtual camera and a third virtual space calibration board in the virtual space,

[0162] wherein the distances between the first virtual space calibration board, the second virtual space calibration board, and the third virtual space calibration board and the virtual camera are different.

[0163] In some alternative embodiments, each virtual space calibration board among the multiple virtual space calibration boards is composed of multiple unit calibration boards arranged in an array, each unit calibration board among the multiple unit calibration boards is composed of a black-and-white chessboard grid, and the intersection points in the middle of four adjacent grids in the black-and-white chessboard grid are three-dimensional space points.

[0164] In some alternative embodiments, after establishing the second imaging model using the second imaging model parameters, the method further includes:

[0165] Construct a virtual space correction board in the virtual space.

[0166] Determine the multiple three-dimensional coordinates corresponding to the multiple three-dimensional space points in the virtual space correction board.

[0167] Respectively use the first imaging model and the second imaging model to convert the multiple three-dimensional coordinates to obtain corresponding first two-dimensional images and second two-dimensional images respectively.

[0168] Compare the multiple two-dimensional icons corresponding to the multiple three-dimensional coordinates in the first two-dimensional image and the second two-dimensional image respectively to determine the error value.

[0169] When the error value is greater than the first preset value, update the first imaging model parameters used in the first imaging model.

[0170] By using the in-vehicle camera model conversion device provided in this application, a virtual space calibration board and a virtual camera using a first imaging model are constructed in a virtual space. The virtual camera is used to collect multiple three-dimensional space points on the virtual space calibration board and convert them into corresponding two-dimensional image projections using the first imaging model. Fitting is performed based on the multiple three-dimensional coordinates of the multiple three-dimensional space points on the virtual space calibration board and the multiple two-dimensional coordinates of the two-dimensional image, and the second imaging model parameters are inversely solved. Thus, a second imaging model is established using the second imaging model parameters, realizing a fast conversion between the first imaging model and the second imaging model, without the need to manually calibrate the camera to achieve model conversion.

[0171] An embodiment of this application also provides a computer-readable storage medium, such as a memory including program code. The above program code can be executed by the processor of the in-vehicle camera model conversion device to complete the in-vehicle camera model conversion method in the above embodiment. For example, the computer-readable storage medium can be a Read-Only Memory (ROM), a Random Access Memory (RAM), a Compact Disc Read-Only Memory (CD-ROM), magnetic tape, floppy disk, and optical data storage device, etc.

[0172] Those of ordinary skill in the art can understand that all or part of the steps to implement the above embodiment can be completed by hardware, or can be completed by hardware related to program code. The program can be stored in a computer-readable storage medium, and the above-mentioned storage medium can be a read-only memory, a magnetic disk, or an optical disc, etc.

[0173] In this application, it should be understood that terms such as "first" and "second" are only used for descriptive purposes and cannot be understood as indicating or implying relative importance or implicitly specifying the quantity of the indicated technical features.

[0174] After considering the specification and practicing the invention disclosed herein, those skilled in the art will readily think of other implementation schemes of this application. This application aims to cover any variations, uses, or adaptive changes of this application. These variations, uses, or adaptive changes follow the general principles of this application and include common general knowledge or conventional technical means in the technical field not disclosed in this application. The specification and embodiments are only regarded as exemplary.

[0175] It should be understood that this application is not limited to the exact structure already described and shown in the drawings, and various modifications and changes can be made without departing from its scope. The scope of this application is only limited by the appended claims.

[0176] The above is only for the convenience of those skilled in the art to understand the technical solution of the present application, and is not intended to limit the present application. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims

1. A vehicle camera model conversion method, characterized in that: The method comprises: Constructing a virtual space calibration plate and a virtual camera in the virtual space, wherein the virtual camera adopts a first imaging model; Determining a plurality of three-dimensional coordinates corresponding to a plurality of three-dimensional space points in the virtual space calibration plate; Using the virtual camera to collect images of the multiple three-dimensional space points, using the first imaging model to transform the multiple three-dimensional coordinates to obtain corresponding two-dimensional images, wherein the two-dimensional image includes multiple two-dimensional coordinates corresponding to the multiple three-dimensional coordinates; Perform fitting according to the multiple three-dimensional coordinates and the multiple two-dimensional coordinates to obtain second imaging model parameters; A second imaging model is established using the second imaging model parameters.

2. The vehicle camera model conversion method according to claim 1, characterized in that: The using the virtual camera to collect images of the multiple three-dimensional space points and using the first imaging model to transform the multiple three-dimensional coordinates to obtain corresponding two-dimensional images includes: The plurality of three-dimensional coordinates are transformed using a first projection formula included in the first imaging model to obtain corresponding two-dimensional images, The fitting according to the multiple three-dimensional coordinates and the multiple two-dimensional coordinates to obtain the second imaging model parameters comprises: Obtaining a second projection formula corresponding to the second imaging model, wherein the independent variable in the second projection formula is a three-dimensional coordinate, the dependent variable is a two-dimensional coordinate, and the coefficient is a parameter of the second imaging model, wherein the coefficient is an unknown quantity; Substitute the multiple three-dimensional coordinates and the multiple two-dimensional coordinates into the second projection formula to obtain the coefficients, and use the coefficients as the second imaging model parameters.

3. The vehicle camera model conversion method according to claim 1, characterized in that: The step of constructing a virtual space calibration plate and a virtual camera in a virtual space includes: Constructing the virtual camera and the first virtual space calibration plate in the virtual space; Constructing the virtual camera and the second virtual space calibration plate in the virtual space; Constructing the virtual camera and the third virtual space calibration plate in the virtual space, The distances between the first virtual space calibration plate, the second virtual space calibration plate and the third virtual space calibration plate and the virtual camera are different.

4. The vehicle camera model conversion method according to claim 2, characterized in that: Each of the multiple virtual space calibration plates is composed of a plurality of unit calibration plates arranged in an array, each of the multiple unit calibration plates is composed of a black and white chessboard, and the intersection between four adjacent grids in the black and white chessboard is a three-dimensional space point.

5. The vehicle camera model conversion method according to claim 1, characterized in that: After establishing the second imaging model using the second imaging model parameters, the method further includes: constructing a virtual space correction plate in the virtual space; Determining a plurality of three-dimensional coordinates corresponding to a plurality of three-dimensional space points in the virtual space correction plate; The plurality of three-dimensional coordinates are converted using the first imaging model and the second imaging model respectively to obtain corresponding first two-dimensional images and second two-dimensional images respectively; Compare a plurality of two-dimensional icons corresponding to the plurality of three-dimensional coordinates in the first two-dimensional image and the second two-dimensional image to determine an error value; When the error value is greater than a first preset value, first imaging model parameters used by the first imaging model are updated.

6. A vehicle-mounted camera model conversion device, characterized in that: The device comprises: A construction module is configured to construct a virtual space calibration plate and a virtual camera in the virtual space; A determination module, configured to determine a plurality of three-dimensional coordinates corresponding to a plurality of three-dimensional space points in the virtual space calibration plate; a conversion module configured to use the virtual camera to perform image acquisition on the multiple three-dimensional space points, and use the first imaging model to convert the multiple three-dimensional coordinates to obtain corresponding two-dimensional images, wherein the two-dimensional image includes multiple two-dimensional coordinates corresponding to the multiple three-dimensional coordinates; A fitting module, configured to perform fitting according to the plurality of three-dimensional coordinates and the plurality of two-dimensional coordinates to obtain second imaging model parameters; The establishing module is configured to establish a second imaging model using the second imaging model parameters.

7. The vehicle-mounted camera model conversion device according to claim 6, characterized in that: The conversion module is configured to: The plurality of three-dimensional coordinates are transformed using a first projection formula included in the first imaging model to obtain corresponding two-dimensional images, The fitting module is configured as follows: Obtaining a second projection formula corresponding to the second imaging model, wherein the independent variable in the second projection formula is a three-dimensional coordinate, the dependent variable is a two-dimensional coordinate, and the coefficient is a parameter of the second imaging model, wherein the coefficient is an unknown quantity; Substitute the multiple three-dimensional coordinates and the multiple two-dimensional coordinates into the second projection formula to obtain the coefficients, and use the coefficients as the second imaging model parameters.

8. The vehicle-mounted camera model conversion device according to claim 6, characterized in that: The building blocks are further configured to: Constructing the virtual camera and the first virtual space calibration plate in the virtual space; Constructing the virtual camera and the second virtual space calibration plate in the virtual space; Constructing the virtual camera and the third virtual space calibration plate in the virtual space, The distances between the first virtual space calibration plate, the second virtual space calibration plate and the third virtual space calibration plate and the virtual camera are different.

9. The vehicle-mounted camera model conversion device according to claim 8, characterized in that: Each of the multiple virtual space calibration plates is composed of a plurality of unit calibration plates arranged in an array, each of the multiple unit calibration plates is composed of a black and white chessboard, and the intersection between four adjacent grids in the black and white chessboard is a three-dimensional space point.

10. The vehicle-mounted camera model conversion device according to claim 6, characterized in that: The device also includes a correction module configured to: After establishing the second imaging model using the second imaging model parameters, constructing a virtual space correction plate in the virtual space; Determining a plurality of three-dimensional coordinates corresponding to a plurality of three-dimensional space points in the virtual space correction plate; The plurality of three-dimensional coordinates are converted using the first imaging model and the second imaging model respectively to obtain corresponding first two-dimensional images and second two-dimensional images respectively; Compare a plurality of two-dimensional icons corresponding to the plurality of three-dimensional coordinates in the first two-dimensional image and the second two-dimensional image to determine an error value; When the error value is greater than a first preset value, first imaging model parameters used by the first imaging model are updated.

11. A vehicle camera model conversion device, comprising a processor, a memory, and a computer program stored in the memory and executable on the processor, characterized in that: When the computer program is executed by the processor, the method according to any one of claims 1 to 5 is implemented.