Spatial segmentation radiotherapy ball target automatic generation method based on hexagonal closest packing

By using a hexagonal densest packing method, spatial segmentation radiotherapy targets are automatically generated, solving the problems of low efficiency, suboptimal distribution, and insufficient accuracy in existing technologies. This achieves efficient and accurate target generation and data association, and supports one-click integration into existing radiotherapy systems.

CN121982165APending Publication Date: 2026-05-05RENMIN HOSPITAL OF WUHAN UNIVERSITY (HUBEI GENERAL HOSPITAL)
View PDF 3 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
RENMIN HOSPITAL OF WUHAN UNIVERSITY (HUBEI GENERAL HOSPITAL)
Filing Date
2026-04-07
Publication Date
2026-05-05

AI Technical Summary

Technical Problem

Existing technologies suffer from low generation efficiency, suboptimal spatial distribution, insufficient sphere precision, and complex and error-prone data association issues in spatially segmented radiotherapy targets, which limit their clinical application.

Method used

Using a hexagonal close-packing method, candidate sphere center points are generated by automatically parsing medical image data. Combined with a two-level intelligent screening algorithm and pixel-level precision sphere contour generation, a standard DICOM-RT Structure file is output.

Benefits of technology

It achieves efficient and uniform target generation, ensures geometric accuracy and data correlation accuracy, improves generation efficiency and reduces human error, and supports one-click integration into existing radiotherapy workflows.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121982165A_ABST
    Figure CN121982165A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of medical image processing, in particular to a spatial segmentation radiotherapy ball target automatic generation method based on hexagonal closest packing. The method comprises the following steps: automatically loading and analyzing a medical image and structural data; reconstructing a three-dimensional target area model and calculating features of the three-dimensional target area model A candidate sphere center dot matrix is generated in the target area based on the hexagonal closest packing model, and a two-stage intelligent screening algorithm is adopted to ensure that all points are located in the contour of the target area; directly generating a high-precision sphere section contour in an image pixel coordinate system; and finally, synthesizing a standard DICOM-RT structure file which is strictly associated with the original image. According to the method, the problems of low efficiency, poor spatial distribution, insufficient sphere precision, complex and error-prone data association and the like in the prior art can be solved, so that high efficiency, distribution optimization and precision standardization of sphere target generation are realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of medical image processing technology, specifically to a method for automatically and accurately generating high-dose spherical target areas in three-dimensional medical images using computer technology and mathematical geometric models. Background Technology

[0002] Spatially Fractionated Radiotherapy (SFRT) is a cutting-edge RT technique. Its core principle lies in deliberately designing the heterogeneity of dose distribution within a large tumor volume (GTV). This involves creating a series of discrete high-dose "peaks" within the GTV, alternating with surrounding low-dose "valleys" to form a specific peak-valley dose pattern. This dose distribution has been shown to better kill tumor cells while reducing damage to surrounding normal tissues through dose fractionation, thus achieving a higher therapeutic gain ratio. One of the key steps in its implementation is creating several to dozens of discrete spherical or near-spherical structures within the GTV as "dose peaks" in the Treatment Planning System (TPS). Currently, in clinical practice, this is mainly done manually by physicists on computed tomography (CT) images, but this method has the following significant drawbacks: 1) Inefficient: The manual sketching process is extremely time-consuming, usually taking several hours per case, which severely restricts the clinical application of this technology; 2) Suboptimal spatial distribution: Manually placing the spheres is highly dependent on the operator's experience, making it difficult to achieve the theoretically optimal uniform distribution in three-dimensional space. This may result in too few dose "peaks" or overlap, affecting the final dose engraving effect and the achievement of the optimal "peak-to-valley ratio".

[0003] 3) The geometric accuracy and consistency of high-dose spherical targets are difficult to guarantee: The geometric shape (sphericity, size consistency) and spatial position accuracy of the three-dimensional spherical outline manually drawn on two-dimensional CT slices are difficult to guarantee, resulting in poor repeatability.

