Three-dimensional reconstruction method, device, equipment and storage medium for ultrasonic images of blood vessels

By collecting vascular ultrasound images in real time and combining the spatial position information of electromagnetic sensors, using the U2-Net model and TensorRT framework to accelerate inference, the problems of low accuracy and slow speed of vascular ultrasound images in the prior art are solved, and efficient 3D reconstruction effect is achieved.

CN120032064BActive Publication Date: 2025-07-08HUAXI JINGCHUANG MEDICAL TECH (CHENGDU) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510503258.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-04-22
Publication Date
2025-07-08
Estimated Expiration
2045-04-22

AI Technical Summary

Technical Problem

The three-dimensional reconstruction methods of existing ultrasound images of blood vessels have problems of low accuracy and slow speed, especially in dynamically changing blood vessel structures, and traditional methods are difficult to meet the requirements of real-time processing.

Method used

By collecting ultrasound images of blood vessels in real time, segmenting them using the U2-Net model, and obtaining spatial pose information of the ultrasound probe with electromagnetic sensors, accelerating inference using TensorRT framework, combining geometric transformation algorithms to convert the image coordinate system, and finally real-time rendering in the world coordinate system to achieve efficient three-dimensional reconstruction.

Benefits of technology

It significantly improves the three-dimensional reconstruction accuracy and speed of vascular ultrasound images, meets the requirements of real-time processing, and improves the real-time and calculation accuracy of the image segmentation process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120032064B_ABST
    Figure CN120032064B_ABST
Patent Text Reader

Abstract

The present invention discloses a three-dimensional reconstruction method, device, equipment and storage medium for ultrasonic images of blood vessels, which relates to the technical field of image processing and includes: real-time collecting ultrasonic images of blood vessels; obtaining spatial pose information of an ultrasonic probe; segmenting the ultrasonic images based on the U2-Net model to extract ultrasonic blood vessel images; calculating a conversion matrix from the ultrasonic image coordinate system to the electromagnetic sensor space, a conversion matrix from the electromagnetic sensor space to the magnetic field space, and a conversion matrix from the magnetic field space to the world coordinate system according to the coordinates of calibration key points in the ultrasonic image coordinate system, the electromagnetic positioning coordinate system, and the world coordinate system respectively and the spatial pose information; converting each pixel point of the blood vessel in the ultrasonic image into a navigation coordinate system based on a geometric transformation algorithm to obtain a converted image; and performing real-time rendering on the obtained multiple frames of converted images in the world coordinate system. The present invention improves the three-dimensional reconstruction accuracy and speed of ultrasonic images of blood vessels.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of ultrasonic image processing, and particularly relates to a three-dimensional reconstruction method, device, equipment and storage medium for ultrasonic images of blood vessels. Background Art

[0002] In recent years, due to the non-invasive, real-time and convenient characteristics, ultrasonic imaging has been widely used in cardiovascular interventional surgeries, especially in surgeries such as intravascular stent implantation and cardiac catheter intervention. The real-time and high-frequency acquisition requirements of ultrasonic images call for efficient image processing and analysis techniques to assist doctors in making accurate decisions. However, traditional three-dimensional reconstruction methods for ultrasonic images of blood vessels face multiple challenges: First, ultrasonic images are greatly affected by noise and have low segmentation accuracy, especially in dynamically changing blood vessel structures, resulting in low three-dimensional reconstruction accuracy. Second, the real-time processing of ultrasonic images requires fast spatial reconstruction, but traditional methods rely on CPU computing, which is slow and difficult to meet the real-time requirements.

[0003] Therefore, the applicant of the present invention has developed a three-dimensional reconstruction method, device, equipment and storage medium for ultrasonic images of blood vessels to solve the above problems. Summary of the Invention

[0004] The present invention provides a three-dimensional reconstruction method, device, equipment and storage medium for ultrasonic images of blood vessels to solve the problems of low accuracy and slow speed of existing three-dimensional reconstruction methods for ultrasonic images of blood vessels.

[0005] The present invention achieves the above object through the following technical solutions:

[0006] In a first aspect, the present invention provides a three-dimensional reconstruction method for ultrasonic images of blood vessels, including:

