A spinal column segmentation method, device, medium, and program product
By first coarsely locating the spinal region and then using centroid localization and Gaussian distribution for fine segmentation, the problem of long spinal segmentation time and accuracy dependence on the training set in existing technologies is solved, thus achieving efficient and accurate spinal segmentation.
Patent Information
- Application Number
- CN202411146400.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-20
- Publication Date
- 2026-01-06
- Estimated Expiration
- 2044-08-20
AI Technical Summary
In existing technologies, neural network-based spinal segmentation methods require a large number of doctors to manually draw lines, resulting in high time consumption and segmentation accuracy depending on the amount of training set sample data, making it difficult to achieve efficient and accurate segmentation of each component of the spine.
The method of first coarsely locating the spinal region and then finely segmenting it using centroid localization and Gaussian distribution is adopted to reduce the segmentation difficulty and improve the accuracy. This includes cropping the N-value mask image, locating the centroid, and performing Gaussian distribution segmentation with the centroid as the center.
It reduces the difficulty of spinal segmentation, improves segmentation accuracy and efficiency, is suitable for precise segmentation of complex spinal structures, and reduces the time doctors spend manually drawing.
Smart Images

Figure CN119006496B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of intelligent healthcare, and more specifically, to a spinal segmentation method, device, medium, and program product. Background Technology
[0002] In the medical field, medical image processing can often be used to achieve partially guided surgery, and image segmentation is the foundation for subsequent medical processing. This subsequent processing includes image segmentation, feature extraction, quantitative analysis, and 3D reconstruction based on CT images of normal or diseased tissue in chronological order. Unlike the direct segmentation of tumors in oncology, spinal surgery presents significant challenges due to the complexity of the spinal structure, which includes multiple vertebrae, pedicles, laminae, foramina, transverse processes, and spinous processes.
[0003] In existing technologies, when implementing machine learning algorithms based on neural networks, a large amount of training data is typically used to train the neural network. This means the accuracy of the neural network model directly depends on the amount of training data. To achieve effective segmentation of the various spinal components, each spinal component in the sample data is labeled with a category. However, in practice, doctors need to delineate the spinal region layer by layer from hundreds of two-dimensional images, resulting in doctors spending an average of more than half an hour delineating the spinal region for a single patient. Therefore, there is an urgent need for a spinal segmentation method that is less complex yet can guarantee accurate spinal localization and segmentation. Summary of the Invention
[0004] This invention aims to at least solve one of the technical problems existing in the prior art. To this end, this invention provides a method, device, medium, and program product for spinal segmentation; the method of this invention reduces the difficulty of segmenting the entire spine and improves the segmentation accuracy by first coarsely locating the spinal region and then finely locating different spinal bone regions for segmentation.
[0005] The first aspect of this application discloses a method for spinal segmentation, comprising:
[0006] 101. Acquire a three-dimensional CT image of the spine, and segment the three-dimensional CT image to obtain an N-value mask image of the entire vertebra.
[0007] 102. Cropping individual vertebrae from the N-value mask image of the entire vertebrae to obtain N-value mask images where adjacent individual vertebrae are not connected;
[0008] 103. Locate the centroid of a single vertebra in the N-value mask image where adjacent single vertebrae are not connected, and obtain an image of the located centroid;
[0009] 104. Using the single centroid as the center, segment the image of the single vertebra corresponding to the single centroid from the image of the located centroid.
[0010] In some embodiments, the method of cropping a single vertebral region in the N-value mask image of the entire vertebra in step 102 includes: cropping gradually from the periphery of the single vertebra towards the center; preferably, eroding proportionally from the periphery of the single vertebra towards the center;
[0011] Optionally, the volume of a single vertebra after trimming in step 102 is smaller than the volume of a single vertebra before trimming;
[0012] Preferably, the ratio of the volume of a single vertebra after cutting to the volume of a single vertebra before cutting is 1 / 10-9 / 10, more preferably 1 / 5-4 / 5, and more preferably 1 / 2;
[0013] Optionally, the coordinates of the centroid are three-dimensional coordinates.
[0014] Optionally, the N-value mask is a binary mask.
[0015] In some embodiments, the method for locating the centroid of a single vertebra in an N-value mask image that is not connected between adjacent single vertebrae in step 103 includes: using a connected component algorithm to identify at least one separate region in the N-value mask image that is not connected between adjacent single vertebrae; locating the centroid of the separate region is the centroid of the single vertebra; the separate region is the region where the single vertebra is located;
[0016] Optionally, when locating the centroid of a single vertebra in the 103, the centroids are sorted according to their z-axis coordinates.
[0017] Optionally, the method for acquiring the single vertebral image in step 104 includes:
[0018] Obtain a 3D Gaussian distribution with a fixed a×b×c centered on the single centroid;
[0019] Obtain a 3D image with a×b×c fixed at the centroid;
[0020] Based on a 3D Gaussian distribution centered on the centroid, individual vertebral images corresponding to the centroid surrounding the Gaussian distribution are segmented from the 3D image.
[0021] In some embodiments, after 101 and before 102, the method further includes: cropping the N-value mask image of the vertebra to obtain an N-value mask image containing the target vertebra;
[0022] Optionally, the method for cropping the N-value mask image of the vertebra includes: finding the maximum and minimum values of the N-value vertebral mask in three directions in the RAS three-dimensional space, and cropping out all regions in the original CT that are less than the minimum value and greater than the maximum value in the three directions, thereby obtaining an N-value mask image containing the target vertebra.
[0023] In some embodiments, the method further includes 105 after 104, identifying the category of an individual vertebra in the vertebral image based on the location of the centroid;
[0024] Optionally, when the category of a single vertebra cannot be determined according to the method in 105, the method further includes: inputting the image of the single vertebra into a classifier to identify the category of the single vertebra;
[0025] Optionally, the training method of the classifier includes: inputting a single vertebral image of a training set sample into the classifier to obtain a predicted classification result, comparing it with the classification label, and optimizing it based on the comparison result to obtain the constructed classifier;
[0026] Optionally, the classifier includes any one or more of the following: decision tree, logistic regression, Naive Bayes, neural network; preferably DenseNet among neural networks.
[0027] In some embodiments, the method after step 105 further includes step 106, synthesizing at least two individual vertebrae based on the category of the individual vertebrae to obtain a synthesized image containing the target vertebrae.
[0028] In some embodiments, after acquiring the three-dimensional CT image and before segmenting the spinal image, the method further includes: preprocessing the three-dimensional CT image to obtain a unified three-dimensional CT image; the preprocessing includes: rotating the three-dimensional CT image to the RAS direction, randomly flipping it, normalizing it, and randomly cropping it to a size of 128×128×128.
[0029] A second aspect of this application discloses a computer device, the device comprising: a memory and a processor;
[0030] The memory is used to store a computer program; the processor executes the computer program to implement the steps of the method described in the first aspect of this application.
[0031] The third aspect of this application discloses a computer-readable storage medium, characterized in that it stores a computer program thereon, which, when executed by a processor, implements the steps of the method described in the first aspect of this application.
[0032] The fourth aspect of this application discloses a computer program product, including a computer program, characterized in that, when executed by a processor, the computer program implements the steps of the method described in the first aspect of this application.
[0033] This application has the following beneficial effects:
[0034] 1. This application innovatively discloses a spinal segmentation method. Due to the complex structure of the spine, which includes vertebrae and muscles, and is composed of arranged vertebrae, each vertebra includes a vertebral body, pedicle, lamina, foramen, transverse process, spinous process, accessory process, superior articular process, and mastoid process. Therefore, segmenting spinal CT images is quite difficult. The method disclosed in this application can effectively solve the above problems. It first performs preliminary localization of the spinal region in the three-dimensional image, narrows the region, and reduces the influence of areas outside the spinal region on subsequent segmentation. By eroding the individual vertebrae in the N-value mask image of the entire vertebra, the adjacent vertebrae are not connected. Then, the connected component algorithm is used to determine the different regions where the eroded individual vertebrae are located. The centroid of the individual vertebrae in different regions is located as the centroid of the entire vertebra. A Gaussian distribution centered on the centroid is used to restrict the network to segment only the vertebrae with that centroid, achieving fine segmentation of the spine, thereby obtaining the entire spine. The above method performs bone segmentation through a three-step process of coarse localization, centroid localization, and fine segmentation, which reduces the segmentation difficulty while ensuring segmentation accuracy.
[0035] 2. This application overcomes the difficulties faced in segmenting spinal and tumor images. Unlike the direct segmentation of tumor images, the spine is a special chain structure composed of a large number of similar units, and there are significant individual differences in spinal images. Segmentation requires annotation, learning, and training under multiple views of the spine, which is a cumbersome and difficult process. This leads to problems such as the difficulty in implementing image segmentation using neural network-based machine learning algorithms. Existing technologies are unable to achieve accurate localization and segmentation of each unit that makes up the spine.
[0036] 3. The segmentation method in this application obtains spinal images with high accuracy and has low requirements for spinal sequence images, which is beneficial for large-scale clinical application. Attached Figure Description
[0037] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0038] Figure 1 This is a schematic diagram of the method flow provided in the first aspect of the present invention;
[0039] Figure 2 This is a schematic diagram of the spinal segmentation system provided in an embodiment of the present invention;
[0040] Figure 3 This is a schematic diagram of a computer device provided in an embodiment of the present invention;
[0041] Figure 4 This is a schematic diagram of the architecture of an exemplary computing device provided in an embodiment of the present invention;
[0042] Figure 5 This is a schematic diagram of the storage medium provided in an embodiment of the present invention;
[0043] Figure 6 This is a flowchart of the segmentation method (three-step method: first coarse positioning, then centroid positioning, and finally fine segmentation) provided in this embodiment of the invention; a is coarsely segmented and output as b; b is cropped and output as its corresponding 3D CT image c; c is segmented and output as d; the centroid of each individual vertebra in d is identified and output as e; each individual vertebra is cropped with the centroid as the center to obtain image column f; image column f is ID-identified to identify the class of each individual vertebra (image column g); and image column g is synthesized to obtain image h;
[0044] Figure 7 This is a schematic diagram of the coarse segmentation process (segmenting the input 3D CT image into a 3D binary mask image) in the three-step method provided in this embodiment of the invention; A is the input 3D CT image, B is the output 3D binary mask image; A is processed by the Segrenet segmentation network to output result B;
[0045] Figure 8 This invention provides a method to divide an input, edge-cropped 3D CT image into a 3D binary mask image containing only vertebrae and with no connection between adjacent vertebrae; A is the input, edge-cropped 3D CT image, and B is the output 3D binary mask image whose volume has been reduced by half and contains only vertebrae; A is processed by the Segrenet segmentation network to output result B;
[0046] Figure 9 This is a schematic flowchart of a method for acquiring an image of a single vertebra corresponding to a single centroid, provided in an embodiment of the present invention; A is the input 3D Gaussian distribution with the vertebral body fixed at 224x224x128, B is the input cropped 3D CT image with the vertebral body fixed at 224x224x128, and C is the output 3D binary mask image of the vertebral body; A and B are processed by the Segrenet segmentation network to output result C;
[0047] Figure 10This is a flowchart of a method for identifying the category of a single vertebra in a vertebral image based on the position of the centroid, provided by an embodiment of the present invention; the left side is the input 224x224x128 cropped 3D CT image centered on the vertebral body, which is output as the position label class of the vertebral body after passing through the DenseNet classification network. Detailed Implementation
[0048] To enable those skilled in the art to better understand the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings.
[0049] In some of the processes described in the specification, claims, and accompanying drawings of this invention, multiple operations appearing in a specific order are included. However, it should be clearly understood that these operations may not be executed in the order they appear herein, or may be executed in parallel. The operation numbers, such as 101, 102, etc., are merely used to distinguish different operations and do not represent any execution order. Furthermore, these processes may include more or fewer operations, and these operations may be executed sequentially or in parallel. It should be noted that the descriptions such as "first," "second," etc., in this document are used to distinguish different messages, devices, modules, etc., and do not represent a sequential order, nor do they limit "first" and "second" to different types.
[0050] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0051] Figure 1 This is a schematic flowchart of a spinal segmentation method provided by an embodiment of the present invention. Specifically, the method includes the following steps:
[0052] 101: Acquire a three-dimensional CT image of the spine, and segment the three-dimensional CT image to obtain an N-value mask image of the entire vertebra;
[0053] In some embodiments, the input image size is much larger than the spinal region during spinal segmentation, and given the high similarity between vertebrae, directly segmenting individual vertebrae within each spine is challenging. To improve segmentation accuracy, this application employs a method of first coarsely locating the spinal region and then finely segmenting the individual spinal units to achieve precise spinal segmentation. Specifically, the spinal images in the 3D CT images are binary, meaning that the differences between spinal units are not distinguished in the coarse localization step; the entire spine is treated as a single label. After segmentation, a "preserve maximum connected components" post-processing operation is added; this post-processing helps reduce interference from the skull, etc. The purpose of coarse localization is to find the maximum and minimum values within the binary region. In this step, image impurities significantly affect the cropping in the fine segmentation step; however, if a portion of the image is missing in the coarse localization step, its impact on the cropping in the fine segmentation step is relatively small. In this application, the entire vertebra refers to the human spine, including all the arranged vertebrae.
[0054] In some embodiments, the N-value mask is a binary mask. When it is a binary mask, segmenting the three-dimensional CT image in 101 yields a binary mask image containing the entire vertebrae or any one of the cervical, thoracic, or lumbar vertebrae. When it is a quaternary mask, segmenting the three-dimensional CT image in 101 yields a quaternary mask image containing all the cervical, thoracic, and lumbar vertebrae.
[0055] In some embodiments, after step 101 and before step 102, the method further includes: cropping the N-value mask image of the vertebrae to obtain an N-value mask image containing the target vertebrae; optionally, the target vertebrae are vertebrae that need to be displayed as required, including any one or more of the following: cervical vertebrae, thoracic vertebrae, lumbar vertebrae, and the entire vertebral column; specifically, the method for cropping the N-value mask image of the vertebrae includes: finding the maximum and minimum values of the N-value vertebral mask in three directions in the RAS three-dimensional space, and cropping out all areas in the original CT that are less than the minimum value and greater than the maximum value in the three directions, thereby obtaining an N-value mask image containing the target vertebrae.
[0056] 102: Cropping individual vertebrae from the N-value mask image of the entire vertebrae to obtain N-value mask images where adjacent individual vertebrae are not connected;
[0057] In some embodiments, the method of cropping a single vertebral region in the N-value mask image of the entire vertebra in step 102 includes: cropping gradually from the periphery of the single vertebra towards the center; preferably, eroding proportionally from the periphery of the single vertebra towards the center;
[0058] Optionally, the volume of a single vertebra after trimming in step 102 is smaller than the volume of a single vertebra before trimming;
[0059] Preferably, the ratio of the volume of a single vertebra after trimming to the volume of a single vertebra before trimming is 1 / 10-9 / 10, more preferably 1 / 5-4 / 5, and most preferably 1 / 2. The reason for trimming individual vertebrae is that if the original size of the vertebrae is predicted, there is a high probability that the vertebrae will be connected. If they are connected, the connected component algorithm will not be able to distinguish them in the next step. The trimming erosion in this application changes the size of the vertebrae to prevent them from connecting. The erosion algorithm erodes each vertebra, retaining half of its volume (since two half-vertebrae cannot be connected together, the half-vertebrae are not eroded). By predicting vertebrae with only half the volume, it is ensured that the vertebrae are not connected. Then, the connected component algorithm is used to obtain the centroid of each vertebra, using the centroid of the vertebra as the centroid of the entire vertebrae. Although the preferred ratio is 1 / 2, in actual operation, the trimming ratio is adjusted according to the shape of the subject's spine, as long as it can ensure that adjacent vertebrae are not connected.
[0060] In some embodiments, the pruning process is trained using an erosion algorithm during the training phase to obtain the region of a single cone.
[0061] 103. Locate the centroid of a single vertebra in the N-value mask image where adjacent single vertebrae are not connected, and obtain an image of the located centroid;
[0062] In some embodiments, the method for locating the centroid of a single vertebra in an N-value mask image that is not connected between adjacent single vertebrae in step 103 includes: using a connected component algorithm to identify at least one individual region in the N-value mask image that is not connected between adjacent single vertebrae; locating the centroid of the individual region is the centroid of the single vertebra; the individual region is the region where the single vertebra is located; first locating different regions, and then finding the centroid of different regions.
[0063] Optionally, when locating the centroid of a single vertebra in step 103, the centroids are sorted according to their z-axis coordinates. This is because the sub-regions obtained through the connected component algorithm are disordered; therefore, the centroids are identified after sorting based on their z-axis centroid coordinates.
[0064] In some embodiments, the coordinates of the centroid are three-dimensional coordinates, and the centroid serves to trim individual vertebrae and Gaussian distributions to segment the spine.
[0065] In some embodiments, the centroid of a single vertebra is the centroid of a single vertebra, and the vertebral column contains 24 vertebrae, that is, it contains 24 centroids.
[0066] 104: Using a single centroid as the center, segment the image of a single vertebra corresponding to the single centroid from the image of the located centroid;
[0067] In some embodiments, the method for acquiring the single vertebral image in 104 includes:
[0068] Obtain a 3D Gaussian distribution with a fixed a×b×c centered on the single centroid; the values of a / b / c need to satisfy the following condition: since a / b / c is a hyperparameter, it needs to be a multiple of 16;
[0069] Obtain a 3D image with a fixed a×b×c axis centered on the centroid; the values of a / b / c need to meet the following conditions: since a / b / c is a hyperparameter, it needs to be a multiple of 16; and since it needs to be used to crop a single vertebra, the cropping area must contain the complete vertebra. The larger the area, the greater the interference. Therefore, it should be as small as possible while ensuring coverage of the entire vertebral body, preferably 224×224×128, but its specific value can vary.
[0070] Based on a 3D Gaussian distribution centered on the centroid, individual vertebral images corresponding to the centroid surrounding the Gaussian distribution are segmented from the 3D image. The 3D Gaussian distribution and the 3D image are input together, with Gaussian distribution used for localization, and only the vertebral mask around the Gaussian distribution is segmented.
[0071] In some embodiments, the method after step 104 further includes step 105, identifying the category of a single vertebra in the vertebral image based on the position of the centroid, wherein the ID and vertebral number are in one-to-one correspondence, such as 1 representing T1 and 2 representing T2, which are pre-defined;
[0072] Optionally, when the category of a single vertebra cannot be determined according to the method in 105, the method further includes: inputting the image of the single vertebra into a classifier to identify the category of the single vertebra;
[0073] Optionally, the training method of the classifier includes: inputting a single vertebral image of a training set sample into the classifier to obtain a predicted classification result, comparing it with the classification label, and optimizing it based on the comparison result to obtain the constructed classifier;
[0074] Optionally, the classifier includes any one or more of the following: decision tree, logistic regression, Naive Bayes, neural network; preferably DenseNet among neural networks.
[0075] Specifically, the smallest three-dimensional bounding box of the binary spinal region in the spinal image in 101 is input into the step of fine segmentation of each unit of the spinal column. At this time, each vertebra represents a label, and after the segmentation is complete, the spine that distinguishes each vertebra is formed.
[0076] The principle of the minimum 3D bounding box is as follows:
[0077] inds={(i,j,k)∣data[i][j][k]=1}
[0078] x1 = min(inds[0])
[0079] x2 = max(inds[0])
[0080] y1 = min(inds[1])
[0081] y2 = max(inds[1])
[0082] z1 = min(inds[1])
[0083] z2 = max(inds[1])
[0084] crop_data=data[x1:x2,y1:y2,z1:z2]
[0085] Here, x1, x2, y1, y2, z1, and z2 are integer indices used to define the start and end positions of the clipping region. Specifically: x1 and x2 define the start and end indices for clipping in the first dimension (usually corresponding to length). y1 and y2 define the start and end indices for clipping in the second dimension (usually corresponding to width). z1 and z2 define the start and end indices for clipping in the third dimension (usually corresponding to height).
[0086] In some embodiments, the method after step 105 further includes step 106, synthesizing at least two individual vertebrae based on the category of the individual vertebrae to obtain a synthesized image containing the target vertebra.
[0087] In some embodiments, after acquiring the three-dimensional CT image and before segmenting the spinal image, the method further includes: preprocessing the three-dimensional CT image to obtain a unified three-dimensional CT image; the preprocessing includes: rotating the three-dimensional CT image to the RAS direction, randomly flipping it, normalizing it, and randomly cropping it to a size of 128×128×128.
[0088] Figure 3 This is a schematic diagram of a computer device provided in an embodiment of the present invention, such as... Figure 3 As shown, the device may include: one or more processors and one or more memories; wherein the memories store computer-readable code that, when run by the one or more processors, can perform the methods described above.
[0089] The processor in this embodiment can be an integrated circuit chip with signal processing capabilities. The processor can be a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. It can implement or execute the methods, operations, and logic block diagrams disclosed in this embodiment. The general-purpose processor can be a microprocessor or any conventional processor, and can be based on an x86 or ARM architecture.
[0090] In general, the various exemplary embodiments of this disclosure can be implemented in hardware or dedicated circuitry, software, firmware, logic, or any combination thereof. Some aspects can be implemented in hardware, while others can be implemented in firmware or software that can be executed by a controller, microprocessor, or other computing device. When aspects of embodiments of this disclosure are illustrated or described as block diagrams, flowcharts, or using some other graphical representation, it will be understood that the blocks, apparatuses, systems, techniques, or methods described herein can be implemented as non-limiting examples in hardware, software, firmware, dedicated circuitry or logic, general-purpose hardware or controllers or other computing devices, or some combination thereof.
[0091] For example, the method or apparatus according to embodiments of this disclosure can also be used by means of Figure 4 The architecture of the computing device 3000 shown is used for implementation. For example... Figure 4 As shown, the computing device 3000 may include a bus 3010, one or more CPUs 3020, a read-only memory (ROM) 3030, a random access memory (RAM) 3040, a communication port 3050 connected to a network, an input / output component 3060, a hard disk 3070, etc. The storage devices in the computing device 3000, such as the ROM 3030 or the hard disk 3070, may store various data or files used for processing and / or communication of the methods provided in this disclosure, as well as program instructions executed by the CPU. The computing device 3000 may also include a user interface 3080. Of course, Figure 4 The architecture shown is merely exemplary and can be omitted as needed when implementing different devices. Figure 4 One or more components in the computing device shown.
[0092] This invention also includes a computer-readable storage medium, such as... Figure 5The diagram illustrates a storage medium provided in an embodiment of the present invention. The computer storage medium 4020 stores computer-readable instructions 4010. When the computer-readable instructions 4010 are executed by a processor, the method described above according to embodiments of the present disclosure can be performed. The computer-readable storage medium in the embodiments of the present disclosure can be volatile memory or non-volatile memory, or may include both volatile and non-volatile memory. Non-volatile memory can be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), or flash memory. Volatile memory can be random access memory (RAM), which is used as an external cache. By way of example, but not limitation, many forms of RAM are available, such as Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), Synchronous Dynamic Random Access Memory (SDRAM), Double Data Rate Synchronous Dynamic Random Access Memory (DDRSDRAM), Enhanced Synchronous Dynamic Random Access Memory (ESDRAM), Synchronous Link Dynamic Random Access Memory (SLDRAM), and Direct Memory Bus Random Access Memory (DR RAM). It should be noted that the memory used in the methods described herein is intended to include, but is not limited to, these and any other suitable types of memory.
[0093] This disclosure also provides a computer program product or system that, when executed by a processor, implements the steps of the above-described method.
[0094] This embodiment discloses a spinal segmentation system, such as Figure 2 As shown, the system includes:
[0095] The image coarse segmentation module 201 is used to acquire a three-dimensional CT image of the spine and segment the three-dimensional CT image to obtain an N-value mask image of the entire vertebra.
[0096] The cropping processing module 202 is used to crop individual vertebrae from the N-value mask image of the entire vertebrae to obtain N-value mask images that are not connected between adjacent individual vertebrae.
[0097] Centroid localization module 203 is used to locate the centroid of a single vertebra in an N-value mask image where adjacent single vertebrae are not connected, and to obtain an image of the located centroid;
[0098] Vertebrae segmentation module 204 is used to segment a single vertebrae image corresponding to a single centroid from the image of the pre-positioned centroid, with the single centroid as the center.
[0099] In some embodiments, after the vertebral segmentation module, the system further includes: a vertebral recognition module, used to identify the category of a single vertebra in the vertebral image based on the position of the centroid; optionally, when the category of a single vertebra cannot be determined according to the method of the vertebral recognition module, the method further includes: inputting the single vertebral image into a classifier to identify the category of the single vertebra;
[0100] In some embodiments, after the vertebral recognition module, the system further includes a vertebral synthesis module, configured to synthesize at least two individual vertebrae based on the category of the individual vertebrae, to obtain a synthesized image containing the target vertebra.
[0101] Example: Segmentation based on preoperative CT images of patients
[0102] The spine was segmented using the deep learning method swinunetr, and good segmentation results were obtained after training. Swin UNetR combines the context modeling capability of Swin Transformer and the pixel-level prediction capability of U-Net to improve the performance of semantic segmentation tasks.
[0103] 1) Labeled dataset
[0104] Mainstream deep learning-based segmentation methods require large datasets for training to generalize the model's capabilities. The first step is to have doctors label the cervical, thoracic, and lumbar vertebrae.
[0105] 2) Deep learning algorithm training
[0106] Currently, the U-shaped architecture in medical image segmentation within the CNN field has achieved state-of-the-art performance benchmarks, such as the U-Net model. Swinunetr, also based on a U-shaped architecture, includes a decoder and encoder. We know that transformer models have shown excellent ability to capture stochastic information from multiple domains, including natural language processing and computer vision. However, convolutional layers have limited kernel size, resulting in less than ideal performance in modeling long-range information. Inspired by this, Swinunetr's encoder employs transformers. This architectural design improves the algorithm's ability to capture information while reducing its computational complexity.
[0107] 3) Implementation details
[0108] Rotate the data to the RAS direction;
[0109] Randomly flip the data;
[0110] Normalize the data;
[0111] The data was randomly cropped to a size of 128x128x128;
[0112] Preprocessing before segmentation, unifying the orientation, and constraining the data within a certain range (images have different coordinate systems) leads to image unification and better results in subsequent segmentation.
[0113] Specifically as attached Figure 6 The diagram shown is a flowchart of the segmentation method provided in an embodiment of the present invention. Figure 6 After splitting into Figure 7 , 8 9, 10; During segmentation, binary segmentation can be performed first (to coarsely locate the spinal region and narrow down the area), followed by multi-value segmentation, such as 25-value segmentation; alternatively, four-value segmentation can be performed first (to coarsely locate the cervical, thoracic, and lumbar spine regions, using segmentation algorithms to initially locate the thoracic and lumbar vertebrae, reducing the impact of images outside the thoracic and lumbar vertebrae on subsequent segmentation results), followed by N-value segmentation for each of the three different regions; a centroid localization step can also be added between coarse localization and fine segmentation. The centroid can represent a single vertebra that makes up the spine, since the vertebral bodies are not connected to each other, so the pedicles are discarded during segmentation. For the location, the remaining vertebral body can be directly located. If adjacent vertebrae are connected, an erosion algorithm or other algorithm is needed to peel away the connected vertebrae, making them disconnected. After locating multiple centroids (centroids are spatial points with three-dimensional coordinates), when locating a single vertebra based on the centroids, the influence magnitude is unknown, so the image may be too large or too small during cropping. For large images, the 3D CT image is segmented into individual vertebral images based on the 3D Gaussian distribution of a single centroid, thus completing the cutting of the spine. If the spine is incomplete and it is impossible to determine the specific vertebra or vertebral body, a classifier needs to be introduced to pre-learn the shape of each vertebra in the training set samples, and then trained.
[0114] It should be noted that the flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this disclosure. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0115] In general, the various exemplary embodiments of this disclosure can be implemented in hardware or dedicated circuitry, software, firmware, logic, or any combination thereof. Some aspects can be implemented in hardware, while others can be implemented in firmware or software that can be executed by a controller, microprocessor, or other computing device. When aspects of embodiments of this disclosure are illustrated or described as block diagrams, flowcharts, or using some other graphical representation, it will be understood that the blocks, apparatuses, systems, techniques, or methods described herein can be implemented as non-limiting examples in hardware, software, firmware, dedicated circuitry or logic, general-purpose hardware or controllers or other computing devices, or some combination thereof.
[0116] 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.
[0117] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only 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. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection between apparatuses or units through some interfaces, and may be electrical, mechanical, or other forms.
[0118] 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 can be selected to achieve the purpose of this embodiment according to actual needs.
[0119] Furthermore, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0120] The exemplary embodiments of this disclosure described in detail above are merely illustrative and not restrictive. Those skilled in the art will understand that various modifications and combinations can be made to these embodiments or their features without departing from the principles and spirit of this disclosure, and such modifications should fall within the scope of this disclosure.
Claims
1. A method for spinal segmentation, characterized in that, The method comprises: 101, obtaining a three-dimensional CT image of a spine, and segmenting the three-dimensional CT image to obtain an N-value mask image of the entire spine; 102, cropping a single vertebral body in the N-value mask image of the entire spine to obtain an N-value mask image in which adjacent single vertebral bodies are not connected; the cropping method comprises gradually cropping from the four peripheral edges of the single vertebral body to the center; 103, using a connected domain algorithm to identify at least one single region in the N-value mask image in which adjacent single vertebral bodies are not connected; locating the centroid of the single region is locating the centroid of the single vertebral body, to obtain an image in which the centroid has been located; the single region is a region in which a single vertebral body is located; 104, segmenting a single vertebral body image corresponding to a single centroid from the image in which the centroid has been located, with the single centroid as the center.
2. The spinal column partitioning method of claim 1, wherein, The cropping method is to erode the single vertebral body from the four peripheral edges to the center at a constant ratio.
3. The spinal column partitioning method of claim 1, wherein, The volume of the single vertebral body after cropping is smaller than the volume of the single vertebral body before cropping.
4. The spinal column segmentation method of claim 3, wherein, The ratio of the volume of the single vertebral body after cropping to the volume of the single vertebral body before cropping is 1 / 10-9 / 10.
5. The spinal column partitioning method of claim 4, wherein, The ratio of the volume of the single vertebral body after cropping to the volume of the single vertebral body before cropping is 1 / 5-4 / 5.
6. The spinal column partitioning method of claim 4, wherein, The ratio of the volume of the single vertebral body after cropping to the volume of the single vertebral body before cropping is 1 / 2.
7. The spinal column partitioning method of claim 1, wherein, The coordinates of the centroid are three-dimensional coordinates.
8. The spinal column partitioning method of claim 1, wherein, The N-value mask is a binary mask.
9. The spinal column partitioning method of claim 1, wherein, When locating the centroid of the single vertebral body in 103, the z-axis coordinates of the centroid are sorted.
10. The spinal column partitioning method of claim 1, wherein, The method for obtaining the single vertebral body image in 104 comprises: Obtaining a 3D Gaussian distribution fixed at a×b×c with the single centroid as the center; Obtaining a 3D image fixed at a×b×c with the centroid as the center; Segmenting a single vertebral body image corresponding to the centroid from the 3D image according to the 3D Gaussian distribution with the centroid as the center.
11. The spinal column partitioning method of claim 1, wherein, Before 102 after 101, the method further comprises: cropping the N-value mask image of the spine to obtain an N-value mask image containing a target vertebral body; The method for cropping the N-value mask image of the spine comprises: finding the maximum and minimum values of the N-value mask of the spine in the three directions of the RAS three-dimensional space, and cropping all regions in the original CT that are smaller than the minimum value and larger than the maximum value in the three directions, thereby obtaining an N-value mask image containing a target vertebral body.
12. The spinal column segmentation method of claim 11, wherein, The target vertebral body is a vertebral body that needs to be displayed according to requirements.
13. The spinal column partitioning method according to any one of claims 1 to 12, characterized in that, After 104, the method further comprises 105, identifying the category of a single vertebral body in the vertebral body image based on the position of the centroid.
14. The spinal column segmentation method of claim 13, wherein, When the category of a single vertebral body cannot be determined according to the method in 105, the method further comprises: inputting the single vertebral body image into a classifier to identify the category of the single vertebral body.
15. The spinal column segmentation method of claim 14, wherein, The classifier comprises any one or several of the following: decision tree, logistic regression, naive Bayes, neural network.
16. The spinal column segmentation method of claim 15, wherein, The classifier is DenseNet in the neural network.
17. The spinal column segmentation method of claim 13, wherein, After 105, the method further comprises 106, synthesizing at least two single vertebral bodies based on the category of the single vertebral body, to obtain a synthesized image containing a target vertebral body.
18. The spinal column partitioning method of claim 1, wherein, Before the vertebra image is segmented from the three-dimensional CT image obtained in the step 101, the method further comprises: pre-processing the three-dimensional CT image to obtain a unified three-dimensional CT image; the pre-processing comprises: rotating the three-dimensional CT image to RAS direction, randomly flipping, normalizing, and randomly cutting to 128*128*128.
19. A computer device, comprising: The device comprises a memory and a processor; the memory is used to store a computer program; the processor executes the computer program to implement the steps of the method according to any one of claims 1-18.
20. A computer-readable storage medium, characterized in that, A computer program is stored thereon, and the computer program is executed by a processor to implement the steps of the method according to any one of claims 1-18.
21. A computer program product comprising a computer program, characterized in that, The computer program is executed by a processor to implement the steps of the method according to any one of claims 1-18. The computer program is executed by a processor to implement the steps of the method according to any one of claims 1-18.
Citation Information
Patent Citations
3D multi-vertebra segmentation method based on cascade convolution neural network
CN109493317A
Bone mass recognition method and system based on three-dimensional convolutional neural network and CT image
CN116416428A
Spine image segmentation identification method, device and equipment
CN117350932A