[0004] 4) Data association is complex and error-prone: Manually created target area structure sets must be precisely registered with the original CT image data in a three-dimensional spatial coordinate system. Manual operation may affect the matching accuracy. Summary of the Invention

[0005] The technical problem to be solved by this invention is to provide an automatic generation method for spatial segmentation radiotherapy targets based on hexagonal dense packing, so as to solve the problems of low efficiency, suboptimal spatial distribution, insufficient sphere accuracy and complex and error-prone data association in the existing technology, thereby achieving high efficiency, optimal distribution and standardized accuracy of target generation.

[0006] To solve the above-mentioned technical problems, the technical solution adopted by the present invention is as follows: An automatic generation method for spatial segmentation radiotherapy targets based on hexagonal close-packing mainly includes the following steps: S1 loads and parses DICOM standard CT image sequences and RT Structure files, extracts image metadata from the files, and establishes spatial transformation relationships from the object's original three-dimensional coordinate system to the two-dimensional pixel coordinate system of each CT image layer. S2, extract the target area structure from the RT Structure file, collect the two-dimensional contour points of the target area structure on all CT slices and assign them the corresponding Z-axis coordinates, reconstruct the three-dimensional point cloud model of the target area, and calculate the geometric centroid and three-dimensional axial bounding box of the target area. S3, Based on the hexagonal close packing method (HCP), a candidate sphere center point array is generated, and through a two-level intelligent screening algorithm and spacing consistency filtering, the sphere centers located inside the target area contour and evenly distributed in the candidate sphere center point array are screened out. S4. In the two-dimensional pixel coordinate system of CT image, for each sphere center retained after screening, calculate the intersection section between the lattice point sphere corresponding to the sphere center and each CT slice to generate a sphere two-dimensional slice outline with pixel-level precision. S5. Synthesize and output a standard DICOM-RT Structure file, which contains all spherical three-dimensional contour data associated with the original CT image sequence.

[0007] Furthermore, in step S1, the image metadata includes: image location. Image row vectors Image column vectors Pixel pitch ; The spatial transformation relationship is as follows:

[0008] in The original three-dimensional coordinate system of the object, Let be the two-dimensional pixel coordinate system after spatial transformation, and The formulas for calculating u and v are: ; .

[0009] Furthermore, in step S2, the geometric centroid The coordinates of all points in the 3D point cloud model are the arithmetic mean, and the 3D axial bounding box is... ,in , , These represent the minimum and maximum values ​​of the point cloud's X-axis coordinate, Y-axis coordinate, and Z-axis coordinate, respectively.

[0010] Furthermore, in step S3, the generation of candidate sphere center lattice based on the hexagonal close-packed method specifically includes: S31, the user inputs the lattice constant 'a' to determine the horizontal spacing between the sphere centers, and the system automatically calculates the vertical spacing according to a preset formula. ; S32, with the target area's geometric centroid Define the lattice basis vectors with the origin as the origin. , , and the offset vector of layer B relative to layer A ; S33, within the three-dimensional bounding box of the target area, traverse the integer index combinations. Generate candidate close-packed points in layer A. and B layer close packing points .

[0011] Furthermore, in step S3, the two-level intelligent screening algorithm includes: First-level rapid spatial pre-screening: Perform Delaunay triangulation on the 3D point cloud of the target area to generate the corresponding convex hull, and remove candidate sphere centers located outside the convex hull; Second-level precise contour inclusion judgment: For the candidate sphere centers that have passed the pre-screening, extract the CT slice with the nearest Z coordinate and the corresponding two-dimensional contour polygon of the target area on the slice, and project the candidate sphere centers onto the slice plane. Use the ray method to determine whether the projected point is inside the two-dimensional contour polygon, and only retain the candidate sphere centers that are determined to be inside.

[0012] Furthermore, in step S3, the spacing consistency filtering is as follows: calculate the Euclidean distance between each pair of candidate sphere centers retained by the two-level intelligent screening algorithm, and remove candidate sphere centers whose distance from the neighboring sphere center is less than 0.5a, where a is the lattice constant.