[0007] Real-time collecting ultrasonic images of blood vessels;

[0008] Obtaining the spatial pose information of the ultrasonic probe through an electromagnetic sensor, where the spatial pose information includes the position and rotation quaternion of the ultrasonic probe in space;

[0009] Based on the U2-Net model, segmenting the ultrasonic image to extract the ultrasonic blood vessel image, and accelerating the inference of the U2-Net model through the TensorRT framework during the segmentation process;

[0010] Calculating the transformation matrix from the ultrasonic image coordinate system to the electromagnetic sensor space, the transformation matrix from the electromagnetic sensor space to the magnetic field space, and the transformation matrix from the magnetic field space to the world coordinate system according to the coordinates of the calibration key points in the ultrasonic image coordinate system, the electromagnetic positioning coordinate system, and the world coordinate system respectively, and the spatial pose information, where the calibration key points are the key points calibrated in the ultrasonic image according to the ultrasonic calibration algorithm;

[0011] Based on the conversion matrix from the ultrasonic image coordinate system to the electromagnetic sensor space, the conversion matrix from the electromagnetic sensor space to the magnetic field space, and the conversion matrix from the magnetic field space to the world coordinate system, each pixel point of the blood vessel in the ultrasonic image is converted into the navigation coordinate system based on the geometric transformation algorithm to obtain a converted image;

[0012] In the world coordinate system, real-time rendering is performed on the obtained multiple frames of the converted images to obtain a real-time three-dimensional reconstruction result.

[0013] Furthermore, during the segmentation process, the U2-Net model is accelerated for inference through the TensorRT framework, including:

[0014] Convert the pth model trained by the U2-Net model into an onnx model, and the formula is as follows:

[0015] ;

[0016] represents the PyTorch computational graph, which is a directed computational graph, where V is the node in the computational graph, E is the edge in the computational graph, W is the weight tensor, M represents the dynamic computational symbol mapping, O represents the computational graph optimization process, and the computational graph optimization process includes operator fusion, computational graph pruning, and computational flow rearrangement. represents the conversion function for converting the PyTorch model into an ONNX model. represents the input ONNX computational graph;

[0017] Convert the onnx model into a trt model, and the formula is as follows:

[0018] ;

[0019] Among them, represents the trt model. represents the ONNX model weight, O represents the computational graph optimization process, F represents operator fusion, S represents the scaling factor, C represents the compiler mapping function, and the calculation method of the scaling factor S is:

[0020] ;

[0021] Among them, b = n, indicating weight quantization. Quantize the ONNX model weight FPn quantization is performed, where FPn represents the model accuracy, and n can take 8, 16, or 32.

[0022] Further, based on the coordinates of the calibration key points in the ultrasonic image coordinate system, the electromagnetic positioning coordinate system, and the world coordinate system, respectively, and the spatial pose information, calculate the transformation matrix from the ultrasonic image coordinate system to the electromagnetic sensor space, the transformation matrix from the electromagnetic sensor space to the magnetic field space, and the transformation matrix from the magnetic field space to the world coordinate system, including:

[0023] ;

[0024] ;

[0025] ;

[0026] ;

[0027]

[0028] N is the number of calibration key points determined in the ultrasonic coordinate system and the electromagnetic positioning coordinate system obtained by calibration, where one calibration key point , is the coordinate of this key point in the ultrasonic image coordinate system, is the coordinate of this key point in the electromagnetic positioning coordinate system, is the coordinate of this key point in the world coordinate system, TM represents the matrix required for the left end of the minimization formula, is the transformation matrix from the ultrasonic image coordinate system to the electromagnetic sensor space, is the transformation matrix from the electromagnetic sensor space to the magnetic field space, is the transformation matrix from the magnetic field space to the world coordinate system, is the rotation quaternion, T represents the translation, that is, the position of the ultrasonic probe in space, t x , t y , t z respectively represent the position coordinates of the probe on the three coordinate axes, and R represents the rotation matrix.

[0029] Further, based on the transformation matrix from the ultrasonic image coordinate system to the electromagnetic sensor space, the transformation matrix from the electromagnetic sensor space to the magnetic field space, and the transformation matrix from the magnetic field space to the world coordinate system, transform each pixel point of the blood vessel in the ultrasonic image into the navigation coordinate system based on the geometric transformation algorithm to obtain a transformed image, including:

