A vehicle body positioning method and system
By setting up multiple physical and virtual cameras on the vehicle body and combining the position and attitude relationship to calculate the vehicle body pose, the problem of insufficient estimation accuracy of a single camera is solved, and higher positioning accuracy and stability are achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-08-29
- Publication Date
- 2026-03-17
AI Technical Summary
In existing technologies, when using a single camera to estimate the vehicle's pose in the middle of the vehicle body, especially for longer vehicles, the accuracy is affected by factors such as viewing angle limitations and changes in lighting, resulting in inaccurate and unstable positioning.
By employing a combination of multiple cameras and virtual cameras, the vehicle's pose is estimated by calculating the extrinsic parameters of the front, middle, and rear cameras, as well as the baseline lengths of the front and rear virtual cameras.
This improved the accuracy and stability of vehicle pose estimation, reduced errors and deviations, and achieved higher positioning accuracy and reliability.
Smart Images

Figure CN117315016B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of image data processing, and in particular to a vehicle positioning method and system. Background Technology
[0002] In existing technologies, a common vehicle localization method uses a single camera positioned at the center of the vehicle to estimate its pose. However, when the vehicle is long, the accuracy of this method is significantly affected because the limited field of view at the front and rear of the vehicle restricts the image information captured by a single camera, leading to inaccurate pose estimations. Furthermore, in practical applications, factors such as lighting variations and background interference can negatively impact the accuracy of this method, causing instability or failure in localization. Therefore, improving the accuracy and stability of vehicle pose estimation is a pressing issue that needs to be addressed.
[0003] Currently, no effective solution has been proposed for improving the accuracy and stability of vehicle pose estimation in related technologies. Summary of the Invention
[0004] This application provides a vehicle positioning method and system to at least address the problem of how to improve the accuracy and stability of vehicle pose estimation in related technologies.
[0005] In a first aspect, embodiments of this application provide a vehicle body positioning method, the method comprising:
[0006] The extrinsic parameters of the front camera, the middle camera, and the rear camera are calculated, wherein the front camera and the rear camera are located at the edge of the vehicle body to be located, and the middle camera is located at the center of the vehicle body to be located.
[0007] Calculate the baseline length between the front virtual camera and the rear virtual camera, wherein the front virtual camera and the rear virtual camera are located at the top corner of the vehicle body to be located;
[0008] The pose of the vehicle body to be positioned is calculated based on the extrinsic parameters of the front camera, the middle camera, the rear camera, and the baseline length.
[0009] In some embodiments, the front camera and the rear camera are located at the edge of the vehicle body to be positioned, including:
[0010] The front camera is located at the first edge of the vehicle body to be located, and the rear camera is located at the second edge of the vehicle body to be located. The first edge and the second edge of the vehicle body are non-intersecting vehicle body edges.
[0011] In some embodiments, the front virtual camera and the rear virtual camera are located at the top corner of the vehicle body to be located, including:
[0012] The front virtual camera is located at the first apex of the vehicle body at the first edge of the vehicle body, and the rear virtual camera is located at the second apex of the vehicle body at the second edge of the vehicle body.
[0013] In some embodiments, the rotation values of the front virtual camera, the rear virtual camera, and the vehicle center in the world coordinate system are consistent.
[0014] In some embodiments, the y-axis direction value of the front virtual camera in the world coordinate system is consistent with the y-axis direction value of the front camera in the world coordinate system;
[0015] The y-axis direction value of the rear virtual camera in the world coordinate system is consistent with the y-axis direction value of the rear camera in the world coordinate system.
[0016] In some embodiments, calculating the extrinsic parameters of the front camera, the middle camera, and the rear camera includes:
[0017] The external parameters of the middle camera are calibrated using a calibration board to obtain the external parameters of the middle camera;
[0018] The external parameters of the front camera are calibrated using a calibration board to obtain the external parameters of the front camera;
[0019] The external parameters of the rear camera are calibrated using a calibration plate to obtain the external parameters of the rear camera.
[0020] In some embodiments, the extrinsic parameters of the intermediate camera are calibrated using a calibration plate to obtain the extrinsic parameters of the intermediate camera, including:
[0021] The camera is calibrated using a calibration plate to obtain the camera's extrinsic parameters and the pose of the reference coordinate system.
[0022] In some embodiments, the extrinsic parameters of the front camera are calibrated using a calibration plate to obtain the extrinsic parameters of the front camera; the extrinsic parameters of the rear camera are calibrated using the calibration plate to obtain the extrinsic parameters of the rear camera, including:
[0023] The front camera is calibrated using a calibration plate to obtain its pose.
[0024] The rear camera is calibrated using a calibration plate to obtain its pose.
[0025] Based on the pose of the front camera and the pose of the reference coordinate system, the extrinsic parameters of the front camera are calculated.
[0026] Based on the pose of the rear camera and the pose of the reference coordinate system, the extrinsic parameters of the rear camera are calculated.
[0027] In some embodiments, the calibration board is a QR code calibration board.
[0028] Secondly, embodiments of this application provide a vehicle positioning system, the system including a physical parameter calculation module, a virtual parameter calculation module, and a vehicle positioning module;
[0029] The entity parameter calculation module is used to calculate the extrinsic parameters of the front camera, the middle camera, and the rear camera, wherein the front camera and the rear camera are located at the edge of the vehicle body to be located, and the middle camera is located at the center of the vehicle body to be located.
[0030] The virtual parameter calculation module is used to calculate the baseline length between the front virtual camera and the rear virtual camera, wherein the front virtual camera and the rear virtual camera are located at the top corner of the vehicle body to be located;
[0031] The vehicle positioning module is used to calculate the pose of the vehicle to be positioned based on the extrinsic parameters of the front camera, the extrinsic parameters of the middle camera, the extrinsic parameters of the rear camera, and the baseline length.
[0032] Compared to related technologies, the vehicle positioning method and system provided in this application embodiment solves the problem of how to improve the accuracy and stability of vehicle positioning estimation. This method calculates the extrinsic parameters of the front camera, the middle camera, and the rear camera, where the front and rear cameras are located at the edges of the vehicle body to be positioned, and the middle camera is located at the center of the vehicle body. It also calculates the baseline length between the front and rear virtual cameras, where the front and rear virtual cameras are located at the top corners of the vehicle body to be positioned. Based on the extrinsic parameters of the front, middle, and rear cameras and the baseline length, the pose of the vehicle body to be positioned is calculated. This method improves the accuracy and stability of vehicle positioning estimation and realizes the calculation of vehicle pose based on the positional and orientation relationships between the three physical cameras and the virtual cameras, thereby improving the accuracy and stability of vehicle positioning. Attached Figure Description
[0033] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings:
[0034] Figure 1 This is a flowchart of the steps of the vehicle positioning method according to an embodiment of this application;
[0035] Figure 2 This is a schematic diagram illustrating the camera position setting according to this embodiment;
[0036] Figure 3 This is a structural block diagram of a vehicle positioning system according to an embodiment of this application;
[0037] Figure 4 This is a schematic diagram of the internal structure of an electronic device according to an embodiment of this application.
[0038] Attached diagram labels: 31, Entity parameter calculation module; 32, Virtual parameter calculation module; 33, Vehicle positioning module. Detailed Implementation
[0039] To make the objectives, technical solutions, and advantages of this application clearer, the application is described and illustrated below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application. All other embodiments obtained by those skilled in the art based on the embodiments provided in this application without inventive effort are within the scope of protection of this application.
[0040] Obviously, the accompanying drawings described below are merely some examples or embodiments of this application. Those skilled in the art can apply this application to other similar scenarios based on these drawings without any inventive effort. Furthermore, it is understood that although the efforts made in this development process may be complex and lengthy, for those skilled in the art related to the content disclosed in this application, any changes to design, manufacturing, or production based on the technical content disclosed in this application are merely conventional technical means and should not be construed as insufficient disclosure of the content of this application.
[0041] In this application, the reference to "embodiment" means that a specific feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places in the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment that is mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described in this application may be combined with other embodiments without conflict.
[0042] Unless otherwise defined, the technical or scientific terms used in this application shall have the ordinary meaning understood by one of ordinary skill in the art to which this application pertains. The terms “a,” “an,” “an,” “the,” and similar words used in this application do not indicate quantity limitation and may indicate singular or plural. The terms “comprising,” “including,” “having,” and any variations thereof used in this application are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or device that includes a series of steps or modules (units) is not limited to the listed steps or units, but may also include steps or units not listed, or may include other steps or units inherent to these processes, methods, products, or devices. The terms “connected,” “linked,” “coupled,” and similar words used in this application are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. “Multiple” used in this application refers to two or more. “And / or” describes the relationship between related objects, indicating that three relationships may exist; for example, “A and / or B” can represent: A alone, A and B simultaneously, and B alone. The character " / " generally indicates that the preceding and following objects are in an "or" relationship. The terms "first," "second," and "third" used in this application are merely to distinguish similar objects and do not represent a specific ordering of the objects.
[0043] This application provides a vehicle positioning method. Figure 1 This is a flowchart of the vehicle positioning method according to an embodiment of this application, as follows: Figure 1 As shown, the method includes the following steps:
[0044] Step S102: Calculate the extrinsic parameters of the front camera, the middle camera, and the rear camera. The front and rear cameras are located at the edges of the vehicle body to be located, and the middle camera is located at the center of the vehicle body to be located.
[0045] Step S102 specifically also includes steps S21 and S22;
[0046] Step S21: The front camera is located at the first edge of the vehicle body to be positioned, and the rear camera is located at the second edge of the vehicle body to be positioned. The first edge and the second edge of the vehicle body are non-intersecting vehicle body edges.
[0047] Step S21 preferably, Figure 2 This is a schematic diagram illustrating the camera position settings according to this embodiment, as shown below. Figure 2As shown, cf is the front camera, cm is the middle camera, cb is the rear camera, and e is the center of the vehicle (the middle camera cm is located at the center e of the vehicle). Furthermore, the camera can be positioned at the bottom of the vehicle, which allows the subsequent vehicle positioning to be unaffected by ambient light, improving the stability of vehicle positioning.
[0048] Step S22: The center camera is calibrated using a calibration board to obtain its extrinsic parameters and the pose of the reference coordinate system; the front camera is calibrated using a calibration board to obtain its pose; the rear camera is calibrated using a calibration board to obtain its pose; the extrinsic parameters of the front camera are calculated based on the pose of the front camera and the pose of the reference coordinate system; the extrinsic parameters of the rear camera are calculated based on the pose of the rear camera and the pose of the reference coordinate system.
[0049] Step S22 preferably uses a QR code calibration board. The same calibration board is observed by the front camera cf, the middle camera cm, and the rear camera cb, respectively, and the poses wMcf (front camera cf), wMcm (middle camera cm), wMcb (rear camera cb), and wMe (reference coordinate system, vehicle center e) are calculated.
[0050] The extrinsic parameter eMcm of the camera cm is equal to (wMe). -1 (The camera coordinate system is the same as the reference coordinate system), and then the formula eMcf=(wMe) is used. -1 The extrinsic parameter eMcf of the front camera cf is calculated using the formula eMcb = (wMe). -1 *wMcb calculates the extrinsic parameter eMcb of the rear camera cb.
[0051] It's important to note that rigid body transformation is a transformation in three-dimensional space that preserves the shape and size of an object, changing only its position and orientation. Rigid body transformation involves transformation matrices, typically represented by a 4x4 matrix. This matrix consists of two parts: a 3x3 rotation matrix and a 3x1 translation vector (the rotation matrix describes the object's rotation, and the translation vector describes its translation). This matrix transforms a point P(x,y,z) in the original coordinate system to a point P'(x',y',z') in the new coordinate system. The transformation is achieved through matrix multiplication. Furthermore, a crucial characteristic of rigid body transformation is its invertibility; that is, if the transformation matrix from the original coordinate system to the new coordinate system is known, the transformation matrix from the new coordinate system to the original coordinate system can be calculated.
[0052] Camera extrinsic parameters are transformation matrices. The rotation matrix describes the camera's rotation, while the translation vector describes its translation. The extrinsic parameter eMcm for the middle camera cm represents the transformation from the reference coordinate system (vehicle center e) to the middle camera coordinate system; the extrinsic parameter eMcf for the front camera cf represents the transformation from the reference coordinate system (vehicle center e) to the front camera coordinate system; and the extrinsic parameter eMcb for the rear camera cb represents the transformation from the reference coordinate system (vehicle center e) to the rear camera coordinate system.
[0053] Step S104: Calculate the baseline length between the front virtual camera and the rear virtual camera, wherein the front virtual camera and the rear virtual camera are located at the top corner of the vehicle body to be located.
[0054] Step S104 specifically also includes steps S41 and S42;
[0055] Step S41: The front virtual camera is located at the first apex of the vehicle body at the first edge of the vehicle body, and the rear virtual camera is located at the second apex of the vehicle body at the second edge of the vehicle body.
[0056] Step S41 is preferably, as follows: Figure 2 As shown, vcf is the virtual front camera, located close to the front camera cf (at the first apex of the vehicle body at the first edge of the vehicle body), collinear with the origin of the front camera coordinate system, and the virtual front camera coordinate system has the same orientation as the front camera coordinate system; vcb is the virtual rear camera, located close to the rear camera cb (at the second apex of the vehicle body at the second edge of the vehicle body), collinear with the origin of the rear camera coordinate system, and the virtual rear camera coordinate system has the same orientation as the rear camera coordinate system.
[0057] Furthermore, in order to ensure that the front virtual camera vcf, the rear virtual camera vcb and the vehicle center e are collinear, it is necessary to satisfy wMvcf[0][3]=wMe[0][3]=wMvcb[0][3], that is, the front virtual camera vcf, the rear virtual camera vcb and the middle camera cm (vehicle center e) have the same x-axis movement tx_e in the world coordinate system.
[0058] Furthermore, since the front virtual camera vcf is close to the front camera cf, it is necessary to satisfy wMvcf[1][3]=wMcf[1][3], that is, the y-axis direction value (ty_cf) of the front virtual camera in the world coordinate system is consistent with the y-axis direction value of the front camera in the world coordinate system.
[0059] Furthermore, since the virtual camera vcb is close to the camera cb, wMvcb[1][3] = wMcb[1][3] must be satisfied. That is, the y-axis direction value (ty_cb) of the virtual camera in the world coordinate system is consistent with the y-axis direction value of the camera in the world coordinate system.
[0060] Furthermore, the coordinate axes of the front virtual camera vcf, the rear virtual camera vcb, and the vehicle center e are aligned, so it is necessary to satisfy wMvcf[0:2][0:2]=wMe[0:2][0:2]=wMvcb[0:2][0:2], that is, the rotation values (Re) of the front virtual camera vcf, the rear virtual camera vcb, and the vehicle center e in the world coordinate system are consistent.
[0061] Step S42: Calculate the baseline length l between the front virtual camera and the rear virtual camera. The specific calculation formula is as follows:
[0062] eMvcf=eMcf*cfMvcf
[0063] eMvcb=eMcb*cbMvcb
[0064] vcfMvcb=(eMvcf) -1 *eMvcb
[0065] l = vcfMvcb[0][3]
[0066] Wherein, eMvcf is the transformation matrix from the reference coordinate system (vehicle center e) to the front virtual camera coordinate system, eMcf is the transformation matrix from the reference coordinate system (vehicle center e) to the front camera coordinate system, cfMvcf is the transformation matrix from the front camera coordinate system to the front virtual camera coordinate system; eMvcb is the transformation matrix from the reference coordinate system (vehicle center e) to the rear virtual camera coordinate system, eMcb is the transformation matrix from the reference coordinate system (vehicle center e) to the rear camera coordinate system, cbMvcb is the transformation matrix from the rear camera coordinate system to the rear virtual camera coordinate system; vcfMvcb is the transformation matrix from the front virtual camera coordinate system to the rear virtual camera coordinate system.
[0067] Step S106: Based on the extrinsic parameters of the front camera, the middle camera, the rear camera, and the baseline length, the pose of the vehicle body to be located is calculated.
[0068] Step S106 specifically also includes steps S61 and S62;
[0069] Step S61: Calculate the real-time perceived value. The specific calculation formula is as follows:
[0070] w1Mvcf=w1Mcf*cfMvcf
[0071] w2Mvcb=w2Mcb*cbMvcb
[0072] Where w1Mvcf represents the transformation matrix of the real-time perception relative to the front virtual camera coordinate system, w1Mcf represents the transformation matrix of the real-time perception relative to the front camera coordinate system; w2Mvcb represents the transformation matrix of the real-time perception relative to the rear virtual camera coordinate system, w2Mcb represents the transformation matrix of the real-time perception relative to the rear camera coordinate system.
[0073] Step S62: The vehicle body to be positioned moves from the taught position to the current position, and calculations are performed using plane geometry:
[0074] Based on the aforementioned extrinsic parameters of the front camera, middle camera, and rear camera, the translation amount of the middle camera is defined as t. cm = cmMcm'.trans, where cmMcm' is the transformation matrix of the middle camera relative to the teaching state, and trans represents taking its translation vector; the translation amount of the front camera is t. cf =cfMcf'.trans, where cfMcf' is the transformation matrix of the front camera relative to the teaching state, and trans represents taking its translation vector; the translation amount of the rear camera is t. cb =cbMcb'.trans, where bMcb' is the transformation matrix of the rear camera relative to the teaching state, and trans represents taking its translation vector.
[0075] Through l cf =t cf -t cm and l cb =t cb -t cm Calculate the translation of the vehicle body to be positioned from the taught position to the current position, where t cf Let t be the translation vector of the front camera's current pose relative to the position during teaching. cm Let l be the translation vector of the camera's current pose relative to the position during teaching. cf The translation vector of the vehicle body under the rotation of the middle camera (i.e., the translation vector of the front camera minus the translation vector of the middle camera); t cb Let l be the translation vector of the rear camera's current pose relative to the pose during teaching. cb It is the translation vector of the vehicle body under the rotation of the middle camera (i.e., the translation vector of the rear camera minus the translation vector of the middle camera).
[0076] Furthermore, based on the triangular relationship of baseline length l, it can be seen that through (|l cf |+|l cb|) / 2l=sin(θ / 2) calculates the angle θ between the camera (front camera, middle camera and rear camera) from the teaching position to the current position, that is, calculates the rotation matrix R of the vehicle body to be positioned from the teaching position to the current position.
[0077] Steps S102 to S106 in this embodiment solve the problem of improving the accuracy and stability of vehicle pose estimation. They enable the calculation of vehicle pose based on the positional and orientation relationships between three physical cameras and a virtual camera, thereby improving the accuracy and stability of vehicle positioning. Compared to existing technologies that use a single camera to estimate vehicle pose, using multiple cameras and a virtual camera to estimate vehicle pose improves estimation stability, reduces errors and deviations, and enhances the accuracy and reliability of the estimation.
[0078] It should be noted that the steps shown in the above process or in the flowchart of the accompanying figures can be executed in a computer system such as a set of computer-executable instructions, and although a logical order is shown in the flowchart, in some cases the steps shown or described may be executed in a different order than that shown here.
[0079] This application provides a vehicle positioning system. Figure 3 This is a structural block diagram of a vehicle positioning system according to an embodiment of this application, such as... Figure 3 As shown, the system includes a physical parameter calculation module 31, a virtual parameter calculation module 32, and a vehicle positioning module 33;
[0080] The entity parameter calculation module 31 is used to calculate the extrinsic parameters of the front camera, the middle camera, and the rear camera, wherein the front camera, the middle camera, and the rear camera are arranged in a straight line on the vehicle body to be positioned.
[0081] The virtual parameter calculation module 32 is used to calculate the baseline length between the front virtual camera and the rear virtual camera, wherein the front virtual camera is located at a preset distance from the front camera and the rear virtual camera is located at a preset distance from the front camera.
[0082] The vehicle positioning module 33 is used to calculate the pose of the vehicle to be positioned based on the extrinsic parameters of the front camera, the middle camera, the rear camera, and the baseline length.
[0083] The entity parameter calculation module 31, virtual parameter calculation module 32, and vehicle positioning module 33 in this embodiment solve the problem of how to improve the accuracy and stability of vehicle pose estimation. They realize the calculation of vehicle pose based on the positional and attitude relationships between the three entity cameras and the virtual camera, thereby improving the accuracy and stability of vehicle positioning.
[0084] It should be noted that the above modules can be functional modules or program modules, and can be implemented through software or hardware. For modules implemented through hardware, the above modules can reside in the same processor; or the above modules can be located in different processors in any combination.
[0085] This embodiment also provides an electronic device, including a memory and a processor, wherein the memory stores a computer program and the processor is configured to run the computer program to perform the steps in any of the above method embodiments.
[0086] Optionally, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor and the input / output device is connected to the processor.
[0087] It should be noted that the specific examples in this embodiment can refer to the examples described in the above embodiments and optional implementations, and will not be repeated here.
[0088] In addition, in conjunction with the vehicle positioning methods in the above embodiments, this application embodiment can provide a storage medium for implementation. The storage medium stores a computer program; when the computer program is executed by a processor, it implements any of the vehicle positioning methods in the above embodiments.
[0089] In one embodiment, a computer device is provided, which may be a terminal. The computer device includes a processor, memory, a network interface, a display screen, and an input device connected via a system bus. The processor provides computing and control capabilities. The memory includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores an operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. The network interface is used to communicate with an external terminal via a network connection. When the computer program is executed by the processor, it implements a vehicle positioning method. The display screen may be a liquid crystal display (LCD) or an e-ink display. The input device may be a touch layer covering the display screen, buttons, a trackball, or a touchpad mounted on the computer device's casing, or an external keyboard, touchpad, or mouse.
[0090] In one embodiment, Figure 4 This is a schematic diagram of the internal structure of an electronic device according to an embodiment of this application, such as... Figure 4 As shown, an electronic device is provided, which can be a server, and its internal structure diagram can be as follows. Figure 4As shown, the electronic device includes a processor, a network interface, internal memory, and non-volatile memory connected via an internal bus. The non-volatile memory stores an operating system, computer programs, and a database. The processor provides computing and control capabilities, the network interface communicates with external terminals via a network connection, the internal memory provides an environment for the operation of the operating system and computer programs, the computer programs are executed by the processor to implement a vehicle positioning method, and the database stores data.
[0091] Those skilled in the art will understand that Figure 4 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the electronic device to which the present application is applied. The specific electronic device may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0092] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. This computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and RAMbus dynamic RAM (RDRAM), etc.
[0093] Those skilled in the art should understand that the technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments have been described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0094] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the invention patent. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this patent application should be determined by the appended claims.
Claims
1. A method of positioning a vehicle body, characterized by, The method comprises: calculating front camera extrinsic parameters of a front camera, middle camera extrinsic parameters of a middle camera and rear camera extrinsic parameters of a rear camera, wherein the front camera and the rear camera are located at the edges of a vehicle body to be positioned, and the middle camera is located at the center of the vehicle body to be positioned; calculating a baseline length between a front virtual camera and a rear virtual camera, wherein the front virtual camera and the rear virtual camera are located at the top corners of the vehicle body to be positioned; the front virtual camera, the rear virtual camera and the center of the vehicle body have the same x-axis movement in a world coordinate system; the y-axis direction value of the front virtual camera in the world coordinate system is consistent with the y-axis direction value of the front camera in the world coordinate system; the y-axis direction value of the rear virtual camera in the world coordinate system is consistent with the y-axis direction value of the rear camera in the world coordinate system; the rotation values of the front virtual camera, the rear virtual camera and the center of the vehicle body in the world coordinate system are consistent; calculating the pose of the vehicle body to be positioned based on the front camera extrinsic parameters, the middle camera extrinsic parameters, the rear camera extrinsic parameters and the baseline length.
2. The method of claim 1, wherein, The front camera and the rear camera are located at the edges of a vehicle body to be positioned, comprising: The front camera is located at a first edge of a vehicle body to be positioned, and the rear camera is located at a second edge of the vehicle body to be positioned, wherein the first edge and the second edge are non-intersecting edges of the vehicle body.
3. The method of claim 2, wherein, The front virtual camera and the rear virtual camera are located at the top corners of the vehicle body to be positioned, comprising: The front virtual camera is located at a first top corner of the first edge of the vehicle body, and the rear virtual camera is located at a second top corner of the second edge of the vehicle body.
4. The method of claim 1, wherein, The calculation of the front camera extrinsic parameters, the middle camera extrinsic parameters and the rear camera extrinsic parameters comprises: extrinsic calibration of the middle camera by a calibration board to obtain the middle camera extrinsic parameters; extrinsic calibration of the front camera by a calibration board to obtain the front camera extrinsic parameters; extrinsic calibration of the rear camera by a calibration board to obtain the rear camera extrinsic parameters.
5. The method of claim 4, wherein, The extrinsic calibration of the middle camera by a calibration board to obtain the middle camera extrinsic parameters comprises: calibration of the middle camera by a calibration board to obtain the middle camera extrinsic parameters and the pose of a reference coordinate system.
6. The method of claim 5, wherein, The extrinsic calibration of the front camera by a calibration board to obtain the front camera extrinsic parameters and the extrinsic calibration of the rear camera by a calibration board to obtain the rear camera extrinsic parameters comprises: calibration of the front camera by a calibration board to obtain the pose of the front camera; calibration of the rear camera by a calibration board to obtain the pose of the rear camera; calculation of the front camera extrinsic parameters based on the pose of the front camera and the pose of the reference coordinate system; calculation of the rear camera extrinsic parameters based on the pose of the rear camera and the pose of the reference coordinate system.
7. The method of claim 4, wherein, The calibration board is a two-dimensional code calibration board.
8. A vehicle body positioning system, characterized by, The system comprises an entity parameter calculation module, a virtual parameter calculation module and a vehicle body positioning module; The entity parameter calculation module is configured to calculate front camera extrinsic parameters of the front camera, middle camera extrinsic parameters of the middle camera, and rear camera extrinsic parameters of the rear camera, wherein the front camera and the rear camera are located at edges of a vehicle body to be positioned, and the middle camera is located at a center of the vehicle body to be positioned. The virtual parameter calculation module is configured to calculate a baseline length between a front virtual camera and a rear virtual camera, wherein the front virtual camera and the rear virtual camera are located at top corners of the vehicle body to be positioned; the front virtual camera, the rear virtual camera, and the center of the vehicle body have the same x-axis movement in a world coordinate system; a y-axis direction value of the front virtual camera in the world coordinate system is consistent with a y-axis direction value of the front camera in the world coordinate system; a y-axis direction value of the rear virtual camera in the world coordinate system is consistent with a y-axis direction value of the rear camera in the world coordinate system; the front virtual camera, the rear virtual camera, and the center of the vehicle body have the same rotation value in the world coordinate system. The vehicle positioning module is configured to calculate a pose of the vehicle body to be positioned based on the front camera extrinsic parameters, the middle camera extrinsic parameters, the rear camera extrinsic parameters, and the baseline length.
Citation Information
Patent Citations
Stereo camera
CN109564091A
Image-based pose determination method and device, storage medium and electronic equipment
CN112509047A