[0013] Furthermore, in step S4, generating the pixel-level precision sphere two-dimensional slice contour specifically includes: S41, Calculate the vertical distance from the center of the sphere to each CT slice plane. ,in The Z-axis coordinate of the sphere's center. The Z-axis coordinate of the slicing plane; S42, if d Smaller than the physical radius of a sphere If so, determine if the sphere intersects with the corresponding slice plane, and calculate the physical radius of the corresponding cross-sectional circle. ; S43, the projection of the sphere center onto the slice plane is transformed to the pixel coordinate system of the current slice using the spatial transformation relationship established in step S1, to obtain the pixel center coordinates. And obtain the physical radius of the cross-section circle. Pixel radius mapped in the pixel coordinate system ; S44, in the pixel coordinate system, according to the preset parametric equation Generate a discrete point set, where Uniform sampling is performed within the range of 0 to 2π to form a two-dimensional slice profile of the sphere.

[0014] Furthermore, in step S5, the synthesized standard DICOM-RT Structure file includes: S51, copy the unique identifier of the original CT image and write it into the header and corresponding data fields of the newly generated RT Structure file; S52, transform all pixel coordinate points of the sphere two-dimensional slice outline described in step S4 back to the original three-dimensional coordinate system through inverse coordinate transformation, and store it in a flattened format according to the DICOM standard format; S53 creates a complete DICOM dataset containing file metadata, object information, Study reference sequence, ROI definition sequence, and ROI contour sequence, and outputs it as a .dcm file.

[0015] Compared with the prior art, the present invention has the following main advantages: 1. This invention innovatively applies the mathematical model of hexagonal close-packed crystallography to the field of SFRT target design, breaking through the technical bottleneck of uniform arrangement of high-dose spherical targets in three-dimensional irregular target areas, so that the generated spherical centers achieve the theoretically densest and most uniform arrangement in three-dimensional space, laying the optimal geometric foundation for SFRT to achieve the ideal dose "peak and valley" distribution. 2. This invention proposes a two-level intelligent screening algorithm that combines "rapid pre-screening of Delaunay convex hull" and "precise judgment by slice-specific ray method". While efficiently completing the screening of generated points, it ensures that all generated points fall precisely inside the complex target area contour; the generation time of a single spherical target is reduced from several hours of manual operation to tens of seconds to several minutes, and the efficiency is improved by more than an order of magnitude. 3. This invention adopts a method of directly generating mathematical sphere cross-sectional contours in the image pixel coordinate system, which eliminates the error introduced by the coordinate transformation process in principle, achieves sub-pixel level geometric accuracy of the generated contours, ensures the mathematical accuracy and display consistency of all sphere contours, and avoids subjective errors and batch differences caused by manual operation. 4. This invention constructs a complete DICOM standard compatibility and automatic association guarantee mechanism, enabling the software output results to be seamlessly and error-free integrated into the existing radiotherapy workflow, achieving the application effect of "one-click generation, immediately usable", and completely eliminating the risk of manual registration errors; and relying on the fully automated target generation and data processing mechanism, it can ensure the high repeatability of output results in different scenarios. Attached Figure Description

[0016] Figure 1 This is a schematic diagram of the overall process of the automatic generation method for spatial segmentation radiotherapy targets in an embodiment of the present invention; Figure 2 This is a three-dimensional schematic diagram of the close-packed plane of a hexagonal close-packed unit cell in an embodiment of the present invention; Figure 3 This is a top view of the close-packed hexagonal unit cell in an embodiment of the present invention; Figure 4 This is a geometric diagram showing the radius of the intersection circle between the sphere and the CT slice in an embodiment of the present invention; Figure 5 This is a schematic diagram of the graphical user interface in an embodiment of the present invention.