[0030] ;

[0031] Among them, is the coordinate of the pixel point in the transformed image, (x, y) is the coordinate of the pixel point of the blood vessel in the ultrasonic image coordinate system, S x , S yThey are the scaling factors of the x-axis and y-axis in the ultrasonic image coordinate system respectively.

[0032] In a second aspect, the present invention also provides a three-dimensional reconstruction device for ultrasonic images of blood vessels, including:

[0033] An acquisition module, which is used to acquire ultrasonic images of blood vessels in real time;

[0034] An acquisition module, which is used to obtain the spatial pose information of the ultrasonic probe through an electromagnetic sensor, and the spatial pose information includes the position and rotation quaternion of the ultrasonic probe in space;

[0035] A segmentation module, which is used to segment the ultrasonic image based on the U2-Net model to extract the ultrasonic blood vessel image, and accelerate the inference of the U2-Net model through the TensorRT framework during the segmentation process;

[0036] A calculation module, which is used to calculate the ultrasonic-to-magnetic field space conversion matrix and the magnetic field-to-ultrasonic field space conversion matrix according to the spatial pose information through a calibration model and an algorithm based on feature points;

[0037] A conversion module, which is used to convert each pixel point in the ultrasonic blood vessel image to the navigation coordinate system based on the ultrasonic-to-magnetic field space conversion matrix and the magnetic field-to-ultrasonic field space conversion matrix according to a geometric transformation algorithm to obtain a converted image;

[0038] A rendering module, which is used to perform real-time rendering on the converted multiple frames of images in the world coordinate system to obtain a real-time three-dimensional reconstruction result.

[0039] In a third aspect, the present invention also provides a three-dimensional reconstruction device for ultrasonic images of blood vessels, including:

[0040] A memory, which is used to store a computer program;

[0041] A processor, which is used to implement the steps of the three-dimensional reconstruction method for ultrasonic images of blood vessels as described when executing the computer program.

[0042] The present invention also discloses a storage medium, which is a readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, the steps of the three-dimensional reconstruction method for ultrasonic images of blood vessels are implemented.

[0043] The beneficial effects of the present invention are as follows:

[0044] The three-dimensional reconstruction method of ultrasonic images of blood vessels proposed by the present invention solves the problems of low accuracy and slow speed in the existing three-dimensional reconstruction methods of ultrasonic images of blood vessels. The present invention collects ultrasonic images of blood vessels in real time, accelerates the inference of the U2-Net model, and significantly improves the real-time performance and calculation accuracy in the ultrasonic image segmentation process by using its highly parallel computing characteristics. Subsequently, the precise spatial pose information of the ultrasonic probe is obtained by combining an electromagnetic sensor, and the local coordinate system of the ultrasonic image is accurately docked with the global navigation system coordinate system through a geometric transformation algorithm, improving the three-dimensional reconstruction accuracy and speed of the ultrasonic images of blood vessels. BRIEF DESCRIPTION OF THE DRAWINGS

[0045] Figure 1 It is a flowchart of a three-dimensional reconstruction method of ultrasonic images of blood vessels according to the present application. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0046] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Apparently, the described embodiments are some, but not all, of the embodiments of the present invention. Components of the embodiments of the present invention described and illustrated herein generally may be arranged and designed in a variety of different configurations.

[0047] Therefore, the following detailed description of the embodiments of the present invention provided in the accompanying drawings is not intended to limit the scope of the claimed invention, but merely represents selected embodiments of the present invention. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts fall within the scope of protection of the present invention.

[0048] It should be noted that like reference numerals and letters denote like items in the following drawings, and thus, once an item is defined in one drawing, it need not be further defined and explained in subsequent drawings.

[0049] The following will describe the specific embodiments of the present invention in detail with reference to the accompanying drawings.

[0050] As Figure 1 shown, a three-dimensional reconstruction method of ultrasonic images of blood vessels according to the present invention includes:

[0051] S1: Collect ultrasonic images of blood vessels in real time;

