Online hand-eye calibration method, device and equipment for surgical robot and medium
Through the online hand-eye calibration method, the data of the binocular camera and the robotic arm motor system are used to calculate the position error and time difference, and automatically adjust the trajectory and conversion matrix. This solves the problem of calibration parameter errors of the surgical robot, improves the calibration accuracy and intelligence, and reduces maintenance costs.
Patent Information
- Application Number
- CN202410701072.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-31
- Publication Date
- 2024-08-30
AI Technical Summary
The existing hand-eye calibration method of surgical robots needs to be completed when the robot leaves the factory. As the use time increases, the wear and tear of the mechanical structure and the deformation of the cables lead to errors in the calibration parameters. Regular maintenance is required for recalibration, which increases maintenance costs and complexity. .
Through the online hand-eye calibration method, the binocular camera and the robotic arm motor system are used to obtain the attitude data of the instrument, calculate the position error and time difference, and automatically adjust the trajectory and transformation matrix to achieve real-time adaptive calibration and avoid human intervention.
It improves the calibration accuracy and intelligence of the surgical robot during use, reduces maintenance costs and complexity, and enables real-time comparison and automatic calibration of robotic arm attitude data and image attitude data.
Smart Images

Figure CN118570291A
Abstract
Description
Technical Field
[0001] The present disclosure relates to the technical field of computers and medical devices, and in particular to an online hand-eye calibration method, device, equipment and medium for a surgical robot. Background Art
[0002] With the advancement of technology, surgical robots are gradually being applied to minimally invasive surgery. Through clear imaging systems and flexible robotic arms, surgical robots assist doctors in performing complex surgical operations in a minimally invasive manner, completing intraoperative positioning, cutting, puncture, hemostasis, suturing and other operations.
[0003] The doctor observes the patient's intracavitary tissue and the position of the surgical instruments in the field of view of the lens through the images provided by the laparoscope camera, and controls the movement of the instruments at the end of the remote robotic arm through the master hand of the master hand console to complete the surgical action. To complete the above operations, the relative posture of the laparoscope and the surgical instruments must be similar to the relative posture of the doctor's own eyes and hands, otherwise the movement direction of the instrument will deviate from the direction expected by the doctor or the movement speed of the instrument will be inconsistent with the speed set by the doctor, which will significantly increase the risk of surgery.
[0004] The calibration method for the relative position of the surgical robot's instrument and camera is called "hand-eye calibration". The traditional calibration method is generally to install a calibration plate at the end of the instrument, and then complete the calibration according to the established process. After the calibration is completed, the calibration plate is removed. The above calibration method needs to be completed when the robot leaves the factory, and then the calibration result is saved for use. However, as the robot is used for a long time, the mechanical structure will wear out, and for cable-driven surgical instruments, the cable will also deform. If the factory calibrated parameters are continued to be used, errors will occur in the "hand-eye" mapping. To solve the above problems, the manufacturer's technicians are currently required to regularly go to the hospital (or send the machine back to the manufacturer) to check whether the error of the "hand-eye" mapping is within an acceptable range. If it exceeds, manual recalibration is required. Considering that the equipment may be used nationwide or globally, this will greatly increase the maintenance cost. Summary of the invention
[0005] In view of this, a first aspect of an embodiment of the present disclosure provides an online hand-eye calibration method for a surgical robot, comprising: converting a first position of an instrument end in a robotic arm coordinate system to a camera coordinate system based on a first pose conversion matrix to obtain a second position; calculating a position error between the second position and a third position of the instrument end in the camera coordinate system calculated based on a binocular camera; in response to the position error being greater than an error threshold, determining a first trajectory of the instrument end in the camera coordinate system based on the third position at different times, and determining a second trajectory of the instrument end in the robotic arm coordinate system based on a time difference; wherein the time difference is the time difference between obtaining the same pose data of the instrument based on the binocular camera and based on the robotic arm motor system; and determining a second pose conversion matrix based on the first trajectory and the second trajectory.
[0006] According to an embodiment of the present disclosure, the method also includes: moving the end of the instrument to the field of view of the lens of the binocular camera; controlling the end of the instrument to move a specified distance through the robotic arm motor system; monitoring the position of the motor in the robotic arm motor system, and monitoring the end of the instrument based on the image captured by the binocular camera; in response to the position of the motor no longer changing, recording the first time of the robotic arm motor system; in response to the position of the instrument end in the image no longer changing, recording the second time of the image captured when the position no longer changes; calculating the difference between the first time and the second time to obtain the time difference.
[0007] According to an embodiment of the present disclosure, first trajectory data of the instrument end in the camera coordinate system is determined based on the third positions at different times, including: calculating the movement speed of the instrument end corresponding to the third positions at different times; eliminating the third positions corresponding to the movement speed greater than a preset threshold, and determining the first trajectory based on the remaining third positions.
[0008] According to an embodiment of the present disclosure, a second trajectory of the instrument end in the robot arm coordinate system is determined based on the time difference, including: calculating multiple moments corresponding to the first position in the robot arm coordinate system based on the time difference and different moments corresponding to the third position, and obtaining the first positions corresponding to the multiple moments; eliminating the first position at the moment corresponding to the eliminated third position from the multiple first positions, and determining the first trajectory based on the remaining first positions.
[0009] According to an embodiment of the present disclosure, the first trajectory data of the instrument end in the camera coordinate system is determined based on the third positions at different times, and also includes: calculating the distance between the third positions corresponding to any adjacent moments; in response to the distance being less than a preset distance, eliminating any third position corresponding to the adjacent moments, and determining the first trajectory based on the remaining third positions; determining the second trajectory of the instrument end in the robot arm coordinate system based on the time difference, and also includes: eliminating the first position at the moment corresponding to the eliminated third position among multiple first positions, and determining the first trajectory based on the remaining first positions.
[0010] According to an embodiment of the present disclosure, the method also includes: repeatedly calculating the position error between the second position and the third position of the instrument end in the camera coordinate system calculated based on the binocular camera to obtain multiple position errors; and averaging the multiple position errors as the final position error.
[0011] According to an embodiment of the present disclosure, the method further includes: in response to the position error being not greater than an error threshold, not updating the first pose transformation matrix.
[0012] A second aspect of an embodiment of the present disclosure provides an online hand-eye calibration device for a surgical robot, comprising: a conversion module, configured to convert a first position of an instrument end in a robotic arm coordinate system to a camera coordinate system based on a first pose conversion matrix to obtain a second position; a calculation module, configured to calculate a position error between the second position and a third position of the instrument end in the camera coordinate system calculated based on a binocular camera; a determination module, configured to determine a first trajectory of the instrument end in the camera coordinate system based on the third position at different times in response to a position error being greater than an error threshold, and determine a second trajectory of the instrument end in the robotic arm coordinate system based on a time difference; wherein the time difference is a time difference between obtaining the same pose data of the instrument based on the binocular camera and based on the robotic arm motor system; and a calibration module, configured to determine a second pose conversion matrix based on the first trajectory and the second trajectory.
[0013] A third aspect of an embodiment of the present disclosure provides an electronic device, comprising: one or more processors; and a memory for storing one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement an online hand-eye calibration method for a surgical robot.
[0014] A fourth aspect of an embodiment of the present disclosure provides a computer-readable storage medium having executable instructions stored thereon, which, when executed by a processor, enables the processor to implement an online hand-eye calibration method for a surgical robot. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] The above and other objects, features and advantages of the present disclosure will become more apparent through the following description of the embodiments of the present disclosure with reference to the accompanying drawings, in which:
[0016] Figure 1 The flowchart of the online hand-eye calibration method for a surgical robot according to an embodiment of the present disclosure is schematically shown.
[0017] Figure 2 The structure diagram of a surgical robot system according to an embodiment of the present disclosure is schematically shown.
[0018] Figure 3 The structural diagram of a robotic arm according to an embodiment of the present disclosure is schematically shown.
[0019] Figure 4 The structural block diagram of the online hand-eye calibration device for a surgical robot according to an embodiment of the present disclosure is schematically shown.
[0020] Figure 5 A block diagram of an electronic device suitable for an online hand-eye calibration method for a surgical robot according to an embodiment of the present disclosure is schematically shown. DETAILED DESCRIPTION
[0021] In order to make the purpose, technical solutions and advantages of the present disclosure more clearly understood, the present disclosure is further described in detail below in combination with specific embodiments and with reference to the accompanying drawings. Obviously, the described embodiments are part of the embodiments of the present disclosure, rather than all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in the field without creative work are within the scope of protection of the present disclosure.
[0022] The terms used herein are only for describing specific embodiments and are not intended to limit the present disclosure. The terms "comprise", "include", etc. used herein indicate the existence of the features, steps, operations and / or components, but do not exclude the existence or addition of one or more other features, steps, operations or components.
[0023] In the present disclosure, unless otherwise clearly specified and limited, the terms "installed", "connected", "connected", "fixed" and the like should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection, an electrical connection, or can communicate with each other; it can be a direct connection, or it can be indirectly connected through an intermediate medium, it can be the internal connection of two elements or the interaction relationship between two elements. For ordinary technicians in this field, the specific meanings of the above terms in the present disclosure can be understood according to specific circumstances.
[0024] In the description of the present disclosure, it is necessary to understand that the terms "longitudinal", "length", "circumferential", "front", "rear", "left", "right", "top", "bottom", "inside", "outside", etc., indicating the orientation or positional relationship, are based on the orientation or positional relationship shown in the accompanying drawings, and are only for the convenience of describing the present disclosure and simplifying the description, and do not indicate or imply that the subsystem or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as a limitation on the present disclosure.
[0025] Throughout the drawings, the same elements are represented by the same or similar reference numerals. Conventional structures or configurations will be omitted when they may cause confusion in the understanding of the present disclosure. The shapes, sizes, and positional relationships of the components in the drawings do not reflect the actual size, proportion, and actual positional relationship. In addition, in the claims, any reference symbol between brackets shall not be construed as a limitation to the claims.
[0026] Similarly, in order to simplify the present disclosure and help understand one or more of the various disclosed aspects, in the above description of the exemplary embodiments of the present disclosure, the various features of the present disclosure are sometimes grouped together into a single embodiment, figure, or description thereof. The description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" and the like means that the specific features, structures, materials, or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present disclosure. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.
[0027] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the feature. In the description of the present disclosure, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.
[0028] The online hand-eye calibration method for a surgical robot provided by an embodiment of the present disclosure will be explained in detail below with reference to specific drawings.
[0029] Figure 1 The flowchart of the online hand-eye calibration method for a surgical robot according to an embodiment of the present disclosure is schematically shown.
[0030] like Figure 1 As shown, the online hand-eye calibration method for a surgical robot may include, for example, operations S110 to S140.
[0031] In operation S110, a first position of the end of the instrument in the robot arm coordinate system is converted to the camera coordinate system based on the first pose conversion matrix to obtain a second position.
[0032] The first pose conversion matrix can be understood as the “hand-eye” pose conversion matrix T of the surgical robot when it leaves the factory or is previously calibrated.
[0033] In operation S120 , a position error between the second position and a third position of the instrument tip in the camera coordinate system calculated based on the binocular camera is calculated.
[0034] In operation S130 , in response to the position error being greater than the error threshold, a first trajectory of the instrument end in the camera coordinate system is determined based on the third position at different times, and a second trajectory of the instrument end in the robot arm coordinate system is determined based on the time difference.
[0035] The time difference is the time difference between obtaining the same posture data of the device based on the binocular camera and the robot arm motor system, that is, after the device moves to a certain posture, the time difference between obtaining the posture data through the visual image and obtaining the posture data through the robot arm motor system.
[0036] In operation S140 , a second pose conversion matrix is determined based on the first trajectory and the second trajectory.
[0037] After determining that the pose transformation matrix needs to be recalibrated, the second pose transformation matrix can be used to replace the first pose transformation matrix to update the hand-eye calibration result.
[0038] According to the online hand-eye calibration method for a surgical robot in an embodiment of the present disclosure, by realizing a real-time comparison between the robot arm posture data (the second position) and the image posture data (the third position), it is possible to adaptively determine whether recalibration is required during the user's use according to the error, without the need for manual judgment of whether recalibration is required. The timestamp alignment between the robot arm posture data and the image posture data is achieved through the time difference, and the online calibration can be automatically completed based on the aligned first trajectory and the second trajectory.
[0039] Based on the above embodiment, the method may further include: calculating the time difference between obtaining the same posture data of the device based on the binocular camera and based on the mechanical arm motor system.
[0040] Figure 2 The structure diagram of a surgical robot system according to an embodiment of the present disclosure is schematically shown.
[0041] like Figure 2 As shown, the surgical robot system drives the movement of the instrument through the motor controller, and calculates the position of the instrument based on the robot arm coordinate system through the motor position encoder. The binocular camera transmits image data to the computing server through the image processing host.
[0042] For the robot arm link, the connection between the device and the motor can be approximately considered as a rigid connection of the structure. The motor position data is transmitted to the computing server through the signal line. The amount of this data is relatively small, generally a maximum of dozens of bytes. Therefore, when the device position changes, the time difference for the computing server to receive this change data is generally less than 1ms.
[0043] For the image link, the laparoscope camera exposes and captures the current field of view at fixed intervals. The image processing host performs necessary processing on the image (such as ISP service) and then transmits it to the computing server through a signal line. However, since the image data is large (generally between several hundred KB and several MB), when the position of the instrument changes, the time difference for the computing server to receive this change data through the image link is generally tens of milliseconds to more than a hundred milliseconds.
[0044] Therefore, it is necessary to use some method to calculate the time difference between the same posture change data obtained by the robot link and the image link. That is, to perform timestamp alignment. Since the time difference between the two links is mainly related to the software program and the hardware that supports its operation, the software program and hardware will not change significantly during the life cycle of the robot, so it is only necessary to complete the timestamp alignment calibration once before the robot leaves the factory.
[0045] The process of calculating the time difference can be:
[0046] Move the tip of the instrument into the field of view of the binocular camera.
[0047] The end of the instrument is controlled to move a specified distance through the motor system of the robotic arm, and the motor can be driven to rotate through the program.
[0048] The robot data receiving module monitors the position of the motor in the robot motor system in real time and determines whether the motor position changes. When the motor position no longer changes, it indicates that the device has moved to the target position. In response to the motor position no longer changing, the first time t of the robot motor system is recorded. 1 .
[0049] Based on the binocular camera to collect images to monitor the end of the instrument, the image data receiving module receives the image data in real time and uses the image comparison algorithm to determine whether the instrument has moved (the lens always remains stationary). When the position of the instrument in the image no longer changes, it means that the instrument has moved to the target position. In response to the position of the end of the instrument in the image no longer changing, the second time t of the image that the position no longer changes is recorded. 2 .
[0050] Calculate the difference between the first time and the second time to get the time difference, that is, ΔT = t 2 -t 1 .
[0051] Since the data receiving interval of the robot link can be less than 1ms, that is, t 1 The error of the image link is less than 1ms. The error of the image link is related to the image frame rate. Taking 60 frames as an example (i.e. 60fps), the time interval between two frames of image is about 16.7m, so t 2 The maximum possible error for a single calibration is 16.7ms. Therefore, the single calibration result cannot be used as the final result. The ideal situation is that the camera is exposed and captured while the device stops moving. At this time, ΔT = t 2 -t 1 Therefore, the above time difference calculation process is repeated to calculate n groups (n>20) of ΔTi, and the minimum value is selected as the final result data, named ΔTime diff .
[0052] Figure 3 The structural diagram of a robotic arm according to an embodiment of the present disclosure is schematically shown.
[0053] like Figure 3 As shown, the camera and the surgical instrument are connected to the same mechanical arm (the camera and the instrument can also be on two mechanical arms respectively). The entire mechanical arm consists of three parts, namely the mechanical arm (including joints Jb1 and Jb2), the lens arm (including joint Jc) and the instrument arm (including joints Jt1 and Jt2). Figure 3 The "hand-eye" system in contains four coordinate systems, namely the camera coordinate system, the joint Jc coordinate system, the instrument end coordinate system, and the robot base coordinate system. There are three corresponding transformation matrices, namely: the transformation matrix from the instrument coordinate system to the robot base coordinate system, recorded as , the transformation matrix from the base coordinate system to the Jc coordinate system is recorded as , and the transformation matrix from the Jc coordinate system to the camera coordinate system, recorded as Therefore, the transformation matrix from the instrument coordinate system to the camera coordinate system is It can be calculated by the following formula:
[0054]
[0055] in, and All can be calculated from the mechanical structure and the corresponding joint motor data, so only calibration is required That is, its specific form is:
[0056]
[0057] Among them, rij is the rotation matrix part and ti is the translation vector part.
[0058] During the use of the surgical robot, the robotic arm data receiving module receives the position data of each motor of the robotic arm in real time and further calculates the instrument end position data P t_j , save the location data at different times in the list Pt_list, and save the system time Time when the corresponding location data is received t_j At the same time, the binocular image data is received in real time, the key points of the end of the instrument are detected using the pre-trained key point detection model, and then the binocular stereo matching algorithm is used to calculate the position P of the end of the instrument based on the camera coordinate system. C (x,y,z), assuming that the system time when the current frame image is received is Time c , then according to the calibration result ΔTime of the aforementioned timestamp alignment diffThe time of the robot arm coordinate system position data corresponding to the camera coordinate system position data of the current frame can be calculated:
[0059]
[0060] Get the location with the time from the previously saved location list t′ The first position P of the instrument in the robot arm coordinates corresponding to the timestamp closest in time t , and then apply the factory or previously calibrated "hand-eye" pose transformation matrix Convert the end position of the instrument in the robot coordinate system to the camera coordinate system to obtain the second position :
[0061]
[0062] in, and The latest calculation.
[0063] Calculate the second position and the third position P calculated based on binocular vision c Error ΔP:
[0064]
[0065] Furthermore, the method may also include: repeatedly calculating the position error between the second position and the third position of the instrument end in the camera coordinate system calculated based on the binocular camera, to obtain multiple position errors; averaging the multiple position errors as the final position error, and judging whether the final error is less than a preset threshold. If the error is less than a preset threshold, recalibration is not required, that is, the first pose transformation matrix does not need to be updated or replaced. Otherwise, recalibration is required to proceed to the next step.
[0066] On the basis of the above embodiment, the first trajectory data of the instrument end in the camera coordinate system is determined based on the third position at different times, including: calculating the movement speed of the instrument end corresponding to the third position at different times; eliminating the third position corresponding to the movement speed greater than the preset threshold, and determining the first trajectory based on the remaining third positions.
[0067] Determining a second trajectory of the end of the instrument in the robotic arm coordinate system based on the time difference includes: calculating multiple moments corresponding to the first position in the robotic arm coordinate system based on the time difference and different moments corresponding to the third position, obtaining the first positions corresponding to the multiple moments, eliminating the first position at the moment corresponding to the eliminated third position from the multiple first positions, and determining the first trajectory based on the remaining first positions.
[0068] Specifically, similar to determining whether recalibration is required, the image data is received in real time and the n groups of instrument end positions in the camera coordinate system are calculated to form the instrument motion trajectory, which is recorded as P c0 …P ci …P cn At the same time, the end position of the instrument based on the robot arm coordinate system is obtained by calculating the robot arm position according to the timestamp alignment calibration result, which is recorded as P t0 …P ti …P tn .
[0069] At the same time, since there is a certain error in the timestamp alignment calibration result, in order to reduce the impact of the timestamp alignment error on the calibration result, when selecting the instrument motion trajectory points, remove the trajectory points with faster instrument motion speed. The speed calculation method is:
[0070]
[0071] Among them, Δtime is the time interval for reporting the device motor data.
[0072] When v i When it is greater than the preset threshold, the corresponding trajectory point P is removed from the two trajectories. ci and P ti .
[0073] On the basis of the above embodiment, determining the first trajectory data of the instrument end in the camera coordinate system based on the third positions at different times further includes: calculating the distance between the third positions corresponding to any adjacent times. In response to the distance being less than the preset distance, any third position among the third positions corresponding to the adjacent times is eliminated, and the first trajectory is determined based on the remaining third positions.
[0074] Determining the second trajectory of the instrument end in the robot arm coordinate system based on the time difference also includes: eliminating the first position at the time corresponding to the eliminated third position among multiple first positions, and determining the first trajectory based on the remaining first positions.
[0075] Specifically, it is necessary to remove the points with too small displacement between the trajectory points to ensure that the entire trajectory has sufficient relative displacement. The relative displacement calculation formula between the points is:
[0076]
[0077] When ΔP ti When it is less than the preset threshold, the corresponding trajectory point P is removed from the two trajectories. ci and P ti .
[0078] After the above screening, we finally get two first trajectories P based on the camera coordinate system and the robot arm coordinate system respectively.c0 …P ci …P cm and the second trajectory P t0 …P ti …P tm Then the iterative closest point (ICP) algorithm is applied to align the two trajectories in the above two coordinate systems to obtain the second pose transformation matrix of the two trajectories. .
[0079] Furthermore, after obtaining the second posture conversion matrix, the end position data of the instrument in the new manipulator coordinate system can be obtained in real time and converted to the camera coordinate system, and then compared with the end position of the instrument in the camera coordinate system calculated based on the binocular camera at the corresponding moment, and the error between the two is calculated. If the consecutive n groups of errors are less than the preset threshold, the new calibration result is considered to be reliable, and the second posture conversion matrix is used to replace the first posture conversion matrix, that is:
[0080]
[0081] According to the online hand-eye calibration method for a surgical robot according to the embodiment of the present disclosure, it is possible to intelligently select trajectory points with higher reliability to automatically complete online calibration, thereby improving the intelligence and accuracy of the calibration.
[0082] Based on the above-mentioned surgical robot online hand-eye calibration method, the present disclosure also provides a surgical robot online hand-eye calibration device. Figure 4 The device is described in detail.
[0083] Figure 4 The structural block diagram of the online hand-eye calibration device for a surgical robot according to an embodiment of the present disclosure is schematically shown.
[0084] like Figure 4 As shown, the surgical robot online hand-eye calibration device 400 of this embodiment includes a conversion module 410 , a calculation module 420 , a determination module 430 and a calibration module 440 .
[0085] The conversion module 410 is configured to convert the first position of the instrument end in the manipulator coordinate system to the camera coordinate system based on the first pose conversion matrix to obtain a second position. In one embodiment, the conversion module 410 can be used to perform the operation S110 described above, which will not be repeated here.
[0086] The calculation module 420 is configured to calculate the position error between the second position and the third position of the instrument end in the camera coordinate system calculated based on the binocular camera. In one embodiment, the calculation module 420 can be used to perform the operation S120 described above, which will not be repeated here.
[0087] The determination module 430 is configured to determine the first trajectory of the instrument end in the camera coordinate system based on the third position at different times in response to the position error being greater than the error threshold, and determine the second trajectory of the instrument end in the robotic arm coordinate system based on the time difference. The time difference is the time difference between obtaining the same posture data of the instrument based on the binocular camera and the robotic arm motor system. In one embodiment, the determination module 430 can be used to perform the operation S130 described above, which will not be repeated here.
[0088] The calibration module 440 is configured to determine the second posture conversion matrix based on the first trajectory and the second trajectory. In one embodiment, the calibration module 440 can be used to perform the operation S140 described above, which will not be described in detail here.
[0089] According to an embodiment of the present disclosure, any multiple modules of the conversion module 410, the calculation module 420, the determination module 430 and the calibration module 440 can be combined into one module for implementation, or any one of the modules can be split into multiple modules. Alternatively, at least part of the functions of one or more of these modules can be combined with at least part of the functions of other modules and implemented in one module. According to an embodiment of the present disclosure, at least one of the conversion module 410, the calculation module 420, the determination module 430 and the calibration module 440 can be at least partially implemented as a hardware circuit, such as a field programmable gate array (FPGA), a programmable logic array (PLA), a system on a chip, a system on a substrate, a system on a package, an application specific integrated circuit (ASIC), or can be implemented by hardware or firmware such as any other reasonable way of integrating or packaging the circuit, or implemented in any one of the three implementation methods of software, hardware and firmware or in a suitable combination of any of them. Alternatively, at least one of the conversion module 410 , the calculation module 420 , the determination module 430 , and the calibration module 440 may be at least partially implemented as a computer program module, and when the computer program module is executed, a corresponding function may be performed.
[0090] Figure 5 A block diagram of an electronic device suitable for an online hand-eye calibration method for a surgical robot according to an embodiment of the present disclosure is schematically shown.
[0091] like Figure 5As shown, the electronic device 500 according to an embodiment of the present disclosure includes a processor 501, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 502 or a program loaded from a storage part 508 to a random access memory (RAM) 503. The processor 501 may include, for example, a general-purpose microprocessor (such as a CPU), an instruction set processor and / or a related chipset and / or a special-purpose microprocessor (for example, an application-specific integrated circuit (ASIC)), etc. The processor 501 may also include an onboard memory for caching purposes. The processor 501 may include a single processing unit or multiple processing units for performing different actions of the method flow according to an embodiment of the present disclosure.
[0092] In RAM 503, various programs and data required for the operation of electronic device 500 are stored. Processor 501, ROM 502 and RAM 503 are connected to each other via bus 504. Processor 501 performs various operations of the method flow according to the embodiment of the present disclosure by executing the program in ROM 502 and / or RAM 503. It should be noted that the program can also be stored in one or more memories other than ROM 502 and RAM 503. Processor 501 can also perform various operations of the method flow according to the embodiment of the present disclosure by executing the program stored in the one or more memories.
[0093] According to an embodiment of the present disclosure, the electronic device 500 may further include an input / output (I / O) interface 505, which is also connected to the bus 504. The electronic device 500 may further include one or more of the following components connected to the I / O interface 505: an input portion 506 including a keyboard, a mouse, etc.; an output portion 507 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage portion 508 including a hard disk, etc.; and a communication portion 509 including a network interface card such as a LAN card, a modem, etc. The communication portion 509 performs communication processing via a network such as the Internet. A drive 510 is also connected to the I / O interface 505 as needed. A removable medium 511, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 510 as needed, so that a computer program read therefrom is installed into the storage portion 508 as needed.
[0094] The present disclosure also provides a computer-readable storage medium, which may be included in the device / apparatus / system described in the above embodiments; or may exist independently without being assembled into the device / apparatus / system. The above computer-readable storage medium carries one or more programs, and when the above one or more programs are executed, the method according to the embodiment of the present disclosure is implemented.
[0095] According to an embodiment of the present disclosure, the computer-readable storage medium may be a non-volatile computer-readable storage medium, for example, it may include but is not limited to: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program, which may be used by or in combination with an instruction execution system, an apparatus or a device. For example, according to an embodiment of the present disclosure, the computer-readable storage medium may include the ROM 502 and / or RAM 503 described above and / or one or more memories other than ROM 502 and RAM 503.
[0096] The embodiment of the present disclosure also includes a computer program product, which includes a computer program, and the computer program contains program code for executing the method shown in the flowchart. When the computer program product is run in a computer system, the program code is used to enable the computer system to implement the method provided by the embodiment of the present disclosure.
[0097] The above functions defined in the system / device of the embodiment of the present disclosure are performed when the computer program is executed by the processor 501. According to the embodiment of the present disclosure, the system, device, module, unit, etc. described above can be implemented by a computer program module.
[0098] In one embodiment, the computer program may rely on tangible storage media such as optical storage devices, magnetic storage devices, etc. In another embodiment, the computer program may also be transmitted and distributed in the form of signals on a network medium, and downloaded and installed through the communication part 509, and / or installed from the removable medium 511. The program code contained in the computer program may be transmitted using any appropriate network medium, including but not limited to: wireless, wired, etc., or any suitable combination of the above.
[0099] In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 509, and / or installed from the removable medium 511. When the computer program is executed by the processor 501, the above functions defined in the system of the embodiment of the present disclosure are performed. According to the embodiment of the present disclosure, the system, device, means, module, unit, etc. described above can be implemented by a computer program module.
[0100] According to an embodiment of the present disclosure, the program code for executing the computer program provided by the embodiment of the present disclosure can be written in any combination of one or more programming languages. Specifically, these computing programs can be implemented using high-level process and / or object-oriented programming languages, and / or assembly / machine languages. Programming languages include, but are not limited to, Java, C++, python, "C" language or similar programming languages. The program code can be executed entirely on the user computing device, partially on the user device, partially on the remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device can be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computing device (for example, using an Internet service provider to connect through the Internet).
[0101] The flow charts and block diagrams in the accompanying drawings illustrate the possible architecture, functions and operations of the systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each box in the flow chart or block diagram can represent a module, a program segment, or a part of a code, and the above-mentioned module, program segment, or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0102] It will be appreciated by those skilled in the art that the features described in the various embodiments of the present disclosure may be combined and / or combined in a variety of ways, even if such combinations and / or combinations are not explicitly described in the present disclosure. In particular, without departing from the spirit and teachings of the present disclosure, the features described in the various embodiments of the present disclosure may be combined and / or combined in a variety of ways. All of these combinations and / or combinations fall within the scope of the present disclosure.
[0103] The embodiments of the present disclosure are described above. However, these embodiments are only for illustrative purposes and are not intended to limit the scope of the present disclosure. Although the embodiments are described above, this does not mean that the measures in the various embodiments cannot be used in combination to advantage. Without departing from the scope of the present disclosure, those skilled in the art may make a variety of substitutions and modifications, which should all fall within the scope of the present disclosure.
Claims
1. A surgical robot online hand-eye calibration method, characterized in that: include: Based on the first pose conversion matrix, a first position of the end of the instrument in the robot arm coordinate system is converted to the camera coordinate system to obtain a second position; Calculating a position error between the second position and a third position of the instrument end in the camera coordinate system calculated based on the binocular camera; In response to the position error being greater than an error threshold, a first trajectory of the instrument end in the camera coordinate system is determined based on the third position at different times, and a second trajectory of the instrument end in the robotic arm coordinate system is determined based on the time difference; wherein the time difference is the time difference between obtaining the same posture data of the instrument based on the binocular camera and the robotic arm motor system; A second pose transformation matrix is determined based on the first trajectory and the second trajectory.
2. The online hand-eye calibration method for a surgical robot according to claim 1, characterized in that: The method further comprises: Moving the end of the instrument to the field of view of the binocular camera; Controlling the end of the instrument to move a specified distance through a robotic arm motor system; Monitoring the position of the motor in the motor system of the robotic arm, and monitoring the end of the instrument based on the image captured by the binocular camera; In response to the position of the motor no longer changing, recording a first time of the motor system of the robotic arm; In response to the position of the instrument tip in the image no longer changing, recording a second time at which the image at which the position no longer changes is acquired; The difference between the first time and the second time is calculated to obtain the time difference.
3. The online hand-eye calibration method for a surgical robot according to claim 1, characterized in that: The first trajectory data of the end of the instrument in the camera coordinate system is determined based on the third position at different times, including: Calculating the movement speed of the end of the instrument corresponding to the third position at different times; The third positions corresponding to the movement speeds greater than a preset threshold are eliminated, and the first trajectory is determined based on the remaining third positions.
4. The method for online hand-eye calibration of a surgical robot according to claim 3, characterized in that: Determining a second trajectory of the end of the instrument in the robot arm coordinate system based on the time difference includes: Calculate multiple moments corresponding to the first position in the robot arm coordinate system based on the time difference and different moments corresponding to the third position, and obtain the first position corresponding to the multiple moments; The first position at the time corresponding to the eliminated third position is eliminated from the plurality of first positions, and the first trajectory is determined based on the remaining first positions.
5. The method for online hand-eye calibration of a surgical robot according to claim 4, characterized in that: The first trajectory data of the end of the instrument in the camera coordinate system is determined based on the third position at different times, and further includes: Calculate the distance between the third positions corresponding to any adjacent moments; In response to the distance being less than a preset distance, any third position corresponding to the third positions at adjacent moments is eliminated, and the first trajectory is determined based on the remaining third positions; The method of determining a second trajectory of the instrument end in the robot arm coordinate system based on the time difference also includes: The first position at the time corresponding to the eliminated third position is eliminated from the plurality of first positions, and the first trajectory is determined based on the remaining first positions.
6. The method for online hand-eye calibration of a surgical robot according to claim 1, characterized in that: The method further comprises: Repeatedly calculating a position error between the second position and a third position of the end of the instrument in the camera coordinate system calculated based on the binocular camera to obtain multiple position errors; An average value is calculated for the multiple position errors to obtain a final position error.
7. The method for online hand-eye calibration of a surgical robot according to claim 1, characterized in that: The method further comprises: In response to the position error being not greater than the error threshold, the first posture transformation matrix is not updated.
8. An online hand-eye calibration device for a surgical robot, characterized in that: include: A conversion module is configured to convert a first position of the end of the instrument in the robot arm coordinate system to the camera coordinate system based on the first posture conversion matrix to obtain a second position; A calculation module, configured to calculate a position error between the second position and a third position of the instrument end in a camera coordinate system calculated based on the binocular camera; A determination module is configured to, in response to the position error being greater than an error threshold, determine a first trajectory of the instrument end in the camera coordinate system based on third positions at different times, and determine a second trajectory of the instrument end in the robotic arm coordinate system based on a time difference; wherein the time difference is a time difference between obtaining the same posture data of the instrument based on the binocular camera and the robotic arm motor system; A calibration module is configured to determine a second posture transformation matrix based on the first trajectory and the second trajectory.
9. An electronic device, comprising: one or more processors; a memory for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 7.
10. A computer-readable storage medium having executable instructions stored thereon, which, when executed by a processor, enables the processor to implement the method according to any one of claims 1 to 7.
Citation Information
Cited By
CT scanning system mechanical arm control method, device, equipment and medium
CN119279618A