[0017] In the diagram: 1 - Center of the close-packed plane of layer A, 2 - Center of the close-packed plane of layer B, 3 - Lattice constant, 4 - Basis vectors 5-basis vectors 6-basis vectors 7 - Cell height and perimeter c; 8 - Distance between adjacent spheres in layer AB; 9 - Centroid 10 - The intersection of the sphere and the CT slice; 11 - The radius R of the sphere; 12 - The spacing d between multi-slice CT scans. z 13 - Radius of the circle where the sphere intersects with the CT , 14-GTV high-dose spherical target. Detailed Implementation

[0018] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention. Furthermore, the technical features involved in the various embodiments of this invention described below can be combined with each other as long as they do not conflict with each other.

[0019] It should be noted that, depending on the implementation needs, the various steps / components described in this application can be broken down into more steps / components, or two or more steps / components or parts of the operation of steps / components can be combined into new steps / components to achieve the purpose of this invention.

[0020] In this invention, unless otherwise expressly specified and limited, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of that feature. In the description of this invention, "a plurality of" means at least two, such as two, three, etc., unless otherwise expressly and specifically limited.

[0021] Example 1: This example provides an automatic generation method for spatial segmentation radiotherapy target based on hexagonal close-packed (HCP) data. It automatically analyzes medical image data and then uses the hexagonal close-packed (HCP) theory to generate the optimal sphere center distribution in the three-dimensional target area. Then, it directly generates a high-precision sphere outline in the image pixel coordinate system and finally outputs a standard structure file that is strictly associated with the original data.

[0022] like Figure 1 As shown, the main steps include the following: Step S1: Automated loading and parsing of medical imaging and structural data The program first reads and parses the DICOM standard CT image sequence (including multi-slice continuous sections) and the RTStructure file (a DICOM standard structure file used to store radiotherapy-related data). It then extracts the image locations from the radiotherapy data standard file. Image row vectors Image column vectors Pixel pitch Including metadata such as layer spacing, the system establishes a three-dimensional coordinate system for objects. To the two-dimensional pixel coordinate system of each CT image layer Precise spatial transformation between:

[0023] because (Orthogonal), can be solved directly:

[0024]

[0025] This transformation relationship forms the basis for all subsequent geometric calculations.

[0026] Step S2: Target area 3D geometric model reconstruction and feature extraction The program first identifies and extracts the user-specified target area structure (e.g., GTV or GTV-10mm) from the RT Structure file. Then, it aggregates the two-dimensional contour points of this structure across all CT slices, assigns them their corresponding Z-axis coordinates, and reconstructs a three-dimensional point cloud model of the target area. Based on this point cloud, it continues to calculate the geometric centroid of the target area. (i.e., the average coordinates of all points) and the three-dimensional axial bounding box. The centroid will serve as the reference origin for subsequent lattice generation.

[0027] Step S3: Adaptive Generation and Intelligent Screening of HCP Lattices This step is one of the key innovations of this invention, aiming to adapt the mathematical theoretical model to irregular anatomical structures. The lattice model of HCP consists of hexagonal unit cells formed by close-packed atomic layers stacked in an ABAB… staggered order. Its unit cell parameters include the side length of the base rhombus, i.e., the lattice constant a, the unit cell height perimeter c, and the ideal axial ratio. The space utilization rate reaches 74.05%. Its mathematical model can be simplified to a close-packed, staggered arrangement of equal-diameter spheres in a three-dimensional space in the order ABAB… , such as… Figures 2-3 The diagram illustrates the stacking relationship between layers A and B, and the specific processing steps include: 1) HCP Model Parameterization: In this step, the HCP model is simplified to a form that can be driven by preset parameters. The user-input lattice constant 'a' determines the horizontal spacing between the sphere centers. Based on the geometry of the HCP, the vertical interlayer spacing 'c' is determined by the formula... It is calculated automatically.

[0028] 2) Lattice basis vector definition: Taking the centroid C as the origin, and the CT layer where it is located as the first A-layer close-packed layer, the program defines three basis vectors to generate other lattice points:

[0029] It also defines the offset vector for generating the interleaved layer (B layer):

[0030] 3) Adaptive lattice point generation: Taking the target centroid calculated in step two as the origin, within the three-dimensional bounding box of the target area, the system traverses all possible combinations of integer indices. (in The value range is determined by the bounding box size and lattice constant, generating candidate A-layer close-packed points. and B layer close packing points .

[0031] 4) Two-level intelligent screening mechanism: First-level rapid spatial pre-screening: The system performs Delaunay triangulation on the 3D point cloud of the target area to generate its convex hull. For each candidate lattice point, by querying whether it is located inside this convex hull, points that are obviously located outside the target area are quickly eliminated, which greatly improves computational efficiency.

[0032] The second level of precise contour inclusion determination: For points that pass the pre-screening, a more precise determination is performed to ensure that they are located inside the actual target area contour outlined clinically (and not just inside the convex hull). The algorithm finds the nearest CT slice at the point's Z-coordinate, obtains the corresponding 2D contour polygon on that slice, and projects the point onto the slice plane. The final determination of whether it is inside the contour is made using ray casting (calculating the number of intersections between horizontal rays emanating from the point and the contour polygon). Only points determined to be inside are retained.

[0033] 5) Spacing Consistency Filtering: To avoid the generated spheres being too close or overlapping, the program calculates the Euclidean distance between all pairs of lattice points that are ultimately retained, and removes those points whose distance from their neighbors is less than a preset threshold (e.g., 0.5a) to ensure uniform distribution.

[0034] Step S4: Pixel-level precision sphere contour modeling and generation To ensure the highest geometric accuracy of the generated sphere outline during display, this invention innovatively proposes generating a two-dimensional cross-section of the sphere directly in the pixel coordinate system of the CT image. Specific steps include: 1) Sphere-Plane Intersection Calculation: For each selected lattice point (as the sphere center O) and each CT slice plane, calculate the perpendicular distance from the sphere center to the plane. ,in The distance between adjacent CT slices. Let d be the number of layers between the slice plane and the layer containing the center of the sphere O. Smaller than the physical radius of a sphere If so, then the sphere intersects with this slice.

[0035] 2) Calculation of cross-sectional circle parameters: The intersecting cross-section is a circle. Its physical radius... From the formula Calculations show that, for example Figure 4 As shown.

[0036] 3) Pixel spatial contour generation: Transform the center of the circle (the projection of the sphere's center onto the slice plane) to the pixel coordinate system of the current slice using the spatial transformation relationship established in step one, to obtain the pixel center coordinates. The physical radius is determined in a similar way. Mapped to pixel radius Subsequently, in the pixel coordinate system, the discrete point set of the circle is directly generated using the parametric equation of the circle: ,in Uniform sampling is performed within the range of 0 to 2π. The contours generated by this method are perfectly aligned with the pixel grid of the CT image, achieving sub-pixel level display accuracy.

[0037] Step S5: Composition and Output of Standard DICOM-RT Structure Files To ensure the generated structures can be directly used by any commercial TPS, the program encapsulates all sphere contours as standard DICOM-RT Structure objects. Specific details include: 1) Data Association Guarantee: The program method copies key unique identifiers, such as StudyInstanceUID, FrameOfReferenceUID, and PatientID, from the original CT sequence and writes them into the header and corresponding data fields of the newly generated RTStructure file. This is the core mechanism to ensure that the file can be automatically recognized by TPS and associated with the correct CT sequence.

[0038] 2) Contour data encapsulation: All pixel coordinate contour point sets generated in step four are transformed back to the patient's three-dimensional coordinate system through inverse coordinate transformation, and then flattened and stored according to the DICOM standard format.

[0039] 3) File Generation: The program method creates a complete DICOM dataset, including file metadata, patient and study reference sequences, ROI definition sequences, and ROI contour sequences containing all spherical contours, ultimately outputting a single .dcm file. The standard DICOM-RT Structure object can be directly imported into TPS along with the original CT data for RT planning.