[0052] The ultrasonic images of blood vessels are collected in real time through a video capture card. The two-dimensional ultrasonic image collected by a sensor (such as an ultrasonic probe) can be expressed as I(x, y, t), where (x, y) are the spatial coordinates of the image and t is the time dimension. Specifically, at each moment t, the capture card acquires the ultrasonic image from the sensor and converts it into digital image data through signal processing.

[0053] S2: Obtain the spatial pose information of the ultrasonic probe through an electromagnetic sensor, where the spatial pose information includes the position and rotation quaternion of the ultrasonic probe in space;

[0054] Combined with the electromagnetic sensor to obtain the accurate spatial pose information of the ultrasonic probe, the electromagnetic sensor provides the position and rotation quaternion of the ultrasonic probe, where , T represents translation (i.e., the position of the ultrasonic probe in space), is a quaternion used to describe rotation.

[0055] S3: Segment the ultrasonic image based on the U2-Net model to extract the ultrasonic blood vessel image, and accelerate the inference of the U2-Net model through the TensorRT framework during the segmentation process;

[0056] Using the U2-Net model to segment the collected ultrasonic image can accurately extract the blood vessel structure. At the same time, the TensorRT framework is used to accelerate the inference of the U2-Net model, and its highly parallel computing characteristics are utilized to significantly improve the real-time performance and computing accuracy during the ultrasonic image segmentation process. Specific optimizations for the complex segmentation task of the U2-Net model are carried out through the TensorRT framework, including adaptive operator fusion, weight quantization, cache optimization, and CUDA C preprocessing to reduce the CPU-GPU data copy overhead, improve the inference throughput, make the inference more efficient, and reduce the video memory occupancy.

[0057] Specifically, S3 includes:

[0058] First, convert the pth model trained by the U2-Net model into an onnx model, and the formula is as follows:

[0059] ;

[0060] represents the PyTorch computation graph, which is a directed computation graph, where V are the nodes in the computation graph, E are the edges in the computation graph, W is the weight tensor, M represents the dynamic computation symbol mapping, and O represents the computation graph optimization process. The computation graph optimization process includes operator fusion, computation graph pruning, and computation flow rearrangement. A conversion function that converts a PyTorch model to an ONNX model, thereby ensuring computational logic consistency. During the conversion process, O is responsible for computational graph optimization, including operator fusion, which combines multiple mergeable operators into one efficient operator; computational graph pruning, which reduces redundant computations by removing invalid computational nodes; and computational flow rearrangement, which optimizes the execution order of the computational graph to improve inference efficiency and resource utilization.

[0061] Then convert the onnx model to a trt model , the formula is as follows:

[0062] ;

[0063] Among them, represents the input ONNX computational graph, which consists of multiple computational nodes (operators). After being processed by the computational graph optimization O, including optimization strategies such as computational flow rearrangement, operator fusion, and computational graph pruning, to improve inference efficiency. The optimized computational graph undergoes operator fusion F, which combines multiple independent operators into a more efficient operator, further reducing the computational overhead. Subsequently, weight quantization performs FP16 quantization on the ONNX model weights , and the scaling factor S is calculated as follows:

[0064] ;

[0065] Among them, b = 16 (for FP16 quantization). The quantized computational graph passes through the compiler mapping function C, which converts the optimized ONNX computational graph into an efficient TensorRT computational engine, and finally generates , that is, the TensorRT engine for efficient inference. This process combines computational optimization, weight quantization, and hardware acceleration, enabling the model to have faster inference speed, lower video memory occupancy, and better energy consumption efficiency when running on NVIDIA GPUs.

[0066] S4: According to the coordinates of the calibration key points in the ultrasonic image coordinate system, electromagnetic positioning coordinate system, and world coordinate system respectively, and the spatial pose information, calculate the transformation matrix from the ultrasonic image coordinate system to the electromagnetic sensor space, the transformation matrix from the electromagnetic sensor space to the magnetic field space, and the transformation matrix from the magnetic field space to the world coordinate system. The calibration key points are the key points calibrated in the ultrasonic image according to the ultrasonic calibration algorithm, including:

[0067] ;

[0068] ;

[0069] ;

[0070] ;

[0071] ;

