A scanning head pose detection method, device, equipment and medium
By acquiring the three-dimensional coordinates of the external frame markers of the scanning head using a multi-view tracking camera, and calculating the rotation matrix and translation vector, the problem of insufficient positioning accuracy and stability of the scanning head in a binocular camera system is solved, achieving higher measurement accuracy.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- HANGZHOU SHINING TIANYUAN 3D INSPECTION TECH CO LTD
- Filing Date
- 2022-11-25
- Publication Date
- 2026-05-08
AI Technical Summary
In existing binocular camera-based tracking and scanning measurement systems, the positioning accuracy and stability of the scanning head pose are difficult to guarantee in the three-dimensional shape measurement of large workpieces, which affects the measurement accuracy.
A multi-camera tracking system (more than two cameras) is used to track and scan the marker points on the outer frame of the scanning head, obtaining the three-dimensional coordinates of at least three valid marker points. The rotation matrix and translation vector of the scanner coordinate system to the tracker coordinate system are calculated to improve the positioning accuracy and stability.
This improves the positioning accuracy and stability of the tracker for the scanning head pose, enhances the overall measurement accuracy of the tracker scanning measurement system, and solves the problem of low measurement accuracy in traditional methods.
Smart Images

Figure CN115984371B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of scanning processing technology, and in particular to a scanning head pose detection method, apparatus, device and medium. Background Technology
[0002] Typically, the tracking and scanning measurement method mainly includes real-time tracking and positioning of the scanning head by the tracker, scanning measurement of the scanning head, and unification of the coordinate system of the scanning measurement data. The scanning measurement accuracy of the scanning head can be maintained at a high level. The unification of the coordinate system of the scanning data mainly depends on the real-time positioning accuracy of the scanning head by the tracker. Therefore, the tracking and positioning accuracy of the scanning head by the tracker directly determines the final scanning measurement accuracy.
[0003] Since tracking scanning measurement systems are typically used for three-dimensional topography measurement of large workpieces, the baseline distance of the binocular cameras constituting the tracker is usually relatively long. When performing pose detection on the scanning head, the difference in shooting angles between the binocular cameras and the scanning head is quite significant. The markers attached to the outer frame of the scanning head cannot simultaneously achieve good imaging quality on both cameras. Therefore, it is difficult to guarantee the positioning accuracy and stability of the scanning head's pose, ultimately affecting the measurement accuracy of the tracking scanning measurement system. Summary of the Invention
[0004] In order to solve the above-mentioned technical problems, or at least partially solve the above-mentioned technical problems, this disclosure provides a scanning head pose detection method, apparatus, device and medium.
[0005] This disclosure provides a method for detecting the pose of a scanning head, the method comprising:
[0006] Based on N tracking cameras, the marker points on the outer frame of the scanning head are tracked and scanned to obtain at least three valid three-dimensional coordinates of the marker points; where N is a positive integer greater than 2;
[0007] Based on the three-dimensional coordinates of the at least three valid marker points and the reference coordinates of each valid marker point in the frame coordinate system, the rotation matrix and translation vector for transforming the scanner coordinate system to the tracker coordinate system are calculated.
[0008] This disclosure also provides a scanning head pose detection device, the device comprising:
[0009] The scanning processing module is used to perform tracking and scanning processing on the marker points on the outer frame of the scanning head based on N tracking cameras, so as to obtain the three-dimensional coordinates of at least three valid marker points; where N is a positive integer greater than 2;
[0010] The calculation module is used to calculate, based on the three-dimensional coordinates of the at least three valid marker points and the reference coordinates of each valid marker point in the frame coordinate system, the rotation matrix and translation vector of the scanner coordinate system to the tracker coordinate system.
[0011] This disclosure also provides an electronic device, the electronic device comprising: a processor; a memory for storing executable instructions of the processor; the processor being configured to read the executable instructions from the memory and execute the instructions to implement the scanning head pose detection method provided in this disclosure.
[0012] This disclosure also provides a computer-readable storage medium storing a computer program for performing the scanning head pose detection method provided in this disclosure.
[0013] Compared with the prior art, the technical solution provided in this disclosure has the following advantages: The scanning head pose detection scheme provided in this disclosure is based on N tracking cameras to track and scan marker points on the outer frame of the scanning head, obtaining at least three valid marker point three-dimensional coordinates; where N is a positive integer greater than 2; based on the at least three valid marker point three-dimensional coordinates and the reference coordinates of each valid marker point in the frame coordinate system, the rotation matrix and translation vector for transforming the scanner coordinate system to the tracker coordinate system are calculated. By adopting the above technical solution, the positional relationship between the scanning head coordinate system and the tracker coordinate system is calculated based on marker point data acquired by more than two tracking cameras, thereby improving the positioning accuracy and stability of the scanning head pose by the tracker, as well as the overall measurement accuracy of the tracker scanning measurement system. Attached Figure Description
[0014] The above and other features, advantages, and aspects of the embodiments of this disclosure will become more apparent from the accompanying drawings and the following detailed description. Throughout the drawings, the same or similar reference numerals denote the same or similar elements. It should be understood that the drawings are schematic, and the originals and elements are not necessarily drawn to scale.
[0015] Figure 1 A schematic flowchart illustrating a scanning head pose detection method provided in an embodiment of this disclosure;
[0016] Figure 2 A flowchart illustrating another scanning head pose detection method provided in this embodiment of the present disclosure;
[0017] Figure 3 A schematic diagram of a multi-view tracking camera provided in an embodiment of this disclosure;
[0018] Figure 4 This is a schematic diagram of the structure of a scanning head pose detection device provided in an embodiment of the present disclosure;
[0019] Figure 5 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this disclosure. Detailed Implementation
[0020] Embodiments of this disclosure will now be described in more detail with reference to the accompanying drawings. While some embodiments of this disclosure are shown in the drawings, it should be understood that this disclosure can be implemented in various forms and should not be construed as limited to the embodiments set forth herein. Rather, these embodiments are provided to provide a more thorough and complete understanding of this disclosure. It should be understood that the accompanying drawings and embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of protection of this disclosure.
[0021] It should be understood that the steps described in the method embodiments of this disclosure may be performed in different orders and / or in parallel. Furthermore, the method embodiments may include additional steps and / or omit the steps shown. The scope of this disclosure is not limited in this respect.
[0022] The term "comprising" and its variations as used herein are open-ended inclusions, meaning "including but not limited to". The term "based on" means "at least partially based on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". Definitions of other terms will be given in the description below.
[0023] It should be noted that the concepts of "first" and "second" mentioned in this disclosure are used only to distinguish different devices, modules or units, and are not used to limit the order of functions performed by these devices, modules or units or their interdependencies.
[0024] It should be noted that the terms "a" and "a plurality of" used in this disclosure are illustrative rather than restrictive, and those skilled in the art should understand that, unless otherwise expressly indicated in the context, they should be understood as "one or more".
[0025] The names of messages or information exchanged between multiple devices in the embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of such messages or information.
[0026] Specifically, the multi-camera-based tracking and scanning measurement system consists of a tracker composed of multiple cameras and a scanning head based on structured light measurement. The tracking and scanning measurement process is achieved by the tracker detecting the marker points on the outer frame of the scanning head in real time to realize the real-time pose of the scanning head, thereby unifying the structured light measurement data of the scanning head into the coordinate system of the tracker and completing the scanning measurement of the object under test.
[0027] To address the issue of low accuracy and stability in current binocular camera-based tracking and scanning measurement methods and devices during the scanning measurement process, the scanning head pose detection method of this disclosure improves the positioning accuracy and stability of the scanning head pose by the tracker, as well as the overall measurement accuracy of the tracker scanning measurement system, by designing a tracking and positioning device and a tracking and positioning method based on multiple cameras (more than two cameras). The method uses marker point data acquired by more than two tracking cameras to calculate the positional relationship between the scanning head coordinate system and the tracker coordinate system.
[0028] Figure 1 This is a flowchart illustrating a scanning head pose detection method provided in an embodiment of the present disclosure. This method can be executed by a scanning head pose detection device, which can be implemented using software and / or hardware, and is generally integrated into an electronic device. Figure 1 As shown, the method includes:
[0029] Step 101: Based on N tracking cameras, perform tracking and scanning processing on the marker points on the outer frame of the scanning head to obtain at least three valid three-dimensional coordinates of the marker points; where N is a positive integer greater than 2.
[0030] Where N can be a positive integer greater than 2, depending on the application scenario, such as three tracking cameras. At least three valid 3D coordinates of the marker points must be obtained to calculate the rotation matrix and translation vector for transforming the scanner coordinate system to the tracker coordinate system.
[0031] In this embodiment of the disclosure, when the multi-view tracking camera detects the pose of the scanning head, it acquires the three-dimensional coordinates of the valid marker points by collecting the marker points (such as circular reflective marker points) pasted on the outer frame of the scanning head and performing operations such as identification, positioning, and reconstruction of the marker points.
[0032] In this embodiment of the disclosure, a multi-view tracking camera detects the pose of the scanning head. At least two tracking cameras in the multi-view tracking camera detect valid marker points, and the number of valid marker points is at least three. The positional relationship between the scanning head coordinate system and the tracker coordinate system can be calculated through the marker points.
[0033] In this embodiment of the disclosure, there are many ways to obtain at least three valid three-dimensional coordinates of marker points by tracking and scanning the marker points on the outer frame of the scanning head based on N tracking cameras. In some implementations, the pixel coordinates and major and minor axes of the marker points are obtained based on the images acquired by each tracking camera. M pixel coordinate pairs are determined from the N pixel coordinates based on the major and minor axes. Here, M is a positive integer greater than 3. The M pixel coordinate pairs are reconstructed based on a preset triangulation principle to obtain at least three valid three-dimensional coordinates of the marker points.
[0034] In other implementations, based on the images acquired by each tracking camera, the pixel coordinates of the marker points and the angle between the marker point plane and the camera imaging plane are obtained. Based on the angle, M pixel coordinate pairs are determined from N pixel coordinates; where M is a positive integer greater than 3. Based on a preset triangulation principle, the M pixel coordinate pairs are reconstructed to obtain at least three valid three-dimensional coordinates of the marker points.
[0035] Step 102: Based on the three-dimensional coordinates of at least three valid marker points and the reference coordinates of each valid marker point in the frame coordinate system, calculate the rotation matrix and translation vector for transforming the scanner coordinate system to the tracker coordinate system.
[0036] The reference coordinates of each valid marker point in the frame coordinate system refer to the coordinate information of the valid marker point in the frame coordinate system.
[0037] In this embodiment of the disclosure, there are many ways to calculate the rotation matrix and translation vector from the scanner coordinate system to the tracker coordinate system based on the three-dimensional coordinates of at least three valid marker points and the reference coordinates of each valid marker point in the frame coordinate system. For example, the rotation matrix and translation vector from the scanner coordinate system to the tracker coordinate system can be calculated using OpenCVSharp three-dimensional points. The specific settings can be selected according to the application scenario.
[0038] The scanning head pose detection scheme provided in this disclosure uses N tracking cameras to track and scan marker points on the outer frame of the scanning head, obtaining at least three valid three-dimensional coordinates of the marker points; where N is a positive integer greater than 2. Based on the three-dimensional coordinates of the at least three valid marker points and the reference coordinates of each valid marker point in the frame coordinate system, a rotation matrix and translation vector are calculated to transform the scanner coordinate system to the tracker coordinate system. By employing this technical solution, the positional relationship between the scanning head coordinate system and the tracker coordinate system is calculated based on marker point data acquired by more than two tracking cameras, thereby improving the positioning accuracy and stability of the scanning head pose by the tracker, as well as the overall measurement accuracy of the tracker scanning measurement system.
[0039] Figure 2 This is a flowchart illustrating another scanning head pose detection method provided in this embodiment of the present disclosure. This embodiment further optimizes the above-described scanning head pose detection method based on the previous embodiment. Figure 2 As shown, the method includes:
[0040] Step 201: Take multiple images of the calibrator containing marker points or coded points at multiple positions and in multiple poses using a multi-view tracking camera to obtain multiple sets of first images, and calculate the intrinsic and extrinsic parameters of the multi-view tracking camera using the appropriate multi-view camera calibration method and the multiple sets of first images.
[0041] Specifically, the embodiments of this disclosure employ a multi-view camera tracker to achieve high-precision and stable position and pose detection of the scanning head, thereby achieving high-precision and high-stability tracking and scanning measurement.
[0042] For example, tracking scan measurement based on multi-view tracking cameras, such as Figure 3 The multi-view tracking camera shown consists of three tracking cameras 10.
[0043] Specifically, the calibration of a multi-view tracker mainly involves calibrating the intrinsic and extrinsic parameters of the multi-view tracking camera. The calibration parameters primarily include the intrinsic parameter K of the multi-view tracking camera. i ,(i=0,1,…,N-1), the extrinsic parameters R of the multi-view tracking camera i t i (i = 0, 1, ..., N-1). This process involves acquiring multiple sets of images by taking pictures of the calibrator (a standard instrument containing marker points or coded points) at multiple positions and orientations, and then selecting the appropriate calibration method for the multi-view tracking camera (e.g., using a 4-point or 11-point straight rod to calibrate the multi-view tracking camera, or using a large marble plane to calibrate the multi-view tracking camera) to calculate the intrinsic and extrinsic parameters of the multi-view tracking camera.
[0044] Step 202: Take multiple images of the calibrator containing marker points or coded points at multiple positions using the scanning head camera to obtain multiple sets of second images, and calculate the intrinsic and extrinsic parameters of the scanning head camera using the appropriate camera calibration method and the multiple sets of second images.
[0045] Step 203: Calculate the mathematical expressions of multiple laser line emitting surfaces in the scanning head coordinate system and calculate the rigid body transformation relationship between the external frame coordinate system of the scanning head and the scanning head coordinate system.
[0046] Specifically, the scanning head system calibration mainly includes the calibration of the scanning head camera's internal and external parameters and the calibration of the scanning head laser line. The calibration of the scanning head camera's internal and external parameters can be achieved by taking multiple images at multiple locations with the calibrator to obtain multiple sets of second images, and by selecting the appropriate camera calibration method and the multiple sets of second images to calculate the internal and external parameters of the scanning head camera.
[0047] Specifically, the laser line calibration of the scanning head involves calculating the mathematical expressions of multiple laser line emitting surfaces in the scanning head coordinate system. That is, the mathematical expression of the laser surface can be expressed by plane equations or quadratic surface equations depending on the characteristics of the laser surface. The plane equation is shown in formula (1), and the quadratic surface equation is shown in formula (2).
[0048] ax + by + cz + d = 0 (1)
[0049] Ax 2 +By 2 +Cz2 +Dxy+Exz+Fyz+Gx+Hy+Iz+J=0 (2)
[0050] Where a, b, c, and d are plane equation parameters, (x, y, z) are three-dimensional point coordinates; A, B, C, D, E, F, G, H, I, and J are quadric surface equation parameters.
[0051] Specifically, the rigid body transformation relationship between the external frame coordinate system and the scanning head coordinate system is calculated, i.e., hand-eye calibration, i.e., the scanning head coordinate system P. scan Coordinate system P connected to the external frame Frame The conversion relationship between them is shown in formula (3):
[0052] P Scan =R*P Frame +t (3)
[0053] Among them, P scan Let P be the coordinates of the point cloud in the scanning head coordinate system. Frame R represents the coordinates of the point cloud in the frame coordinate system, and R and t are the rotation matrix and translation vector for transforming the frame coordinate system to the scan head coordinate system.
[0054] It is understandable that the execution order of steps 201-203 can be selected and set according to the needs of the application scenario.
[0055] Step 204: Based on the images acquired by each tracking camera, obtain the pixel coordinates and major and minor axes of the marker points. Based on the major and minor axes, determine M pixel coordinate pairs from the N pixel coordinates; where M is a positive integer greater than 3. Reconstruct the M pixel coordinate pairs based on the preset triangulation principle to obtain at least three valid three-dimensional coordinates of the marker points.
[0056] Step 205: Based on the images acquired by each tracking camera, obtain the pixel coordinates of the marker points and the angle between the marker point plane and the camera imaging plane. Based on the angle, determine M pixel coordinate pairs from N pixel coordinates; where M is a positive integer greater than 3. Reconstruct the M pixel coordinate pairs based on the preset triangulation principle to obtain at least three valid three-dimensional coordinates of the marker points.
[0057] It should be noted that after step 203, either step 201 or step 202 can be executed. The execution order of steps 201-202 can be determined according to the actual situation. Figure 2 This is just an example.
[0058] Step 206: Based on the three-dimensional coordinates of at least three valid marker points and the reference coordinates of each valid marker point in the frame coordinate system, calculate the rotation matrix and translation vector for transforming the scanner coordinate system to the tracker coordinate system.
[0059] Step 207: Acquire scanning data based on the scanning head, and calculate the tracking scanning measurement data based on the rotation matrix and translation vector transformed from the scanner coordinate system to the tracker coordinate system and the scanning data.
[0060] Specifically, the multi-view tracking camera detects the pose of the scanning head. At least two cameras in the multi-view tracking camera detect valid marker points, and the number of valid marker points is at least three. The positional relationship between the scanning head coordinate system and the tracker coordinate system can be calculated from the marker points, as shown in equation (4):
[0061] P Tracker =R FS *P Scan +t FS (4)
[0062] Among them, P Tracker Let R be the coordinates of the point cloud in the tracker's coordinate system. FS t FS This is the rotation matrix and translation vector for transforming the scanner coordinate system to the tracker coordinate system.
[0063] Specifically, when multi-view tracking cameras detect the pose of the scanning head, they acquire the three-dimensional coordinates of the markers by collecting data from markers attached to the external frame of the scanning head and performing operations such as identification, localization, and reconstruction. The information of the markers mainly includes the pixel coordinates (u) of their center (e.g., the center of a circle in the case of a circle) in the images acquired by each camera. i v i ), i = 0, 1, 2...N-1 and major and minor axes (a i b i ), i = 0, 1, 2...N-1 (N is the number of cameras), 3D coordinates P(x, y, z) and the unit normal vector N(n) of the plane containing them. x n y n z ).
[0064] Typically, given the pixel coordinates (u) of a marker point in two images... i v i Given i = 0, 1, the three-dimensional coordinates of the current marker point can be obtained based on the principle of triangulation. Multi-view cameras can use the angle α between the marker point plane and the camera's imaging plane. i For i = 0, 1, 2...N-1, select the optimal camera reconstruction combination (e.g., choose a camera combination with the smaller angle for reconstruction), or you can use the ratio β of the major and minor axes in the image of the reflective markers. i =a i / b iThe camera combination with i = 0, 1, 2...N-1 close to 1 or smaller is used for reconstruction, thereby improving the reliability and accuracy of reflective marker reconstruction and ensuring the positioning accuracy of the tracker for the scanning head attitude.
[0065] Furthermore, after the scanning head has completed calibration, it calculates the point cloud data of the structured light reconstruction at the current position, aligns the coordinate system of the scanning measurement data, and transforms the acquired measurement data into the coordinate system of the tracker through the scanning head pose obtained in formula (4).
[0066] Further, point cloud post-processing, such as point cloud optimization and meshing of the scanning measurement data in the tracker coordinate system, and outputting the data results.
[0067] Therefore, it is possible to calibrate a multi-view tracking scanning measurement system, align coordinates of single-frame scanning data (real-time scanning measurement process), and process and export point cloud data.
[0068] The scanning head pose detection method of this disclosure can ensure the positioning accuracy and stability of the scanning head by adopting a tracking and positioning method based on multi-camera tracking (more than 2 cameras), thereby obtaining higher quality scanning measurement data results. It effectively solves the problem of low measurement accuracy of traditional binocular camera-based tracking scanning systems, while increasing the effective field of view for scanning head tracking and positioning, and improving work efficiency.
[0069] Figure 4 This is a schematic diagram of a scanning head pose detection device provided in an embodiment of this disclosure. The device can be implemented by software and / or hardware, and is generally integrated into an electronic device. Figure 4 As shown, the device includes:
[0070] The scanning processing module 301 is used to perform tracking scanning processing on the marker points on the outer frame of the scanning head based on N tracking cameras, and obtain at least three valid three-dimensional coordinates of the marker points; where N is a positive integer greater than 2;
[0071] The calculation module 302 is used to calculate, based on the three-dimensional coordinates of the at least three valid marker points and the reference coordinates of each valid marker point in the frame coordinate system, to obtain the rotation matrix and translation vector of the scanner coordinate system to the tracker coordinate system.
[0072] Optionally, the scanning processing module 301 is specifically used for:
[0073] Based on the images captured by each of the tracking cameras, obtain the pixel coordinates and major and minor axes of the marker points;
[0074] Based on the major and minor semi-axes, determine M pixel coordinate pairs from N pixel coordinates; where M is a positive integer greater than 3;
[0075] Based on the preset triangulation principle, the coordinates of the M pixel pairs are reconstructed to obtain the three-dimensional coordinates of the at least three valid marker points.
[0076] Optionally, the scanning processing module 301 is specifically used for:
[0077] Based on the images captured by each of the tracking cameras, the pixel coordinates of the marker points and the angle between the marker point plane and the camera imaging plane are obtained;
[0078] Based on the included angle, determine M pixel coordinate pairs from N pixel coordinates; where M is a positive integer greater than 3;
[0079] Based on the preset triangulation principle, the coordinates of the M pixel pairs are reconstructed to obtain the three-dimensional coordinates of the at least three valid marker points.
[0080] Optionally, the device further includes:
[0081] The acquisition module is used to acquire scan data based on the scanning head;
[0082] The processing module is used to calculate the tracking scan measurement data based on the rotation matrix and translation vector transformed from the scanner coordinate system to the tracker coordinate system and the scan data.
[0083] Optionally, the device further includes a calibration module for:
[0084] Multiple sets of first images are obtained by taking pictures of the calibrator containing marker points or coded points at multiple positions and in multiple poses using the N tracking cameras. The intrinsic and extrinsic parameters of the N tracking cameras are calculated by selecting the corresponding N camera calibration methods and the multiple sets of first images.
[0085] Multiple sets of second images are obtained by taking pictures of the calibrator containing marker points or coded points at multiple positions using a scanning head camera. The intrinsic and extrinsic parameters of the scanning head camera are calculated by selecting an appropriate camera calibration method and the multiple sets of second images.
[0086] Calculate the mathematical expressions for multiple laser line emitting surfaces in the scanning head coordinate system;
[0087] Calculate the rigid body transformation relationship between the external frame coordinate system and the scanning head coordinate system.
[0088] The scanning head pose detection device provided in this disclosure can execute the scanning head pose detection method provided in any embodiment of this disclosure, and has the corresponding functional modules and beneficial effects of executing the method.
[0089] This disclosure also provides a computer program product, including a computer program / instructions, which, when executed by a processor, implements the scanning head pose detection method provided in any embodiment of this disclosure.
[0090] Figure 5 This is a schematic diagram of an electronic device provided in an embodiment of the present disclosure. See below for details. Figure 5 The diagram illustrates a structural schematic suitable for implementing the electronic device 400 in the embodiments of this disclosure. The electronic device 400 in the embodiments of this disclosure may include, but is not limited to, mobile terminals such as mobile phones, laptops, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), in-vehicle terminals (e.g., in-vehicle navigation terminals), and fixed terminals such as digital TVs and desktop computers. Figure 5 The electronic device shown is merely an example and should not be construed as limiting the functionality and scope of the embodiments disclosed herein.
[0091] like Figure 5 As shown, electronic device 400 may include a processing device (e.g., a central processing unit, a graphics processor, etc.) 401, which can perform various appropriate actions and processes according to a program stored in read-only memory (ROM) 402 or a program loaded from storage device 408 into random access memory (RAM) 403. RAM 403 also stores various programs and data required for the operation of electronic device 400. Processing device 401, ROM 402, and RAM 403 are interconnected via bus 404. Input / output (I / O) interface 405 is also connected to bus 404.
[0092] Typically, the following devices can be connected to I / O interface 405: input devices 406 including, for example, touchscreens, touchpads, keyboards, mice, cameras, microphones, accelerometers, gyroscopes, etc.; output devices 407 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; storage devices 408 including, for example, magnetic tapes, hard disks, etc.; and communication devices 409. Communication device 409 allows electronic device 400 to communicate wirelessly or wiredly with other devices to exchange data. Although Figure 5 An electronic device 400 with various devices is shown; however, it should be understood that it is not required to implement or possess all of the devices shown. More or fewer devices may be implemented or possessed alternatively.
[0093] In particular, according to embodiments of this disclosure, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of this disclosure include a computer program product comprising a computer program carried on a non-transitory computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via a communication device 409, or installed from a storage device 408, or installed from a ROM 402. When the computer program is executed by the processing device 401, it performs the functions defined in the scanning head pose detection method of embodiments of this disclosure.
[0094] It should be noted that the computer-readable medium described in this disclosure can be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. A computer-readable storage medium can be, for example,—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this disclosure, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in connection with an instruction execution system, apparatus, or device. In this disclosure, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium can be any computer-readable medium other than a computer-readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to: wires, optical fibers, RF (radio frequency), etc., or any suitable combination thereof.
[0095] In some implementations, clients and servers can communicate using any currently known or future-developed network protocol such as HTTP (Hypertext Transfer Protocol) and can interconnect with digital data communication (e.g., communication networks) of any form or medium. Examples of communication networks include local area networks (“LANs”), wide area networks (“WANs”), the Internet (e.g., the Internet of Things), and end-to-end networks (e.g., ad hoc end-to-end networks), as well as any currently known or future-developed networks.
[0096] The aforementioned computer-readable medium may be included in the aforementioned electronic device; or it may exist independently and not assembled into the electronic device.
[0097] The aforementioned computer-readable medium carries one or more programs, which, when executed by the electronic device, cause the electronic device to: perform tracking and scanning processing on the marker points on the outer frame of the scanning head based on N tracking cameras to obtain the three-dimensional coordinates of at least three valid marker points; where N is a positive integer greater than 2; and calculate, based on the three-dimensional coordinates of at least three valid marker points and the reference coordinates of each valid marker point in the frame coordinate system, obtain the rotation matrix and translation vector for transforming the scanner coordinate system to the tracker coordinate system.
[0098] Computer program code for performing the operations of this disclosure can be written in one or more programming languages or a combination thereof, including but not limited to object-oriented programming languages such as Java, Smalltalk, and C++, as well as conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0099] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this disclosure. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0100] The units described in the embodiments of this disclosure can be implemented in software or hardware. The names of the units are not, in some cases, intended to limit the specific unit.
[0101] The functions described above in this document can be performed, at least in part, by one or more hardware logic components. For example, exemplary types of hardware logic components that can be used, without limitation, include: Field Programmable Gate Arrays (FPGAs), Application-Specific Integrated Circuits (ASICs), Application Standard Products (ASSPs), System-on-Chip (SoCs), Complex Programmable Logic Devices (CPLDs), and so on.
[0102] In the context of this disclosure, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can be, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
[0103] According to one or more embodiments of this disclosure, this disclosure provides an electronic device, including:
[0104] processor;
[0105] Memory used to store the processor's executable instructions;
[0106] The processor is configured to read the executable instructions from the memory and execute the instructions to implement the scanning head pose detection method as provided in any of the present disclosure.
[0107] According to one or more embodiments of the present disclosure, the present disclosure provides a computer-readable storage medium storing a computer program for performing a scanning head pose detection method as described in any of the present disclosure.
[0108] The above description is merely a preferred embodiment of this disclosure and an explanation of the technical principles employed. Those skilled in the art should understand that the scope of this disclosure is not limited to technical solutions formed by specific combinations of the above-described technical features, but should also cover other technical solutions formed by arbitrary combinations of the above-described technical features or their equivalents without departing from the above-described concept. For example, technical solutions formed by substituting the above features with (but not limited to) technical features disclosed in this disclosure that have similar functions.
[0109] Furthermore, while the operations are described in a specific order, this should not be construed as requiring these operations to be performed in the specific order shown or in a sequential order. In certain environments, multitasking and parallel processing may be advantageous. Similarly, while several specific implementation details are included in the above discussion, these should not be construed as limiting the scope of this disclosure. Certain features described in the context of individual embodiments may also be implemented in combination in a single embodiment. Conversely, various features described in the context of a single embodiment may also be implemented individually or in any suitable sub-combination in multiple embodiments.
[0110] Although the subject matter has been described using language specific to structural features and / or methodological logic, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or actions described above. Rather, the specific features and actions described above are merely illustrative examples of implementing the claims.
Claims
1. A method for detecting the pose of a scanning head, characterized in that, include: Based on N tracking cameras, the marker points on the outer frame of the scanning head are tracked and scanned to obtain at least three valid three-dimensional coordinates of the marker points; where N is a positive integer greater than 2; wherein, based on the image acquired by each tracking camera, the pixel coordinates, major and minor axes, and the angle between the marker point plane and the camera imaging plane are obtained; based on the major and minor axes or the angle, M pixel coordinate pairs are determined from the N pixel coordinates; based on a preset triangulation principle, the M pixel coordinate pairs are reconstructed to obtain the at least three valid three-dimensional coordinates of the marker points; where M is a positive integer greater than 3; wherein, the camera combination with the smaller angle or the camera combination with a major and minor axis ratio close to 1 or smaller is selected for reconstruction; Based on the three-dimensional coordinates of the at least three valid marker points and the reference coordinates of each valid marker point in the frame coordinate system, the rotation matrix and translation vector for transforming the scanner coordinate system to the tracker coordinate system are calculated; wherein, the reference coordinates of each valid marker point in the frame coordinate system refer to the coordinate information of the valid marker point in the frame coordinate system.
2. The scanning head pose detection method according to claim 1, characterized in that, Also includes: Data is acquired based on the scanning head; Based on the rotation matrix and translation vector transformed from the scanner coordinate system to the tracker coordinate system, and the scan data, the tracking scan measurement data is obtained.
3. The scanning head pose detection method according to claim 1, characterized in that, Also includes: Multiple sets of first images are obtained by taking pictures of the calibrator containing marker points or coded points at multiple positions and in multiple poses using the N tracking cameras. The intrinsic and extrinsic parameters of the N tracking cameras are calculated by selecting the corresponding N camera calibration methods and the multiple sets of first images. Multiple sets of second images are obtained by taking pictures of the calibrator containing marker points or coded points at multiple positions using a scanning head camera. The intrinsic and extrinsic parameters of the scanning head camera are calculated by selecting an appropriate camera calibration method and the multiple sets of second images. Calculate the mathematical expressions for multiple laser line emitting surfaces in the scanning head coordinate system; Calculate the rigid body transformation relationship between the external frame coordinate system and the scanning head coordinate system.
4. A scanning head pose detection device, characterized in that, include: The scanning processing module is used to perform tracking scanning processing on the marker points on the outer frame of the scanning head based on N tracking cameras to obtain at least three valid three-dimensional coordinates of the marker points; where N is a positive integer greater than 2; wherein, based on the image acquired by each of the tracking cameras, the pixel coordinates, major and minor axes, and the angle between the marker point plane and the camera imaging plane are obtained; based on the major and minor axes or the angle, M pixel coordinate pairs are determined from the N pixel coordinates; and based on a preset triangulation principle, the M pixel coordinate pairs are reconstructed to obtain the at least three valid three-dimensional coordinates of the marker points, where M is a positive integer greater than 3; wherein, the camera combination with the smaller angle or the camera combination with a major and minor axis ratio close to 1 or smaller is selected for reconstruction; The calculation module is used to calculate, based on the three-dimensional coordinates of the at least three valid marker points and the reference coordinates of each valid marker point in the frame coordinate system, to obtain the rotation matrix and translation vector of the scanner coordinate system to the tracker coordinate system; wherein, the reference coordinates of each valid marker point in the frame coordinate system refer to the coordinate information of the valid marker point in the frame coordinate system.
5. An electronic device, characterized in that, The electronic device includes: processor; Memory used to store the processor's executable instructions; The processor is configured to read the executable instructions from the memory and execute the instructions to implement the scanning head pose detection method according to any one of claims 1-3.
6. A computer-readable storage medium, characterized in that, The storage medium stores a computer program for executing the scanning head pose detection method according to any one of claims 1-3.
Citation Information
Patent Citations
Tracking type three-dimensional scanning system
CN111623725A