[0040] Example 2: This example uses a 100mm × 100mm... ×100 The cube is used as the boundary of the GTV. The center of the target sphere is determined according to the HCP vertex finding method provided in this invention, and the distance between the centers of the spheres is specified as 45. The diameter of the sphere is 15. The number of spheres in layer A within the GTV boundary is 7, and the number of spheres in layer B is 10, with a total volume of 30.04. 3 This accounts for 3% of the total volume of GTV.

[0041] Therefore, it can be seen that the present invention can efficiently and automatically generate high-dose spherical target structures with uniform distribution and high geometric accuracy.

[0042] Example 3: This example uses a target area GTV1-10mm as an example, with a volume of 4181.886. 3 The method described in this invention generates a high-dose spherical target for GTV1-10mm. The specific steps are as follows: Data input: Import the original CT image sequence of 162 layers and the RTStructure file containing the “GTV1-10mm” structure into the software system of this invention.

[0043] Parameter settings: In the software interface, set the target ROI to "GTV1-10mm" and the lattice constant. =50 , the radius of the sphere R=7.5 The output structure is named "HCP_Balls".

[0044] Automated execution: The program completes all calculations in approximately 1 minute. The process includes: parsing the data and calculating the coordinate transformation; reconstructing the target area point cloud and calculating the centroid; generating and filtering HCP lattice points to obtain the center of gravity of all spheres located within the target area; and generating the outline of a sphere for each center of gravity in pixel space. Analysis results show that GTV1-10mm is delineated on 55 consecutive CT slices, with the centroid coordinates in the corresponding coordinate system being (14.95, 35.63, -744.80). A convex hull of 846 faces was created for GTV1-10mm, and its bounding box was determined to be (-91.20, -49.30, -888.82) → (124.70, 148.50, -618.82). 3718 lattice candidate points were generated, of which 42 were quickly filtered, and 42 HCP points were ultimately retained within GTV1-10mm. Of the remaining 42 points, 18 are spheres in layer A and 24 are spheres in layer B, with a theoretical sphericity value of 1 and a total sphere volume of 74.22. 3 The high-dose target occupies 1.29% of the GTV1 volume, which meets the requirements of SFRT for the proportion of high-dose target volume.

[0045] Results Output and Verification: The program generates an RT Structure file named "HCP_Balls.dcm". This file automatically associates all key identifiers from the original CT scan. The verification module confirms successful association.

[0046] Evaluation: When the file was imported into MONACO TPS, the target structure "HCP_Balls" could be automatically registered with the CT scan. In contrast, manually drawing the same instance took approximately 5 hours, with arbitrary sphere positions, irregular shapes and heights, and sphere features primarily determined by the artist's subjective perception.

[0047] Conclusion: This embodiment demonstrates that the method of the present invention can efficiently and automatically generate high-dose spherical target structures with uniform distribution, high geometric accuracy, and perfect correlation with the original images, which is significantly better than traditional manual methods and has extremely high clinical practical value.

[0048] Example 4: Based on the same inventive concept, this example also provides an electronic device, including a memory, a processor, and a program stored in the memory and executable on the processor. When the processor executes the program, it implements the automatic generation method for spatially segmented radiotherapy targets based on hexagonal dense packing as described above.

[0049] Furthermore, the electronic device includes a graphical user interface, such as... Figure 5 As shown, the standard workflow is as follows: Users import CT and RT Structure data through the interface and set parameters such as target ROI name, lattice constant, and sphere diameter; the system automatically executes the above five steps; after processing, the system displays a preview of the generated results (including centroid location, lattice point distribution, and sphere outline overlay display) and saves the final RT Structure file to the specified location. Users can directly import this file into TPS, and the spherical target structure will be automatically registered with the CT image, realizing the intelligent delineation process of SFRT high-dose spherical targets and preparing for SFRT planning and design.

[0050] Furthermore, all parts of this application that are not described in detail are the same as or implemented using existing technology.