[0072] N is the number of calibration key points determined in the ultrasonic coordinate system and the electromagnetic positioning coordinate system obtained by calibration, where one calibration key point , is the coordinate of this key point in the ultrasonic image coordinate system, is the coordinate of this key point in the electromagnetic positioning coordinate system, is the coordinate of this key point in the world coordinate system, TM represents the matrix obtained by minimizing the left end of the equation, is the conversion matrix from the ultrasonic image coordinate system to the electromagnetic sensor space, is the conversion matrix from the electromagnetic sensor space to the magnetic field space, is the conversion matrix from the magnetic field space to the world coordinate system, is the said rotation quaternion, T represents translation, i.e., the position of the ultrasonic probe in space, t x 、t y 、t z respectively represent the position coordinates of the probe on the three coordinate axes, R represents the rotation matrix;

[0073] The ultrasonic calibration algorithm can adopt one of the single-point (line) method, two-dimensional plane alignment method, and Freehand method. For example, adopting the Freehand method uses a model with several thin lines that can be imaged in the ultrasonic and are parallel to each other to implement the calibration of the ultrasonic probe. This method makes the image scanning plane of the ultrasonic probe intersect with these parallel lines. The model can be an open cuboid composed of five plexiglass plates. The model contains several copper wires, and both ends of each copper wire are fixed in the corresponding holes on the front wall and the rear wall of the model. All copper wires form multiple N-shaped structures. Ultrasonic scanning will form 3 bright spots, and the middle bright spot is the key point.

[0074] S5: According to the conversion matrix from the ultrasonic image coordinate system to the electromagnetic sensor space, the conversion matrix from the electromagnetic sensor space to the magnetic field space, and the conversion matrix from the magnetic field space to the world coordinate system, based on the geometric transformation algorithm, convert each pixel point of the blood vessel in the ultrasonic image to the navigation coordinate system to obtain a converted image, including:

[0075] ;

[0076] Among them, is the coordinate of the pixel point in the converted image, (x, y) is the coordinate of the pixel point of the blood vessel in the ultrasonic image coordinate system, S x 、S y are the scaling factors of the x-axis and y-axis in the ultrasonic image coordinate system respectively.

[0077] S6: Render the obtained multiple frames of transformed images in the world coordinate system to obtain a real-time three-dimensional reconstruction result. Thus, the spatial mapping between the ultrasound data and the navigation system is realized, and the optimized volume rendering of the ultrasound slices is performed in the world coordinate system, thereby realizing the rapid three-dimensional reconstruction of two-dimensional ultrasound.

[0078] The embodiment of the present invention also provides a three-dimensional reconstruction device for ultrasound images of blood vessels, including:

[0079] An acquisition module, which is used to acquire ultrasound images of blood vessels in real time;

[0080] An acquisition module, which is used to obtain the spatial pose information of the ultrasound probe through an electromagnetic sensor, and the spatial pose information includes the position and rotation quaternion of the ultrasound probe in space;

[0081] A segmentation module, which is used to segment the ultrasound image based on the U2-Net model to extract the ultrasound blood vessel image, and accelerate the inference of the U2-Net model through the TensorRT framework during the segmentation process;

[0082] A calculation module, which is used to calculate the ultrasound-to-magnetic field space conversion matrix and the magnetic field-to-ultrasound space conversion matrix according to the spatial pose information through a calibration model and an algorithm based on feature points;

[0083] A conversion module, which is used to convert each pixel point in the ultrasound blood vessel image to the navigation coordinate system based on the geometric transformation algorithm according to the ultrasound-to-magnetic field space conversion matrix and the magnetic field-to-ultrasound space conversion matrix to obtain a transformed image;

[0084] A rendering module, which renders the multiple frames of images obtained by conversion in the world coordinate system to obtain a real-time three-dimensional reconstruction result.

[0085] The embodiment of the present invention also provides a three-dimensional reconstruction device for ultrasound images of blood vessels, including:

[0086] A memory for storing computer programs;

[0087] A processor, which is used to implement the steps of the three-dimensional reconstruction method for ultrasound images of blood vessels as described when executing the computer program.

