Method and device for locating a marker in a medical image, system, storage medium
Patent Information
- Application Number
- CN202510971942.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-15
- Publication Date
- 2026-10-27
- Estimated Expiration
- 2045-07-15
AI Technical Summary
然而,在实际应用中,相关技术均需扫描整幅高分辨率影像,匹配操作数量与影像像素规模呈正比,使得冗余计算较多,显著延长了处理时间,从而导致计算负担过重,无法满足术中实时性要求,严重制约导航系统的运行效率
[0020]通过基于预先标注的标记物初始位置信息构建标准匹配模板,并依据该位置在目标医学影像中限定局部匹配区域。局部匹配区域的构建将搜索范围从整幅影像缩减至初始位置周边有限区域,使得匹配操作数量仅与局部区域尺寸相关,而与影像总尺寸无关,即模板匹配操作仅需在局部区域内执行。从根本上避免了遍历整幅高分辨率影像的冗余计算,将匹配操作的计算量级从影像全局像素规模压缩至局部区域像素规模。减轻了医学影像中标记物定位的计算负担,缩短了处理时间,提升了导航系统的运行效率,从而满足了术中实时定位需求。
Smart Images

Figure CN120876603B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of surgical navigation technology, such as a method and apparatus for locating markers in medical images, a surgical navigation system, and a computer-readable storage medium. Background Technology
[0002] Currently, in orthopedic and spinal surgery navigation, the geometric parameter calibration of C-arm DR images directly determines surgical accuracy. This process requires extracting the projected coordinates of multiple metal spheres on the image calibrator to calculate the pose relationship between the light source and the image panel. However, the metal spheres are easily affected by bone occlusion, instrument interference, and image noise during surgery. Rapid and robust positioning of multiple metal spheres has become a core challenge for improving navigation efficiency.
[0003] To meet the needs of intraoperative automation, the relevant technologies mainly employ two types of methods. One type is a grayscale-based full-image template matching method, which predefines a standard template for a single metal sphere and calculates similarity by traversing the entire DR image using the predefined metal sphere template, locating the sphere's center position based on the peak similarity. The other type is an edge feature-based full-image matching method, which first uses an edge detection operator to extract the contour features of the DR image, then matches the predefined metal sphere edge template across the entire image using a sliding window, and finally performs topological relationship verification on discrete matching points using a distance matrix, filtering the results by extracting image edge features and combining them with the distance matrix.
[0004] In the process of implementing the embodiments of this disclosure, at least the following problems were found in the related art:
[0005] The adoption of related technologies has improved navigation efficiency to some extent. However, in practical applications, these technologies all require scanning the entire high-resolution image, and the number of matching operations is proportional to the image pixel size, resulting in a lot of redundant calculations and significantly extending the processing time. This leads to an excessive computational burden, making it impossible to meet the real-time requirements during surgery and severely restricting the operating efficiency of the navigation system.
[0006] It should be noted that the information disclosed in the background section above is only used to enhance the understanding of the background of this application, and therefore may include information that does not constitute prior art known to those skilled in the art. Summary of the Invention
[0007] To provide a basic understanding of some aspects of the disclosed embodiments, a brief summary is given below. This summary is not intended as a general commentary, nor is it intended to identify key / important components or describe the scope of protection of these embodiments, but rather as a prelude to the detailed description that follows.
[0008] This disclosure provides a method and apparatus for locating markers in medical images, a surgical navigation system, and a computer-readable storage medium, to reduce redundant calculations for marker location in medical images and improve the operating efficiency of the navigation system.
[0009] In some embodiments, the method includes: constructing a standard matching template containing the markers based on the initial position information of the pre-labeled markers in the initial medical image; constructing a local matching region in the target medical image based on the initial position information; and performing a template matching operation within the local matching region using the standard matching template to determine the actual position information of the markers in the target medical image.
[0010] Optionally, constructing a local matching region in the target medical image based on the initial location information includes: determining a first location in the target medical image corresponding to the initial location information based on the initial location information; and constructing a local matching region at the first location based on the size information of the marker and the allowable image offset redundancy range.
[0011] Optionally, based on the size information of the marker and the allowable image offset redundancy range, a local matching region is constructed at the first location, including: determining the projection diameter of the marker in the initial medical image; calculating the side length of the local matching region based on the projection diameter plus an allowable image offset redundancy range; and constructing a rectangular local matching region around the first location according to the calculated side length.
[0012] Optionally, based on the initial position information of the pre-labeled markers in the initial medical image, a standard matching template containing the markers is constructed, including: identifying at least one marker in the initial medical image as the target marker; and based on the initial position information of the target marker, extracting a region containing the target marker in the initial medical image as the standard matching template.
[0013] Optionally, a template matching operation is performed within a local matching region using a standard matching template to determine the actual position information of the marker in the target medical image. This includes: moving the standard matching template within the local matching region according to a set step size to obtain matching images corresponding to standard matching templates at different positions; obtaining the similarity between the standard matching template and the matching images, and determining the matching image with the highest similarity as the target matching image; and determining the position in the target matching image corresponding to the initial position information of the standard matching template as the actual position information of the marker.
[0014] Optionally, before constructing a standard matching template containing markers based on the initial position information of the pre-annotated markers in the initial medical image, the method further includes: capturing the initial medical image containing the image calibrator; determining the position of the markers in the initial reference image through annotation operations; wherein the annotation operations include at least one of manual annotation, automatic detection, or semi-automatic interactive annotation; and saving the position of the markers to the surgical navigation system.
[0015] Optionally, the initial location information includes: the center position of the marker and / or the marker number.
[0016] In some embodiments, the apparatus includes a processor and a memory storing program instructions, the processor being configured to execute the method for locating markers in medical images when executing the program instructions.
[0017] In some embodiments, the surgical navigation system includes: a surgical navigation system body; and a positioning device for markers in the medical image described above, which is mounted on the surgical navigation system body.
[0018] In some embodiments, the computer-readable storage medium stores program instructions that, when executed, perform the method for locating markers in medical images described above.
[0019] The method and apparatus for locating markers in medical images, the surgical navigation system, and the computer-readable storage medium provided in this disclosure can achieve the following technical effects:
[0020] A standard matching template is constructed based on the initial position information of pre-labeled markers, and a local matching region is defined in the target medical image based on this position. The construction of the local matching region reduces the search scope from the entire image to a limited area around the initial position. This makes the number of matching operations only related to the size of the local region, and independent of the total image size; that is, template matching operations only need to be performed within the local area. This fundamentally avoids redundant computations that traverse the entire high-resolution image, compressing the computational load of matching operations from the global pixel scale of the image to the local pixel scale. This reduces the computational burden of marker localization in medical images, shortens processing time, and improves the operating efficiency of the navigation system, thereby meeting the requirements for real-time intraoperative positioning.
[0021] The above general description and the description below are exemplary and illustrative only and are not intended to limit this application. Attached Figure Description
[0022] One or more embodiments are illustrated by way of example with reference to the accompanying drawings. These illustrations and drawings do not constitute a limitation on the embodiments. Elements having the same reference numerals in the drawings are shown as similar elements. The drawings are not to be scaled. And wherein:
[0023] Figure 1 This is a schematic diagram of a method for locating markers in medical images provided in an embodiment of this disclosure;
[0024] Figure 2 This is a schematic diagram of another method for locating markers in medical images provided in an embodiment of this disclosure;
[0025] Figure 3 This is a schematic diagram of another method for locating markers in medical images provided in an embodiment of this disclosure;
[0026] Figure 4 This is a schematic diagram of another method for locating markers in medical images provided in an embodiment of this disclosure;
[0027] Figure 5 This is a schematic diagram of a marker positioning device in a medical image provided in an embodiment of the present disclosure.
[0028] Figure label:
[0029] 800: Location device for markers in medical images; 801: Processor; 802: Memory; 803: Communication interface; 804: Bus. Detailed Implementation
[0030] To provide a more detailed understanding of the features and technical content of the embodiments of this disclosure, the implementation of the embodiments of this disclosure will be described in detail below with reference to the accompanying drawings. The accompanying drawings are for illustrative purposes only and are not intended to limit the embodiments of this disclosure. In the following technical description, for ease of explanation, several details are used to provide a full understanding of the disclosed embodiments. However, one or more embodiments may still be implemented without these details. In other cases, well-known structures and devices may be simplified in their depiction to simplify the drawings.
[0031] The terms "first," "second," etc., used in the specification, claims, and accompanying drawings of this disclosure are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate for the embodiments of this disclosure described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion.
[0032] In this disclosure, the terms "upper," "lower," "inner," "middle," "outer," "front," and "rear," etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings. These terms are primarily for better description of the embodiments of this disclosure and their implementations, and are not intended to limit the indicated devices, elements, or components to having a specific orientation, or to require them to be constructed and operated in a specific orientation. Furthermore, some of the aforementioned terms may be used to indicate other meanings besides orientation or positional relationship; for example, the term "upper" may in some cases indicate a dependency or connection relationship. Those skilled in the art can understand the specific meaning of these terms in the embodiments of this disclosure according to the specific circumstances.
[0033] Furthermore, the terms "set up," "connect," and "fix" should be interpreted broadly. For example, "connection" can be a fixed connection, a detachable connection, or an integral structure; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium, or it can be an internal connection between two devices, components, or parts. Those skilled in the art can understand the specific meaning of the above terms in the embodiments of this disclosure according to the specific circumstances.
[0034] Unless otherwise stated, the term "multiple" means two or more.
[0035] In this embodiment of the disclosure, the character " / " indicates that the objects before and after it are in an "or" relationship. For example, A / B means: A or B.
[0036] The term "and / or" describes an association between objects, indicating that three relationships can exist. For example, A and / or B means: A or B, or A and B.
[0037] The term "correspondence" can refer to an association or binding relationship. The correspondence between A and B means that there is an association or binding relationship between A and B.
[0038] It should be noted that, unless otherwise specified, the embodiments and features described in the present disclosure can be combined with each other.
[0039] Figures 1 to 4 This is a schematic diagram of a method for locating markers in medical images provided in an embodiment of this disclosure. Any of the following methods can be executed in a surgical navigation system, or in a server or terminal device that is communicatively connected to the surgical navigation system.
[0040] Combination Figure 1 As shown, this disclosure provides a method for locating markers in medical images, including:
[0041] S01, construct a standard matching template containing the markers based on the initial position information of the pre-labeled markers in the initial medical image.
[0042] S02, Based on the initial location information, construct a local matching region in the target medical image.
[0043] S03, Use a standard matching template to perform template matching operation within the local matching area to determine the actual location information of the marker in the target medical image.
[0044] In this embodiment of the disclosure, constructing a standard matching template includes: taking the initial position of the marker as the center, and extracting a rectangular region as the standard matching template. The side length of this rectangular region is determined based on the projected diameter of the marker multiplied by a size factor. The size factor ensures that the region completely covers the marker image and has compact boundaries. The size factor can be 1.2 times or 1.5 times. For example, when the projected diameter is 20 pixels, the side length of the rectangular region is set to 24 pixels or 30 pixels to exclude the image influence of intraoperative interferences such as bones or instruments.
[0045] In this embodiment, the size information of the marker includes the projected diameter or projected radius, and the allowable image offset redundancy range is determined based on a scaling factor of the standard matching template size. The scaling factor can be 0.4 or 0.6 times; for example, when the standard matching template size is 30 pixels, the allowable image offset redundancy range is set to 12 pixels or 18 pixels. The side length of the local matching region is calculated based on the projected radius plus twice the allowable image offset redundancy range corresponding to the projected radius, or based on the projected diameter plus the allowable image offset redundancy range corresponding to the projected diameter. For example, when the projected diameter is 20 pixels and the allowable image offset redundancy range is 12 pixels, the side length is calculated to be 32 pixels.
[0046] In practical applications, pre-labeled markers can be metal spheres on the image calibrator, non-metallic spheres containing high-density contrast agents (such as barium-containing plastic spheres), or other markers. The initial medical image can be a C-arm DR image containing only the image calibrator, taken preoperatively or during the first use of the system. Initial location information includes the center position of the marker and the marker number, where the center position is determined manually, and the marker number corresponds to the physical number of the marker on the image calibrator. When constructing the standard matching template, based on the initial location information of the marker, a rectangular region containing the complete image of a single marker is extracted from the initial medical image. The size of this region can be 50×50 pixels or 60×60 pixels, the center of the rectangular region is aligned with the center position of the marker, the boundaries are compact, and it does not contain other markers or interfering images.
[0047] The method for locating markers in medical images provided in this disclosure constructs a standard matching template based on the initial position information of pre-labeled markers, and then defines a local matching region in the target medical image based on this position. The construction of the local matching region reduces the search scope from the entire image to a limited area surrounding the initial position, making the number of matching operations only related to the size of the local region and independent of the total image size; that is, the template matching operation only needs to be performed within the local area. This fundamentally avoids redundant calculations that traverse the entire high-resolution image, compressing the computational load of the matching operation from the global pixel scale of the image to the local pixel scale. This reduces the computational burden of marker location in medical images, shortens processing time, and improves the operating efficiency of the navigation system, thereby meeting the requirements for real-time intraoperative positioning.
[0048] Combination Figure 2 As shown, this disclosure provides another method for locating markers in medical images, including:
[0049] S01, construct a standard matching template containing the markers based on the initial position information of the pre-labeled markers in the initial medical image.
[0050] S21, Based on the initial position information, determine the first position in the target medical image that corresponds to the initial position information.
[0051] S22, Based on the size information of the marker and the allowed range of image offset redundancy, a local matching region is constructed at the first position.
[0052] S03, Use a standard matching template to perform template matching operation within the local matching area to determine the actual location information of the marker in the target medical image.
[0053] In this embodiment, determining the first position in the target medical image based on the initial position information includes: mapping the marker center coordinates in the initial position information to the coordinate system of the target medical image using geometric transformation parameters between the initial and target medical images. Specifically, the geometric transformation parameters include a translation vector and a rotation matrix, which can be obtained through the preoperative calibration process of C-arm DR images; the translation vector is used to compensate for pose changes of the image acquisition device, and the rotation matrix is used to correct the viewpoint offset of the image. The mapped coordinates serve as the center point of the first position, ensuring that the construction of the local matching region in the target medical image is consistent with the spatial relationship of the initial position information. And / or, based on the marker numbers contained in the initial position information, combined with the physical structure parameters of the image calibrator, a reference coordinate system corresponding to the number is preset in the target medical image. Specifically, the physical structure parameters of the image calibrator include the spacing and numbering order of the metal spheres, which can be determined preoperatively through 3D modeling; in the target medical image, based on the binding relationship between the numbering order and the spacing, the theoretical coordinates of each marker in the target image are derived and used as the center point of the first position. By directly linking physical numbers with spatial coordinates, coordinate drift caused by intraoperative image distortion is avoided.
[0054] The marker localization method in medical images provided in this disclosure uses initial position information derived from preoperative manual annotation or the correspondence between physical sphere numbers stored in the system. Its stability is based on the structural rigidity of the C-arm image calibrator and the small-range offset characteristics of the metal sphere projection position. The size of the local matching region is determined by the size information of the marker and the redundancy range, ensuring coverage of the actual offset possibility while avoiding excessive expansion that would increase redundant calculations. Since the matching operation is performed only within a local area, its computational complexity is related to the pixel scale of the local area, rather than the global pixel scale of the entire high-resolution image, thus significantly reducing the computational burden and shortening the processing time. At the same time, the allowable offset redundancy range design takes into account the projection offset caused by image brightness changes, noise interference, or slight deformation, improving the robustness of the matching process. Furthermore, the independent construction of the local matching region ensures that the matching of each metal sphere does not interfere with each other. Even if some matching fails, the remaining metal spheres can still be extracted normally, further ensuring the reliability and processing efficiency of the system in complex intraoperative environments.
[0055] Optionally, based on the size information of the marker and the allowable image offset redundancy range, a local matching region is constructed at the first location, including: determining the projection diameter of the marker in the initial medical image; calculating the side length of the local matching region based on the projection diameter plus an allowable image offset redundancy range; and constructing a rectangular local matching region around the first location according to the calculated side length.
[0056] In this embodiment, determining the projected diameter of the marker in the initial medical image includes: extracting the contour boundary of the marker using an edge detection algorithm, and calculating the maximum span of the contour boundary in the horizontal and vertical directions as the projected diameter. Specifically, the horizontal span is the difference between the pixel coordinates of the left and right boundaries of the contour, and the vertical span is the difference between the pixel coordinates of the upper and lower boundaries of the contour; the larger of the two values is taken as the projected diameter. For example, when the horizontal span is 20 pixels and the vertical span is 18 pixels, the projected diameter is 20 pixels. This method ensures that the measured projected diameter is consistent with the actual projected shape of the marker through automated edge detection and geometric calculation. And / or, the projected diameter is calculated based on the ratio of the physical diameter of the marker to the resolution of the initial medical image. Specifically, the physical diameter of the marker is determined through preoperative 3D modeling, and the resolution of the initial medical image is obtained through the parameter table of the image acquisition device; the projected diameter is equal to the physical diameter divided by the resolution ratio. For example, when the physical diameter is 5 mm and the resolution ratio is 0.2 mm / pixel, the projected diameter is calculated to be 25 pixels. By binding physical properties with imaging parameters, the calculated projection diameter is ensured to be consistent with the projection scale of the actual intraoperative image.
[0057] In this embodiment, calculating the side length of the local matching region based on the projection diameter plus an allowable image offset redundancy range includes: setting the projection diameter as a first parameter, the allowable image offset redundancy range as a second parameter, and the side length equal to the sum of the first parameter multiplied by a first size factor and the second parameter multiplied by a second size factor. Through the design of the differentiation coefficient, the side length can adapt to the differences in marker projection in images of different resolutions, and also accommodate projection offsets caused by changes in device pose during surgery. Alternatively, the side length can be the sum of twice the first parameter and twice the second parameter. By standardizing the proportional relationship, the size of the local matching region is ensured to match the physical characteristics of the marker and the noise level of the intraoperative image, improving matching robustness.
[0058] In this embodiment, constructing a rectangular local matching region around the first position according to the calculated side length includes: using the center coordinates of the first position as the geometric center of the rectangular region, extending half the side length in both the horizontal and vertical directions to form the rectangular local matching region. The rectangular local matching region is strictly aligned with the first position and covers the actual projection offset range of the markers. And / or, the size of the rectangular local matching region is adjusted according to the arrangement spacing of the markers to avoid the projections of adjacent markers appearing in a single rectangular local matching region. The arrangement spacing of the markers is positively correlated with the size of the rectangular local matching region. Specifically, when the arrangement spacing of the markers is less than twice the projection diameter, the side length of the rectangular region is set to 1 to 1.2 times the projection diameter; when the arrangement spacing is greater than twice the projection diameter, the side length is set to 1.5 to 2 times the projection diameter. Through differentiated design, the size of the rectangular region is adapted to the risk of occlusion and spatial constraints of intraoperative images, improving matching efficiency.
[0059] In practical applications, the first position in the target medical image corresponding to the initial position information is determined based on the initial position information; the projection radius of the marker in the initial medical image is determined, which is equal to half the size of the standard matching template; the allowable image offset redundancy range corresponding to the projection radius is set, which is 0.5 to 1 times the size of the standard matching template; the side length of the local matching region is calculated based on twice the projection radius (i.e., the projection diameter) plus twice the allowable image offset redundancy range corresponding to the projection radius (i.e., the allowable image offset redundancy range corresponding to the projection diameter); a rectangular local matching region with the calculated side length is constructed around the first position to ensure that the local matching region completely covers the actual projected image of the marker and its possible projection offset range.
[0060] In this way, the projected position of the metal sphere during surgery has only a limited offset relative to the initial label. The size of the local matching area is constrained by the actual projected size of the marker and the preset offset redundancy range, ensuring that the local area can both completely cover the actual projected range of the metal sphere and accommodate slight positional drift that may occur during surgery. By strictly limiting the matching search range to a finite rectangular area around the initial position, the number of matching operations is only related to the pixel scale of the local area, reducing computational complexity and thus significantly reducing processing time, improving the real-time response capability of the navigation system, while maintaining the coverage and reliability of intraoperative positioning.
[0061] Combination Figure 3 As shown, this disclosure provides a method for locating markers in medical images, including:
[0062] S31, Identify at least one marker in the initial medical image as the target marker.
[0063] S32, based on the initial location information of the target marker, extract the region containing the target marker from the initial medical image as a standard matching template.
[0064] S02, Based on the initial location information, construct a local matching region in the target medical image.
[0065] S03, Use a standard matching template to perform template matching operation within the local matching area to determine the actual location information of the marker in the target medical image.
[0066] In this embodiment of the disclosure, a target marker in the initial medical image is determined based on the initial position information of the pre-labeled marker in the initial medical image; around the initial position information of the target marker, a rectangular region containing the target marker is cropped in the initial medical image as a standard matching template, wherein the center position of the standard matching template is aligned with the center position of the marker, the boundary range of the standard matching template is compact and contains only a complete image of a single target marker, excluding other interfering images; the constructed standard matching template is used to reuse in the template matching operation of multiple subsequent target medical images.
[0067] In this embodiment of the disclosure, determining at least one marker in the initial medical image as a target marker includes: identifying the center position of the marker through manual annotation, and selecting markers with unique physical numbers as target markers based on the physical structural parameters of the image calibrator (e.g., the spacing and numbering order of the metal spheres). The selection of a target marker must at least meet the following conditions: its physical number is consistent with the predefined structure of the image calibrator, and it is not obscured by bones or instruments in the initial medical image. Specifically, the physical structural parameters can be determined through preoperative 3D modeling; the spacing of the markers can be set to a preset spacing, such as 5 mm or 10 mm; the numbering order is based on the spatial symmetry design of the image calibrator, for example, arranged in row-first or column-first order. Target markers selected through the above conditions ensure a one-to-one correspondence between the subsequent template matching operation and the physical space. And / or, based on the physical characteristics of the marker (e.g., density differences or material differences), its projection shape in the initial medical image is automatically detected, and the contour boundary is extracted using an edge detection algorithm to verify the integrity of the marker. Physical characteristics can be obtained through preoperative calibration data. For example, the density difference of the metal spheres can be set as a preset difference value, such as 1.2 g / cm³ or 1.5 g / cm³. Material differences can be distinguished by grayscale distribution characteristics. The automated detection process can employ threshold segmentation or morphological operations. For instance, after smoothing the image with a Gaussian filter, the optimal segmentation threshold can be determined using the Otsu algorithm. Using these methods, target markers can be quickly located without human intervention, improving the system's automation level.
[0068] In this embodiment of the disclosure, extracting a region containing the target marker from the initial medical image as a standard matching template based on the initial position information of the target marker includes: calculating the size of the template region based on the projection diameter of the marker, and setting a boundary compactness constraint to exclude interfering images. The projection diameter can be calculated after extracting the contour boundary using an edge detection algorithm, for example, the larger value of the horizontal span and the vertical span can be used as the projection diameter; the boundary compactness constraint requires that the template region contains only the complete image of the target marker and does not overlap with the projection regions of adjacent markers. And / or, the size of the template region is dynamically adjusted to adapt to the noise level of the intraoperative image, and a redundant range is introduced to compensate for possible projection offsets. The introduction of the redundant range can accommodate projection offsets caused by changes in device pose, for example, when the source-image distance of the C-arm changes, the projection position of the marker may shift, and the redundant range can cover such offsets.
[0069] The method for locating markers in medical images provided in this disclosure involves a fixed connection between the image calibrator and the C-arm flat panel sensor. The projected shape of the metal sphere remains stable across multiple images. A compact region containing only a single marker is selected as a template, effectively eliminating the image interference from intraoperative contaminants such as bones and instruments, ensuring the template image possesses high-purity features (containing only the complete image of the target metal sphere). Furthermore, the alignment of the template center with the initial position of the marker provides a highly correlated comparison benchmark for subsequent local matching. Generating a suitable template directly based on actual image features improves the similarity between the template and the intraoperative image, thereby enhancing the accuracy of the matching algorithm and avoiding the risk of misidentification due to template mismatch.
[0070] Combination Figure 4 As shown, this disclosure provides a method for locating markers in medical images, including:
[0071] S01, construct a standard matching template containing the markers based on the initial position information of the pre-labeled markers in the initial medical image.
[0072] S02, Based on the initial location information, construct a local matching region in the target medical image.
[0073] S41, using a standard matching template, move within the local matching region according to a set step size to obtain matching images corresponding to standard matching templates at different positions.
[0074] S42, obtain the similarity between the standard matching template and the matching image, and determine the matching image with the highest similarity as the target matching image.
[0075] S43, determine the actual position information of the marker in the target matching image as the position corresponding to the initial position information of the standard matching template.
[0076] In this embodiment, a standard matching template is used to move within a local matching region at a unit pixel step size to obtain matching images corresponding to different positions. The normalized cross-correlation matching score between the standard matching template and each matching image is calculated. This score is calculated using the pixel grayscale of the standard matching template image, the pixel grayscale of the current matching image within the local matching region, the average grayscale of the standard matching template image, and the average grayscale of the matching images. The matching score ranges from -1 to 1, with a value closer to 1 indicating a higher similarity. The position with the highest matching score is selected as the actual position information of the marker. When the matching score exceeds a set threshold, it is determined to be a valid matching result; otherwise, it is marked as abnormal. Each marker independently performs the above template matching operation. The number of matching calculations is determined by the size of the local matching region and the size of the standard matching template, and the number of matching operations is significantly less than that of a full image traversal operation.
[0077] In practical applications, within a local matching region, a sliding method is used, with a step size of one pixel, to match the standard matching template with every possible matching image I within the local matching region. xy Perform a one-by-one comparison. For each position (x, y) within a local matching region, calculate its normalized cross-correlation matching score NCC(x, y), using the following formula:
[0078]
[0079] Where T(u, v) is the pixel gray level of the standard matching template image, and I(x+u, y+v) is the pixel gray level of the current matching image within the local matching region. and The average gray values of the standard matching template and the matching image are respectively. The denominator is normalized to make the algorithm insensitive to changes in overall brightness. The matching score NCC∈[-1, 1], and the closer it is to 1, the higher the similarity between the standard matching template and the matching image.
[0080] Since the side length D of the standard matching template is approximately the same as the projection diameter of the marker in the target medical image, assuming the size of the standard matching template is D×D, the number of template matching calculations N to be performed in each local matching region is:
[0081] N = (L - D + 1) 2 =(2R+2δ-D+1) 2 =(2δ+1) 2 ;
[0082] Where is the side length of the local matching region, D is the side length of the standard matching template, is the projection radius of the marker in the target medical image, and δ is the allowed image offset redundancy range.
[0083] In this embodiment, using a standard matching template to move within a local matching region at a set step size to obtain matching images corresponding to standard matching templates at different positions includes: moving the standard matching template row by row and column by column within the local matching region using a sliding window mechanism at a set step size, generating a matching image corresponding to each moving position. During the movement, the overlapping area between the standard matching template and the local matching region must satisfy the overlap parameter constraint. The overlap parameter can be a first multiple (0.8 times or 1 times) of the standard matching template size to ensure that the matching image contains complete template features. By controlling the step size and overlap ratio, computational efficiency and matching accuracy are balanced, avoiding the risk of missed detections due to excessively large step sizes. And / or, the step size is dynamically adjusted to adapt to the resolution of the target medical image, with the step size set to a second multiple (0.5 times or 1 times) of the standard matching template size; when the resolution of the target medical image is higher than that of the initial medical image, the second multiple is a smaller value to improve positioning accuracy; when the resolution is lower, the second multiple is a larger value to reduce computation. The dynamic adjustment process is calculated based on a resolution scaling factor, and the adjusted step size is the product of the resolution scaling factor and the standard matching template size. By adopting an adaptive step size design, the processing needs of images with different resolutions are taken into account, and the allocation of computing resources is optimized while ensuring matching accuracy.
[0084] In other embodiments, a multi-scale similarity evaluation mechanism may be introduced, combining the NCC score and edge gradient similarity (EDS) to comprehensively determine the matching quality. The EDS calculation formula is:
[0085]
[0086] in, and These are the gradient magnitudes of the standard matching template and the matching image, respectively.
[0087] The formula for calculating the overall score is:
[0088] Score=α×NCC+(1-α)×(1-EDS);
[0089] Here, α (e.g., 0.7 or 0.8) is the weighting coefficient. By fusing grayscale similarity and edge feature similarity, the matching robustness in complex backgrounds is improved, which is especially suitable for scenarios where the projection of the metal sphere has local blurring or noise interference.
[0090] The marker localization method in medical images provided in this disclosure achieves fine-grained positioning of the projected position of the metal sphere by using pixel-by-pixel step-by-step comparison after initial position constraints, and the normalized similarity metric effectively resists interference from brightness changes in intraoperative images. The similarity peak detection mechanism ensures high-confidence position output when the metal sphere's shape is stable, and the matching process is completely confined to a preset redundancy range, avoiding the ineffective calculations of traditional full-image traversal. While ensuring positioning accuracy, the matching computation is compressed to a local area scale. This significantly reduces the matching time for a single marker, improves intraoperative positioning efficiency, and provides accurate and orderly coordinate input for subsequent navigation processes.
[0091] Optionally, before constructing a standard matching template containing markers based on the initial position information of the pre-annotated markers in the initial medical image, the method further includes: capturing the initial medical image containing the image calibrator; determining the position of the markers in the initial reference image through annotation operations; wherein the annotation operations include at least one of manual annotation, automatic detection, or semi-automatic interactive annotation; and saving the position of the markers to the surgical navigation system.
[0092] In this embodiment of the disclosure, before surgery or when the system is used for the first time, an initial medical image containing an image calibrator and without intraoperative interference is captured; the operator performs annotation operations in the initial medical image in a predetermined order to manually determine the initial position information of the marker in the initial medical image, wherein the initial position information includes the center position of the marker and the number of the marker; the initial position information of the marker is saved to the surgical navigation system for subsequent image processing.
[0093] In this embodiment, acquiring initial medical images including an image calibrator involves: using a C-arm DR device to acquire a two-dimensional image containing only the image calibrator at a first resolution parameter; during image acquisition, the fixing bracket of the image calibrator maintains a mechanical connection with the C-arm flat panel sensor to ensure that the spatial pose of the image calibrator is consistent with its actual use during surgery. Specifically, the image acquisition conditions must meet the following constraints: the metal ball of the image calibrator is not obstructed by bone or instruments, and the image background is free from high-density contrast agent interference; the image brightness value distribution range meets preset conditions to ensure that the projected shape of the marker is clearly distinguishable. By standardizing the preoperative image acquisition process, a high signal-to-noise ratio initial reference image is provided for subsequent annotation operations.
[0094] In this embodiment, determining the position of a marker in the initial reference image through annotation includes: using a semi-automatic interactive annotation method, combining edge detection algorithms with manual point selection to generate the center coordinates of the marker; specifically, firstly, Gaussian filtering is performed on the initial medical image for noise reduction, and then the Canny operator is used to extract the contour boundary of the marker; the larger value of the horizontal span and the vertical span is calculated based on the contour boundary as the projection diameter; the manual point selection operation must be completed within the contour boundary, and the selection error must be within a preset error range. By combining automated preprocessing with manual verification, the accuracy and reliability of the annotation results are ensured, avoiding positioning deviations caused by preoperative image noise or blurred metal ball projection.
[0095] In this embodiment, saving the location of the marker to the surgical navigation system includes: storing the annotation results in a system database in a set format, which can be JSON or XML; the stored content includes the marker's center coordinates, physical number, and projection diameter information; the binding relationship between the center coordinates and the physical number is determined by predefined structural parameters of the image calibrator. Specifically, the storage operation must follow preset rules, which can be "a one-to-one correspondence between the center coordinates and the physical number, and cannot be modified," to ensure consistency between the intraoperative positioning process and the physical space. Through structured data storage, a traceable initial position reference is provided for subsequent template matching operations, improving the robustness and maintainability of the system.
[0096] In this way, capturing the initial image containing only the image calibrator ensures the purity of the marker morphology (free from intraoperative bone or instrument interference). Marker positions are determined through manual annotation, automatic detection, or semi-automatic interactive methods, preserving operational flexibility while providing the system with highly reliable initial coordinates. Persistently saving the position information to the navigation system allows all subsequent intraoperative image processing to directly access this spatial reference. By fully utilizing the mechanical fixation characteristics of the image calibrator and C-arm, the intraoperative projection position of the metal ball exhibits only a limited offset relative to the initial coordinates, thus providing the necessary prerequisite for subsequent local matching guided by the initial position. By establishing a stable and traceable positional benchmark, the reliance on full-image scanning for real-time intraoperative positioning is reduced, laying a data foundation for the efficient operation of subsequent steps such as local matching area construction and template comparison, achieving rapid response and improved robustness throughout the entire navigation process.
[0097] Optionally, the initial location information includes: the center position of the marker and / or the marker number.
[0098] In this embodiment, based on the pre-saved binding relationship between marker numbers and initial location information, an independent local matching region is constructed for each marker in the target medical image. A template matching operation is performed within each local matching region to output the actual location information of the marker. Since each local matching region is associated with initial location information of a specific number, the output actual location information automatically inherits the corresponding marker number, forming a set of actual location information with numerical order. This avoids post-processing sorting or distance matrix comparison of the actual location information set, and the failure to match a single marker does not affect the localization results of other markers.
[0099] In this way, the central location serves as the spatial coordinate reference, directly contributing to the construction of the local matching region and ensuring that the search window accurately covers the range where markers may have shifted. The numbering information is inherited from the physical structural order of the initial annotation, naturally binding to each marker during the matching process. This dual attribute fully leverages the mechanical stability of the image calibrator; the fixed spatial arrangement and unique numbering of the metal spheres ensure that the intraoperative localization results simultaneously retain the correspondence between spatial location and logical number. This avoids the additional numbering inference steps required by traditional methods (such as distance matrix post-processing), reducing computational coupling and anomaly sensitivity, while ensuring that the output directly meets the navigation system's requirement for ordered coordinates, thus improving the efficiency and reliability of pose determination.
[0100] Combination Figure 5 As shown, this embodiment of the present disclosure provides a marker localization device 800 in medical images, including a processor 801 and a memory 802. Optionally, the device may further include a communication interface 803 and a bus 804. The processor 801, communication interface 803, and memory 802 can communicate with each other via the bus 804. The communication interface 803 can be used for information transmission. The processor 801 can call logical instructions in the memory 802 to execute the marker localization method in medical images described in the above embodiment.
[0101] Furthermore, the logic instructions in the aforementioned memory 802 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium.
[0102] The memory 802, as a computer-readable storage medium, can be used to store software programs and computer-executable programs, such as program instructions / modules corresponding to the methods in the embodiments of this disclosure. The processor 801 executes functional applications and data processing by running the program instructions / modules stored in the memory 802, thereby implementing the method for locating markers in medical images in the above embodiments.
[0103] The memory 802 may include a program storage area and a data storage area. The program storage area may store the operating system and application programs required for at least one function; the data storage area may store data created based on the use of the terminal device. Furthermore, the memory 802 may include high-speed random access memory and may also include non-volatile memory.
[0104] This disclosure provides a surgical navigation system, including a surgical navigation system body and a positioning device 800 for markers in medical images. The positioning device 800 for markers in medical images is mounted on the surgical navigation system body. The mounting relationship described herein is not limited to placement within the surgical navigation system, but also includes mounting connections with other components of the surgical navigation system, including but not limited to physical connections, electrical connections, or signal transmission connections. Those skilled in the art will understand that the positioning device 800 for markers in medical images can be adapted to any feasible surgical navigation system body, thereby realizing other feasible embodiments.
[0105] This disclosure provides a computer-readable storage medium storing computer-executable instructions configured to perform a method for locating markers in a medical image.
[0106] The technical solutions of this disclosure can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes one or more instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the method described in this disclosure. The aforementioned storage medium can be a non-transitory storage medium, including: a USB flash drive, a portable hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, and other media capable of storing program code.
[0107] The foregoing description and accompanying drawings fully illustrate embodiments of this disclosure to enable those skilled in the art to practice them. Other embodiments may include structural, logical, electrical, procedural, and other changes. The embodiments represent only possible variations. Individual components and functions are optional unless explicitly required, and the order of operation may vary. Parts and features of some embodiments may be included in or replace parts and features of other embodiments. Moreover, the terminology used in this application is for describing embodiments only and is not intended to limit the claims. As used in the description of embodiments and claims, the singular forms “a,” “an,” and “the” are intended to equally include the plural forms unless the context clearly indicates otherwise. Similarly, the term “and / or” as used in this application means including one or more of the associated listed items and all possible combinations thereof. Additionally, when used in this application, the term "comprise" and its variations "comprises" and / or "comprising" refer to the presence of stated features, integrals, steps, operations, elements, and / or components, but do not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components, and / or groups thereof. Without further limitations, an element defined by the phrase "comprises a..." does not exclude the presence of other identical elements in the process, method, or apparatus that includes said element. In this document, each embodiment may focus on the differences from other embodiments, and similar or identical parts between embodiments can be referred to mutually. For methods, products, etc., disclosed in the embodiments, if they correspond to the method section disclosed in the embodiments, the relevant parts can be referred to the description of the method section.
[0108] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the embodiments of this disclosure. Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0109] The methods and products (including but not limited to devices and equipment) disclosed in the embodiments herein can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For instance, the division of units may be merely a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. In addition, the coupling or direct coupling or communication connection between the shown or discussed units may be through some interfaces, and the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of the units may be selected to implement this embodiment according to actual needs. Furthermore, the functional units in the embodiments of this disclosure may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0110] 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 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. In some alternative implementations, the functions marked in the blocks may occur in a different order than that shown in the drawings. For example, two consecutive blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. In the descriptions corresponding to the flowcharts and block diagrams in the accompanying drawings, the operations or steps corresponding to different blocks may also occur in a different order than disclosed in the description, and sometimes there is no specific order between different operations or steps. For example, two consecutive operations or steps may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. Each block in a block diagram and / or flowchart, and combinations of blocks in a block diagram and / or flowchart, can be implemented using a dedicated hardware-based system that performs the specified function or action, or using a combination of dedicated hardware and computer instructions.
Claims
1. A method for locating markers in medical images, characterized in that, include: Before surgery or when the system is used for the first time, take initial medical images. The initial medical images include the image calibrator but do not contain intraoperative interference. The initial position information of markers in the initial medical image is determined by the annotation operation, and the initial position information of the markers is saved to the surgical navigation system; Based on the initial location information of pre-labeled markers in the initial medical image, a standard matching template containing the markers is constructed; Based on the initial location information, a local matching region is constructed in the target medical image; the size of the local matching region is determined based on the size information of the markers and the allowable range of image offset redundancy. A standard matching template is used to perform template matching within a local matching area to determine the actual location information of the marker in the target medical image.
2. The method according to claim 1, characterized in that, Based on the initial location information, a local matching region is constructed in the target medical image, including: Based on the initial location information, determine the first location in the target medical image that corresponds to the initial location information; Based on the size information of the markers and the allowable range of image offset redundancy, a local matching region is constructed at the first location.
3. The method according to claim 2, characterized in that, Based on the size information of the markers and the allowable range of image offset redundancy, a local matching region is constructed at the first location, including: Determine the projection diameter of the marker in the initial medical image; The side length of the local matching region is calculated based on the projection diameter plus an allowable image offset redundancy range. Around the first position, construct a rectangular local matching region according to the calculated side length.
4. The method according to any one of claims 1 to 3, characterized in that, Based on the initial location information of pre-labeled markers in the initial medical image, a standard matching template containing the markers is constructed, including: Identify at least one marker in the initial medical images as the target marker; Based on the initial location information of the target marker, the region containing the target marker is extracted from the initial medical image as a standard matching template.
5. The method according to any one of claims 1 to 3, characterized in that, Using a standard matching template, template matching is performed within a local matching region to determine the actual location information of the marker in the target medical image, including: The standard matching template is used to move within a local matching region according to a set step size to obtain matching images corresponding to the standard matching template at different positions. Obtain the similarity between the standard matching template and the matching image, and determine the matching image with the highest similarity as the target matching image; The position in the target matching image that corresponds to the initial position information of the standard matching template is determined as the actual position information of the marker.
6. The method according to any one of claims 1 to 3, characterized in that, The annotation operation includes at least one of the following methods: manual annotation, automatic detection, or semi-automatic interactive annotation.
7. The method according to any one of claims 1 to 3, characterized in that, Initial location information includes: The center position of the marker and / or the number of the marker.
8. A device for locating markers in medical images, comprising a processor and a memory storing program instructions, characterized in that, The processor is configured to, when running the program instructions, perform a method for locating markers in medical images as described in any one of claims 1 to 7.
9. A surgical navigation system, characterized in that, include: The surgical navigation system itself; and, The positioning device for markers in medical images as described in claim 8 is installed on the main body of the surgical navigation system.
10. A computer-readable storage medium storing program instructions, characterized in that, When the program instructions are executed, they cause the computer to perform the method for locating markers in medical images as described in any one of claims 1 to 7.
Citation Information
Patent Citations
Tracing ball positioning method under three-dimensional image
CN115546783A
Image position matching method and apparatus
US20010048758A1