[0051] In summary: 1. This invention innovatively applies the mathematical model of hexagonal close-packed crystallography to the field of SFRT target design, breaking through the technical bottleneck of uniform arrangement of high-dose spherical targets in three-dimensional irregular target areas, so that the generated spherical centers achieve the theoretically densest and most uniform arrangement in three-dimensional space, laying the optimal geometric foundation for SFRT to achieve the ideal dose "peak and valley" distribution. 2. This invention proposes a two-level intelligent screening algorithm that combines "rapid pre-screening of Delaunay convex hull" and "precise judgment by slice-specific ray method". While efficiently completing the screening of generated points, it ensures that all generated points fall precisely inside the complex target area contour; the generation time of a single spherical target is reduced from several hours of manual operation to tens of seconds to several minutes, and the efficiency is improved by more than an order of magnitude. 3. This invention adopts a method of directly generating mathematical sphere cross-sectional contours in the image pixel coordinate system, which eliminates the error introduced by the coordinate transformation process in principle, achieves sub-pixel level geometric accuracy of the generated contours, ensures the mathematical accuracy and display consistency of all sphere contours, and avoids subjective errors and batch differences caused by manual operation. 4. This invention constructs a complete DICOM standard compatibility and automatic association guarantee mechanism, enabling the software output results to be seamlessly and error-free integrated into the existing radiotherapy workflow, achieving the application effect of "one-click generation, immediately usable", and completely eliminating the risk of manual registration errors; and relying on the fully automated target generation and data processing mechanism, it can ensure the high repeatability of output results in different scenarios.

[0052] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0053] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0054] Those skilled in the art will readily understand that the above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.

Claims

1. A method for automatically generating spatially segmented radiotherapy targets based on hexagonal close-packing, characterized in that, Includes the following steps: S1: Load and parse CT image sequences and radiotherapy data standard structure files that conform to preset standards, extract image metadata from the files, and establish spatial transformation relationships from the original three-dimensional coordinate system of the object to the two-dimensional pixel coordinate system of each CT image layer. S2, extract the target area structure from the radiotherapy data standard structure file, collect the two-dimensional contour points of the target area structure on all CT slices and assign them corresponding Z-axis coordinates, reconstruct the three-dimensional point cloud model of the target area, and calculate the geometric centroid and three-dimensional axial bounding box of the target area. S3, a candidate sphere center point array is generated based on the hexagonal densest packing method, and the sphere centers located inside the target area contour and evenly distributed in the candidate sphere center point array are screened out through a two-level intelligent screening algorithm and spacing consistency filtering. S4. In the two-dimensional pixel coordinate system of CT image, for each sphere center retained after screening, calculate the intersection section between the lattice point sphere corresponding to the sphere center and each CT slice to generate a sphere two-dimensional slice outline with pixel-level precision. S5. Synthesize and output the updated radiotherapy data standard structure file, which contains all spherical three-dimensional contour data associated with the original CT image sequence.

2. The method for automatically generating spatially segmented radiotherapy targets based on hexagonal close-packing as described in claim 1, characterized in that... In step S1, the image metadata includes: image location. Image row vectors Image column vectors Pixel pitch ; The spatial transformation relationship is as follows: in The original three-dimensional coordinate system of the object, Let be the two-dimensional pixel coordinate system after spatial transformation, and The formulas for calculating u and v are: ; 。 3. The method for automatically generating a spatially segmented radiotherapy target based on hexagonal close-packing as described in claim 1, characterized in that... In step S2, the geometric centroid The coordinates of all points in the 3D point cloud model are the arithmetic mean, and the 3D axial bounding box is... ,in , , These represent the minimum and maximum values ​​of the point cloud's X-axis coordinate, Y-axis coordinate, and Z-axis coordinate, respectively.