[0088] The embodiment of the present invention also provides a storage medium, which is a readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, the steps of the three-dimensional reconstruction method for ultrasound images of blood vessels as described are implemented.

[0089] A three-dimensional reconstruction method for ultrasonic images of blood vessels proposed by the present invention solves the problems of low accuracy and slow speed in the existing three-dimensional reconstruction methods for ultrasonic images of blood vessels. By collecting ultrasonic images of blood vessels in real time and accelerating the inference of the U2-Net model, the real-time performance and computational accuracy in the ultrasonic image segmentation process are significantly improved by using its highly parallel computing characteristics. Subsequently, the precise spatial pose information of the ultrasonic probe is obtained by combining an electromagnetic sensor, and the local coordinate system of the ultrasonic image is accurately docked with the global navigation system coordinate system through a geometric transformation algorithm, improving the three-dimensional reconstruction accuracy and speed of the ultrasonic image of the blood vessel.

[0090] The above are only the preferred embodiments of the present invention. It should be noted that for those of ordinary skill in the art, without departing from the technical principle of the present invention, several improvements and refinements can be made, and these improvements and refinements should also be regarded as the protection scope of the present invention.

Claims

1. A three-dimensional reconstruction method for ultrasonic images of blood vessels, characterized in that, Including: Real-time acquisition of ultrasonic images of blood vessels; Obtaining the spatial pose information of the ultrasonic probe through an electromagnetic sensor, where the spatial pose information includes the position and rotation quaternion of the ultrasonic probe in space; Segmenting the ultrasonic image based on the U2-Net model to extract the ultrasonic blood vessel image, and accelerating the inference of the U2-Net model through the TensorRT framework during the segmentation process; Calculating the transformation matrix from the ultrasonic image coordinate system to the electromagnetic sensor space, the transformation matrix from the electromagnetic sensor space to the magnetic field space, and the transformation matrix from the magnetic field space to the world coordinate system according to the coordinates of the calibration key points in the ultrasonic image coordinate system, electromagnetic positioning coordinate system, and world coordinate system respectively, and the spatial pose information, where the calibration key points are the key points calibrated in the ultrasonic image according to the ultrasonic calibration algorithm; Based on the transformation matrix from the ultrasonic image coordinate system to the electromagnetic sensor space, the transformation matrix from the electromagnetic sensor space to the magnetic field space, and the transformation matrix from the magnetic field space to the world coordinate system, transforming each pixel point of the blood vessel in the ultrasonic image into the navigation coordinate system through a geometric transformation algorithm to obtain a transformed image, where the navigation coordinate system is the world coordinate system; Performing real-time rendering on the obtained multiple frames of the transformed images in the world coordinate system to obtain a real-time three-dimensional reconstruction result; Among them, ; ; ; ; ; N is the number of calibration key points determined in the ultrasonic coordinate system and the electromagnetic positioning coordinate system obtained by calibration, where one calibration key point , is the coordinate of the key point in the ultrasonic image coordinate system, is the coordinate of the key point in the electromagnetic positioning coordinate system, is the coordinate of the key point in the world coordinate system, TM represents the matrix obtained by minimizing the left end of the equation, is the transformation matrix from the ultrasonic image coordinate system to the electromagnetic sensor space, is the transformation matrix from the electromagnetic sensor space to the magnetic field space, is the transformation matrix from the magnetic field space to the world coordinate system, is the rotation quaternion, T represents the translation, that is, the position of the ultrasonic probe in space, t x , t y , t z respectively represent the position coordinates of the probe on the three coordinate axes, and R represents the rotation matrix; ; Among them, is to convert the coordinates of pixel points in the image, (x, y) are the coordinates of the pixel points of the blood vessel in the coordinate system of the ultrasonic image, and S x , S y are respectively the scaling factors of the x-axis and y-axis in the coordinate system of the ultrasonic image.

2. The three-dimensional reconstruction method of the ultrasonic image of a blood vessel according to claim 1, wherein, Accelerating the inference of the U2-Net model through the TensorRT framework during the segmentation process, including: Converting the pth model trained by the U2-Net model into an onnx model, with the formula as follows: ; Represents a PyTorch computational graph, which is a directed computational graph. Here, V are the nodes in the computational graph, E are the edges in the computational graph, W is the weight tensor, M represents the dynamic computational symbol mapping, O represents the computational graph optimization process, and the computational graph optimization process includes operator fusion, computational graph pruning, and computational flow rearrangement. T' represents the conversion function for converting the PyTorch model to the ONNX model. Represents the input ONNX computational graph; Converting the onnx model into a trt model, with the formula as follows: ; Among them, represents the trt model, denotes the ONNX model weights, O represents computational graph optimization processing, F represents operator fusion, S represents the scaling factor, C represents the compiler mapping function, and the calculation method of the scaling factor S is as follows: ; Among them, b = n, indicating weight quantization For the ONNX model weights Perform FPn quantization, where FPn represents the model accuracy.

3. A three-dimensional reconstruction device for ultrasonic images of blood vessels, characterized in that, Including: An acquisition module for real-time acquisition of ultrasonic images of blood vessels; An acquisition module for obtaining the spatial pose information of the ultrasonic probe through an electromagnetic sensor, where the spatial pose information includes the position and rotation quaternion of the ultrasonic probe in space; A segmentation module for segmenting the ultrasonic image based on the U2-Net model to extract the ultrasonic blood vessel image, and accelerating the inference of the U2-Net model through the TensorRT framework during the segmentation process; A calculation module for calculating the transformation matrix from the ultrasonic image coordinate system to the electromagnetic sensor space, the transformation matrix from the electromagnetic sensor space to the magnetic field space, and the transformation matrix from the magnetic field space to the world coordinate system according to the coordinates of the calibration key points in the ultrasonic image coordinate system, electromagnetic positioning coordinate system, and world coordinate system respectively, and the spatial pose information, where the calibration key points are the key points calibrated in the ultrasonic image according to the ultrasonic calibration algorithm; A transformation module for transforming each pixel point of the blood vessel in the ultrasonic image into the navigation coordinate system through a geometric transformation algorithm based on the transformation matrix from the ultrasonic image coordinate system to the electromagnetic sensor space, the transformation matrix from the electromagnetic sensor space to the magnetic field space, and the transformation matrix from the magnetic field space to the world coordinate system to obtain a transformed image, where the navigation coordinate system is the world coordinate system; A rendering module, which is used to perform real-time rendering on the converted multiple frames of images in the world coordinate system to obtain a real-time three-dimensional reconstruction result; Among them, ; ; ; ; ; N is the number of calibration key points determined in the ultrasonic coordinate system and the electromagnetic positioning coordinate system obtained by calibration, where one calibration key point , is the coordinate of this key point in the ultrasonic image coordinate system, is the coordinate of this key point in the electromagnetic positioning coordinate system, is the coordinate of this key point in the world coordinate system, TM represents the matrix obtained by minimizing the left end of the equation, is the conversion matrix from the ultrasonic image coordinate system to the electromagnetic sensor space, is the conversion matrix from the electromagnetic sensor space to the magnetic field space, is the conversion matrix from the magnetic field space to the world coordinate system, is the said rotation quaternion, T represents translation, that is, the position of the ultrasonic probe in space, t x , t y , t z respectively represent the position coordinates of the probe on the three coordinate axes, and R represents the rotation matrix; ; Among them, is to convert the coordinates of pixel points in the image, and (x, y) are the coordinates of the pixel points of the blood vessel in the ultrasonic image coordinate system. S x , S y are the scaling factors of the x-axis and y-axis in the ultrasonic image coordinate system respectively.

4. A three-dimensional reconstruction device for ultrasonic images of blood vessels, characterized in that, Comprising: A memory for storing a computer program; A processor, which is used to implement the steps of the three-dimensional reconstruction method for ultrasonic images of blood vessels according to any one of claims 1 to 2 when executing the computer program.

5. A storage medium, characterized in that, The storage medium is a readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the steps of the three-dimensional reconstruction method for ultrasonic images of blood vessels according to any one of claims 1 to 2 are implemented.

Citation Information

Patent Citations

  • Positioning device based on small-scale three-dimensional array

    CN116256757A

  • Method and system for registering preoperative CT (Computed Tomography) image and intraoperative ultrasonic image

    CN116580003A