4. The method for automatically generating a spatially segmented radiotherapy target based on hexagonal close-packing as described in claim 1, characterized in that... In step S3, the generation of candidate sphere center lattice based on the hexagonal close-packed method specifically includes: S31, the user inputs the lattice constant 'a' to determine the horizontal spacing between the sphere centers, and the system automatically calculates the vertical spacing according to a preset formula. ; S32, with the target area's geometric centroid Define the lattice basis vectors with the origin as the origin. , , and the offset vector of layer B relative to layer A ; S33, within the three-dimensional bounding box of the target area, traverse the integer index combinations. Generate candidate close-packed points in layer A. and B layer close packing points .

5. The method for automatically generating spatially segmented radiotherapy targets based on hexagonal close-packing as described in claim 4, characterized in that... In step S3, the two-level intelligent screening algorithm includes: First-level rapid spatial pre-screening: Perform Delaunay triangulation on the 3D point cloud of the target area to generate the corresponding convex hull, and remove candidate sphere centers located outside the convex hull; Second-level precise contour inclusion judgment: For the candidate sphere centers that have passed the pre-screening, extract the CT slice with the nearest Z coordinate and the corresponding two-dimensional contour polygon of the target area on the slice, and project the candidate sphere centers onto the slice plane. Use the ray method to determine whether the projected point is inside the two-dimensional contour polygon, and only retain the candidate sphere centers that are determined to be inside.

6. The method for automatically generating a spatially segmented radiotherapy target based on hexagonal close-packing as described in claim 5, characterized in that... In step S3, the spacing consistency filtering is as follows: calculate the Euclidean distance between each pair of candidate sphere centers retained by the two-level intelligent screening algorithm, and remove candidate sphere centers whose distance from the neighboring sphere center is less than 0.5a, where a is the lattice constant.

7. The method for automatically generating a spatially segmented radiotherapy target based on hexagonal close-packing as described in claim 1, characterized in that... In step S4, generating the pixel-level precision 2D slice contour of the sphere specifically includes: S41, Calculate the vertical distance from the center of the sphere to each CT slice plane. ,in The Z-axis coordinate of the sphere's center. The Z-axis coordinate of the slicing plane; S42, if d Smaller than the physical radius of a sphere If so, determine if the sphere intersects with the corresponding slice plane, and calculate the physical radius of the corresponding cross-sectional circle. ; S43, the projection of the sphere center onto the slice plane is transformed to the pixel coordinate system of the current slice using the spatial transformation relationship established in step S1, to obtain the pixel center coordinates. And obtain the physical radius of the cross-section circle. Pixel radius mapped in the pixel coordinate system ; S44, in the pixel coordinate system, according to the preset parametric equation Generate a discrete point set, where Uniform sampling is performed within the range of 0 to 2π to form a two-dimensional slice profile of the sphere.

8. The method for automatically generating a spatially segmented radiotherapy target based on hexagonal close-packing as described in claim 7, characterized in that... In step S5, the synthesized and updated radiotherapy data standard structure file includes: S51, copy the unique identifier of the original CT image and write it into the header and corresponding data fields of the newly generated radiotherapy data standard structure file; S52, transform all pixel coordinate points of the sphere two-dimensional slice outline described in step S4 back to the original three-dimensional coordinate system through inverse coordinate transformation, and store it in a flattened format according to the DICOM standard format; S53 creates a complete DICOM dataset containing file metadata, object information, Study reference sequence, ROI definition sequence, and ROI contour sequence, and outputs it as a .dcm file.

9. An electronic device comprising a memory, a processor, and a program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the automatic generation method for spatial segmentation radiotherapy targets based on hexagonal dense packing as described in any one of claims 1 to 8.

10. A non-transitory readable storage medium having a program stored thereon, characterized in that, When executed by an electronic device, the program implements the automatic generation method for spatially segmented radiotherapy targets based on hexagonal dense packing as described in any one of claims 1 to 8.

Citation Information

Patent Citations

  • Method and device for confirming radiofrequency ablation path and terminal equipment

    CN112656506A

  • Space division radiotherapy target region arrangement method and system

    CN116440426A

  • Method and system for generating and optimizing lattice target region

    CN119090940A