Medical Image Segmentation Method and Device Based on Hierarchical Shape Prior Enhanced ResUNet Model
By introducing a hierarchical shape prior module and a comprehensive loss function in ResUNet model, the problem of low contrast between the target structure and surrounding tissue and complex pathological tissue morphology in medical image segmentation is solved, and the segmentation effect is achieved with high accuracy and high efficiency.
Patent Information
- Application Number
- CN202510042020.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-10
- Publication Date
- 2025-07-01
- Estimated Expiration
- 2045-01-10
AI Technical Summary
The prior art is difficult to accurately deal with scenes in which the target structure has low contrast with surrounding tissue and highly fuzzy pathological tissue morphology and location in medical image segmentation.
The ResUNet model based on hierarchical shape prior enhancement is adopted to realize the layer-by-layer transfer and update of shape priors through the three-layer shape prior module, and DiceLoss, Cross-EntropyLoss and BoundaryDoU loss functions are introduced for the use of comprehensive loss functions.
It improves the accuracy and training efficiency of medical image segmentation, especially when processing images with high detail, low contrast and complex morphology, it can achieve high segmentation accuracy.
Smart Images

Figure CN119477943B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of medical image segmentation, and particularly to a medical image segmentation method and device based on a hierarchical shape prior enhanced ResUNet model. Background Art
[0002] Medical images refer to images that reflect the internal structure of the human body taken by various imaging technologies such as X-ray imaging, Computed Tomography (CT), Computed Tomography Angiography (CTA), and Magnetic Resonance Imaging (MRI), which provide important assistance for modern medicine.
[0003] Medical image segmentation refers to dividing an image into several regions according to the similarity and dissimilarity between regions in a medical image; it also refers to extracting a specific region of interest based on the different imaging brightness of the target organ, tissue, and cell. The segmentation results can be applied to aspects such as clinical disease diagnosis, medical image visualization, treatment plan planning, and treatment effect evaluation.
[0004] Using manually annotated medical images for segmentation is one of the most traditional methods. It requires medical professionals to manually draw or mark different regions in the segmented image, which requires trained professionals and has a high labor cost when dealing with high-resolution images such as multi-layer CT or MAI images. When concentrating on manual operations for a long time, it is also easy to cause annotator fatigue, thereby increasing the possibility of errors. At the same time, for regions with complex structures or unclear boundaries due to low contrast, manual annotation may not be able to fully capture the tiny or complex details in medical images. The various limitations of manual annotation have promoted the development of automated medical image segmentation using computers.
[0005] The earliest automated medical image segmentation methods included edge detection and threshold segmentation using various operators, as well as combining machine learning techniques with traditional image processing. Subsequently, deep learning techniques, especially Convolutional Neural Network (CNN), were introduced and quickly popularized. Among them, the UNet model and its variants became mainstream, and ResUNet, which introduced residual connections into the UNet model, effectively alleviated the problem of gradient disappearance during the training process of neural networks and stood out among a variety of variant models, achieving excellent results in multiple segmentation challenges. However, the ResUNet model still has inherent limitations in capturing global context information and is difficult to achieve satisfactory results when dealing with low contrast between the target structure and surrounding tissues, as well as highly ambiguous morphology and position of pathological tissues.
[0006] In the prior art, there is a lack of an accurate and efficient 3D medical image segmentation method based on a hierarchical shape prior enhanced ResUNet model. Summary of the Invention
[0007] In order to solve the technical problems of the medical image segmentation problem in the prior art, where the contrast between the target structure and the surrounding tissues is low, and the morphology and position of the pathological tissues are highly ambiguous and uncertain, the embodiments of the present invention provide a medical image segmentation method and device based on a hierarchical shape prior enhanced ResUNet model. The technical solutions are as follows:
[0008] On the one hand, a medical image segmentation method based on a hierarchical shape prior enhanced ResUNet model is provided. This method is implemented by a medical image segmentation device, and the method includes:
[0009] Obtain an initial 3D medical image; based on preset processing parameters, perform data processing on the initial 3D medical image to obtain a training 3D medical image;
[0010] Construct a medical image segmentation model based on the ResUnet model structure; the medical image segmentation model is a hierarchical shape prior enhanced ResUNet model;
[0011] Input the training 3D medical image into the medical image segmentation model for image segmentation prediction training to obtain a 3D segmentation image;
[0012] Construct a loss function according to the characteristics of the preset 3D medical image; based on the loss function, calculate according to the preset labeled 3D medical image and the 3D segmentation image to obtain the model segmentation loss; the loss function includes a Dice loss function, a cross-entropy loss function, and a BoundaryDoU loss function;
[0013] Optimize the parameters of the medical image segmentation model according to the model segmentation loss to obtain an optimized image segmentation model;
[0014] Obtain a 3D medical image to be segmented; perform image segmentation on the 3D medical image to be segmented through the optimized image segmentation model.
[0015] On the other hand, a medical image segmentation device based on a hierarchical shape prior enhanced ResUNet model is provided. This device is applied to the medical image segmentation method based on a hierarchical shape prior enhanced ResUNet model, and the device includes:
[0016] An image processing module, configured to obtain an initial 3D medical image; based on preset processing parameters, perform data processing on the initial 3D medical image to obtain a training 3D medical image;
[0017] A model construction module, configured to construct a medical image segmentation model based on the ResUnet model structure; the medical image segmentation model is a prior-enhanced ResUNet model based on hierarchical shapes.
[0018] A model training module, configured to input the training 3D medical image into the medical image segmentation model for image segmentation prediction training to obtain a 3D segmentation image.
[0019] A loss calculation module, configured to construct a loss function according to the characteristics of the preset 3D medical image; based on the loss function, calculate according to the preset labeled 3D medical image and the 3D segmentation image to obtain a model segmentation loss; the loss function includes a Dice loss function, a cross-entropy loss function, and a BoundaryDoU loss function.
[0020] A model optimization module, configured to optimize the parameters of the medical image segmentation model according to the model segmentation loss to obtain an optimized image segmentation model.
[0021] An image segmentation module, configured to obtain a 3D medical image to be segmented; perform image segmentation on the 3D medical image to be segmented through the optimized image segmentation model.
[0022] On the other hand, a medical image segmentation device is provided, and the medical image segmentation device includes: a processor; a memory, and a computer-readable instruction is stored on the memory, and when the computer-readable instruction is executed by the processor, any one of the medical image segmentation methods based on the prior-enhanced ResUNet model with hierarchical shapes as described above is implemented.
[0023] On the other hand, a computer-readable storage medium is provided, and at least one instruction is stored in the storage medium, and the at least one instruction is loaded and executed by a processor to implement any one of the medical image segmentation methods based on the prior-enhanced ResUNet model with hierarchical shapes as described above.
[0024] The beneficial effects brought by the technical solutions provided in the embodiments of the present invention at least include:
[0025] The present invention provides a medical image segmentation method based on a hierarchical shape prior enhanced ResUNet model; the hierarchical shape prior module composed of three layers of shape prior modules realizes the layer-by-layer transfer and update of the shape prior, enhancing the model's comprehensive understanding of medical images; a combined loss function composed of DiceLoss, Cross-EntropyLoss, etc. is introduced to achieve balanced learning of the detailed features and overall structure of medical images, and ensure that the model has high training efficiency while having accurate segmentation accuracy in the face of complex medical image segmentation scenarios such as high-detail, low contrast between the segmentation target and surrounding tissues, and variable morphological positions of diseased organs. The present invention has good portability. The present invention enhances the skip connection part of the ResUNet model without modifying the encoder and decoder of the ResUNet model, so the present invention can be applied to variant models of other UNet models, with high flexibility and practicality. The present invention is an accurate and efficient 3D medical image segmentation method based on a hierarchical shape prior enhanced ResUNet model. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] To more clearly illustrate the technical solutions in the embodiments of the present invention, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the following drawings are only some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can be obtained based on these drawings.
[0027] Figure 1 It is a flowchart of a medical image segmentation method based on a hierarchical shape prior enhanced ResUNet model provided by an embodiment of the present invention;
[0028] Figure 2 It is a schematic diagram of the overall structure of a hierarchical shape prior enhanced ResUNet model provided by an embodiment of the present invention;
[0029] Figure 3 It is a schematic diagram of the structure of a self-update module provided by an embodiment of the present invention;
[0030] Figure 4 It is a schematic diagram of the overall structure of a cross-update module provided by an embodiment of the present invention;
[0031] Figure 5 It is a block diagram of a medical image segmentation device based on a hierarchical shape prior enhanced ResUNet model provided by an embodiment of the present invention;
[0032] Figure 6 It is a schematic diagram of the structure of a medical image segmentation device provided by an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0033] The technical solutions in the present invention will be described below with reference to the accompanying drawings.
[0034] In the embodiments of the present invention, words such as "exemplarily" and "for example" are used to represent examples, illustrations or explanations. Any embodiment or design solution described as an "example" in the present invention should not be construed as being more preferred or having more advantages than other embodiments or design solutions. Rather, the use of the word "example" is intended to present concepts in a specific manner. In addition, in the embodiments of the present invention, the meaning expressed by "and / or" can be both, or either one of the two.
[0035] In the embodiments of the present invention, "image" and "picture" can sometimes be used interchangeably. It should be noted that when the difference is not emphasized, the meanings they express are the same. "(of)", "corresponding", and "corresponding" can sometimes be used interchangeably. It should be noted that when the difference is not emphasized, the meanings they express are the same.
[0036] In the embodiments of the present invention, sometimes a subscript such as W1 may be written in a non-subscript form such as W1. When the difference is not emphasized, the meanings they express are the same.
[0037] To make the technical problems, technical solutions and advantages to be solved by the present invention clearer, the following will be described in detail with reference to the accompanying drawings and specific embodiments.
[0038] The embodiments of the present invention provide a medical image segmentation method based on a hierarchical shape prior enhanced ResUNet model. This method can be implemented by a medical image segmentation device, and the medical image segmentation device can be a terminal or a server. As Figure 1 shown in the flowchart of the medical image segmentation method based on the hierarchical shape prior enhanced ResUNet model, the processing flow of this method can include the following steps:
[0039] S1. Obtain an initial 3D medical image; based on preset processing parameters, perform data processing on the initial 3D medical image to obtain a training 3D medical image.
[0040] Optionally, performing data processing on the initial 3D medical image based on preset processing parameters to obtain a training 3D medical image includes:
[0041] Performing a resampling operation on the initial 3D medical image to obtain a sampled 3D medical image with a reduced image size;
[0042] Performing Z-Score normalization processing on the sampled 3D medical image to obtain a processed 3D medical image;
[0043] Perform data augmentation operations on the processed 3D medical images to obtain training 3D medical images; the data augmentation operations include random pixel perturbation, random image flipping, and random image rotation.
[0044] In a feasible implementation, in the present invention, resampling operations are performed on the initial 3D medical images to reduce the original image size and training pressure; and Z-Score normalization processing is performed on the data obtained after resampling to complete the data preprocessing operations; random pixel perturbation, random flipping, and random rotation are performed on the medical images that have completed the data preprocessing operations to complete the data augmentation operations and obtain the to-be-segmented images that can be used for training.
[0045] Performing resampling operations on the initial 3D medical images to reduce the original image size and training pressure includes: using cubic spline interpolation for the initial 3D medical images; and using the nearest neighbor interpolation method for processing the label data. Before the initial 3D medical images are input into the medical image segmentation model, the size of each 3D medical image is adjusted to (128, 128, 160) by the above cubic spline interpolation method.
[0046] Random pixel perturbation includes random intensity displacement and random intensity scaling; for random intensity displacement, a floating point number is randomly selected between -0.1 and 0.1 and added to the image intensity; for random intensity scaling, a floating point number is randomly selected between 0.9 and 1.1 and multiplied by the image intensity.
[0047] Random flipping is performed on the x, y, and z axes with a probability of 50%. The random rotation angle is randomly selected between -15° and 15°, and the rotation axis is randomly selected from the x, y, and z axes.
[0048] S2. Construct a medical image segmentation model based on the ResUnet model structure; the medical image segmentation model is a prior-enhanced ResUNet model based on hierarchical shapes.
[0049] Among them, the medical image segmentation model includes an encoder module, a hierarchical shape prior module, and a decoder module;
[0050] The encoder module includes a first downsampling module, a second downsampling module, a third downsampling module, and a fourth downsampling module; the first downsampling module includes a compression convolutional layer, a comprehensive convolutional layer, and an expansion convolutional layer; the module structure of the second downsampling module is the same as that of the first downsampling module; the module structure of the third downsampling module is the same as that of the first downsampling module; the module structure of the fourth downsampling module is the same as that of the first downsampling module;
[0051] The hierarchical shape prior module includes a first shape prior module, a second shape prior module, and a third shape prior module; the model structure of the first shape prior module includes a first self-update module and a first cross-update module; the second shape prior module includes a second self-update module and a second cross-update module; the third shape prior module includes a third self-update module and a third cross-update module;
[0052] The decoder module includes a first upsampling module, a second upsampling module, a third upsampling module, and a fourth upsampling module; the first upsampling module includes a compression convolutional layer, a comprehensive convolutional layer, and an expansion convolutional layer; the module structure of the second upsampling module is the same as that of the first upsampling module; the module structure of the third upsampling module is the same as that of the first upsampling module; the module structure of the fourth upsampling module is the same as that of the first upsampling module.
[0053] In a feasible implementation, the first downsampling module includes a compression convolutional layer, a comprehensive convolutional layer, and an expansion convolutional layer connected in sequence; each convolutional layer includes a 3D convolutional layer, a 3D normalization layer, and a ReLU activation function connected in sequence; the second downsampling module, the third downsampling module, and the fourth downsampling module all have the same structure as the first downsampling module.
[0054] The convolution kernel size of the 3D convolutional layer in the compression convolutional layer of the encoder module is set to 、The convolution kernel size of the 3D convolutional layer in the comprehensive convolutional layer is set to 、The convolution kernel size of the 3D convolutional layer in the expansion convolutional layer is set to .
[0055] The 3D normalization layer of the encoder module uses the Group Normalization method (GroupNorm) to perform normalization within a group of feature channels; the shape of the image to be segmented in the first downsampling module of the encoder module is (128, 128, 160). The shapes of the image after passing through the first, second, third, and fourth downsampling modules of the encoder are x1 (64, 64, 80), x2 (32, 32, 40), x3 (16, 16, 20), and x4 (8, 8, 10), respectively.
[0056] The decoder module includes a first upsampling module, a second upsampling module, a third upsampling module, and a fourth upsampling module; the first upsampling module includes a compression convolutional layer, a comprehensive convolutional layer, and an expansion convolutional layer connected in sequence; each convolutional layer includes a 3D convolutional layer, a 3D normalization layer, and a ReLU activation function connected in sequence; the second upsampling module, the third upsampling module, and the fourth upsampling module all have the same structure as the first upsampling module.
[0057] The convolution kernel size of the 3D convolution layer in the compression convolution layer of the decoder module is set to and the convolution kernel size of the 3D convolution layer in the comprehensive convolution layer is set to and the convolution kernel size of the 3D convolution layer in the expansion convolution layer is set to . The 3D normalization layer of the decoder module uses batch normalization (Batch Normalization, BatchNorm) to normalize between samples within a batch.
[0058] The shapes of the image after passing through the fourth, third, second, and first upsampling modules of the decoder are x5(16, 16, 20), x6(32, 32, 40), x7(64, 64, 80), and x8(128, 128, 160) respectively.
[0059] S3. Input the training 3D medical image into the medical image segmentation model for image segmentation prediction training to obtain a 3D segmentation image.
[0060] Optionally, inputting the training 3D medical image into the medical image segmentation model for image segmentation prediction training to obtain a 3D segmentation image includes:
[0061] Inputting the training 3D medical image into the encoder module for feature extraction to obtain the first 3D image feature, the second 3D image feature, the third 3D image feature, and the fourth 3D image feature;
[0062] Inputting the first 3D image feature, the second 3D image feature, and the third 3D image feature into the hierarchical shape prior module for global information capture to obtain the first updated shape prior, the second updated shape prior, and the third updated shape prior;
[0063] Inputting the first updated shape prior, the second updated shape prior, the third updated shape prior, and the fourth 3D image feature into the decoder module to obtain a 3D segmentation image.
[0064] In a feasible implementation, as Figure 2 shown, the hierarchical shape prior module includes a first shape prior module, a second shape prior block, and a third shape prior module; each shape prior module includes a self-update module and a cross-update module.
[0065] Input the image to be segmented into the encoder module of the model. The downsampling module of the encoder module extracts medical image features through pooling and convolution operations and inputs them in the form of the original feature map into the cross-update module of the same layer and the downsampling module of the next layer; among them, since the hierarchical shape prior module only includes three layers of shape prior modules, the lowest downsampling module only inputs the extracted medical image features into the decoder.
[0066] The cross-update module combines the original feature map input by the downsampling module of the same layer with the shape prior input by the self-update module of the same layer, outputs to the upsampling module of the same layer in the decoder, and inputs the updated shape prior into the self-update module of the shape prior module of the next layer, completing the introduction of shape prior information into the decoding process and the further update and transmission of the shape prior.
[0067] The self-update module receives the shape prior input by the cross-update module of the higher layer, updates it using the self-attention mechanism, and inputs the update result into the cross-update module of the next layer.
[0068] The upsampling module of the decoder uses the new feature map input by the cross-update module of the same layer to further restore the restored feature map input by the upsampling module of the next layer, and inputs the result into the upsampling module of the higher layer; among them, since the hierarchical shape prior module only includes three shape prior modules, the upsampling module of the lowest layer only receives the original feature map input by the downsampling module of the lowest layer located in the same layer; the upsampling module of the highest layer of the decoder outputs the segmented medical image.
[0069] Optionally, input the first 3D image feature, the second 3D image feature, and the third 3D image feature into the hierarchical shape prior module for global information capture to obtain the first updated shape prior, the second updated shape prior, and the third updated shape prior, including:
[0070] Input the first 3D image feature into the first self-update module for prior capture to obtain the first shape prior; input the first 3D image feature and the first shape prior into the first cross-update module for prior update to obtain the first updated shape prior;
[0071] Input the second 3D image feature and the first updated shape prior into the second self-update module for prior capture to obtain the second shape prior; input the second 3D image feature and the second shape prior into the second cross-update module for prior update to obtain the second updated shape prior;
[0072] Input the third 3D image feature and the second updated shape prior into the third self-update module for prior capture to obtain the third shape prior; input the third 3D image feature and the third shape prior into the third cross-update module for prior update to obtain the third updated shape prior.
[0073] In a feasible implementation, as Figure 3 shown, the self-update module uses the self-attention mechanism to update the shape prior output by the cross-update module of the higher layer, enhances the ability of the shape prior to capture the global information and internal structure relationship of the medical image, and inputs the shape prior into the cross-update module of the same layer.
[0074] In the self-update module, according to the regularization principle, layer normalization is performed on the shape prior to reduce internal covariate shift and enhance stability; the self-attention calculation method is used to calculate the query matrix, key matrix, and value matrix, and based on the calculation results, the attention probability matrix is calculated and dropout is performed; the attention probability matrix is multiplied element-wise with the value matrix to derive the context vector with global information; the residual connection method is adopted to add the context vector to the shape prior and perform layer normalization on the result; a two-layer fully-connected network is used to process the shape prior, and the GELU activation function is used for activation in the first layer of the fully-connected network; the residual link method is adopted to add the shape prior processed by the fully-connected network to the unprocessed shape prior and continue to perform layer normalization on the result.
[0075] As Figure 4 shown, the cross-update module combines the shape prior output by the self-update module with the medical image features extracted by the encoder, outputs them to the upsampling module of the decoder, and inputs the updated shape prior into the self-update module of the shape prior module in the next layer, completing the introduction of shape prior information into the decoding process and the further update and transmission of the shape prior.
[0076] In the cross-update module, the shape prior and medical image features are fused based on the class feature calculation method and the result is normalized; the Einstein summation convention is used to combine the normalized result with the shape prior, and the residual link method is adopted to add the result to the medical image features extracted by the encoder to obtain the updated medical image features and output them to the upsampling module of the decoder in a skip connection manner; the updated medical image features are processed using a residual convolutional block, scaled using the cubic spline interpolation method, and added to the shape prior to complete the further update of the shape prior; the updated shape prior is input into the self-update module of the shape prior module in the next layer to complete the transmission of the shape prior.
[0077] S4. Construct a loss function according to the preset 3D medical image characteristics; based on the loss function, calculate according to the preset annotated 3D medical image and 3D segmentation image to obtain the model segmentation loss; the loss function includes the Dice loss function, cross-entropy loss function, and BoundaryDoU loss function.
[0078] Optionally, based on the loss function, calculate according to the preset annotated 3D medical image and 3D segmentation image to obtain the model segmentation loss, including:
[0079] Based on the Dice loss function, calculate according to the preset annotated 3D medical image and 3D segmentation image to obtain the Dice loss;
[0080] Based on the cross-entropy loss function, calculate according to the preset labeled 3D medical image and the 3D segmentation image to obtain the cross-entropy loss;
[0081] Based on the BoundaryDoU loss function, calculate according to the preset labeled 3D medical image and the 3D segmentation image to obtain the BoundaryDoU loss;
[0082] Perform weighted calculation according to the Dice loss, cross-entropy loss, and BoundaryDoU loss to obtain the model segmentation loss.
[0083] In a feasible implementation, calculate the model loss using the loss function designed according to the characteristics of the 3D medical image. Calculate the corresponding loss function values according to the following loss function formulas as shown in formulas (1), (2), and (3):
[0084] (1);
[0085] (2);
[0086] (3);
[0087] Wherein, represents the predicted segmentation mask of the model (Predicted mask); represents the ground truth mask (Ground truth mask); M is the number of samples; and are respectively the true label and predicted probability that the sample i belongs to the classification n; represents the predicted boundary (Predicted boundary); represents the ground truth boundary (Ground truth boundary); represents the symmetric difference set between the predicted boundary and the ground truth boundary; DiceLoss represents the Dice loss; Cross-EntropyLoss represents the Cross-Entropy loss; BoundaryDoULoss represents the BoundaryDoU loss.
[0088] Calculate the model segmentation loss based on the DiceLoss between the model segmentation result and the actual annotation, the Cross-EntropyLoss between the 3D segmentation image and the actual annotation, and the BoundaryDoULoss between the model segmentation result and the actual annotation, as shown in formula (4) below:
[0089] (4);
[0090] Among them, 0.5 is the weight of DiceLoss; 0.1 is the weight of Cross-EntropyLoss; 0.4 is the weight of BoundaryDoULoss.
[0091] S5. Optimize the parameters of the medical image segmentation model according to the model segmentation loss to obtain an optimized image segmentation model.
[0092] In a feasible implementation manner, perform backpropagation on the model based on the model segmentation loss to update the parameters in the model.
[0093] Calculate the similarity between the overall segmentation result of the model and the overall actual annotation based on DiceLoss to guide the model to increase the overlap between the segmentation result and the actual annotation; calculate the difference between each class of segmentation result and each class of actual annotation based on Cross-EntropyLoss to guide the model to better handle the multi-classification task including four classifications of kidney tissue, renal tumor, renal artery, and renal vein; calculate the difference between the boundary of the overall segmentation result of the model and the boundary of the overall actual annotation based on BoundaryDoULoss. Using the loss function in the present invention, structures that are subtle in morphological structure but significant for clinical applications, such as fine blood vessels, can be avoided from being ignored.
[0094] During the process of updating the parameters in the model by backpropagation, use the cosine annealing strategy to dynamically adjust the learning rate of the updated parameters. The initial learning rate is 0.0005, and a warm restart is performed every 25 epochs to help the model jump out of the local optimum and improve the generalization ability of the model.
[0095] S6. Obtain the 3D medical image to be segmented; perform image segmentation on the 3D medical image to be segmented through the optimized image segmentation model.
[0096] In a feasible implementation manner, input the 3D medical image to be segmented into the optimized model to obtain a segmentation result, and use ITK-Snap software to construct a visualized 3D medical image.
[0097] Input the 3D image of the segmentation target into the encoder of the trained model, and obtain the segmentation result from the decoder of the trained model; use the initial 3D image as the main image, create a new project in ITK-Snap; add the segmentation result to the main image for three-dimensional reconstruction, and obtain the final visualized 3D medical image.
[0098] In a feasible implementation manner, the present invention adopts a segmentation model, a series of models based on the UNet model, a basic UNet model, and a basic ResUNet model. The effects on the KiPA 22 dataset and the ACDC cardiac segmentation dataset are shown in Table 1 (Table of Image Segmentation Effects of KiPA 22 Dataset) and Table 2 (Table of Image Segmentation Effects of ACDC Dataset):
[0099] Table 1
[0100]
[0101] Table 2
[0102]
[0103] UNet is the unmodified basic UNet model, ResUNet is the unmodified basic ResUNet model, the neural network U-Net (Neural Network U-Net, nnUNet), the multi-layer feature aggregation search network UXNET for 3D medical image segmentation, and a model for 3D medical image analysis (Swin Transformers for Semantic Segmentation, SwinUNTR) are excellent series models based on the UNet model;
[0104] The values in Table 1 and Table 2 include the Dice Similarity Coefficient (DSC), and the larger the value, the better the segmentation effect; the Hausdorff Distance (HD), where "95" indicates that the ninety-fifth percentile of the distance is considered in this case to reduce the influence of extreme outliers, and the smaller the value, the better the segmentation effect; the Average Symmetric Surface Distance (ASSD), and the smaller the value, the better the segmentation effect; the bold black values in the table indicate the best segmentation performance.
[0105] Compared with the UNet model, the segmentation index DSC of the present invention on the KiPA 22 dataset is increased by 5.26%, HD95 is decreased by 9.9104 mm, and ASSD is decreased by 1.9111 mm. On the ACDC dataset, the segmentation index DSC is increased by 1.54%, HD95 is decreased by 0.4468 mm, and ASSD is decreased by 0.1526 mm.
[0106] Compared with the three models of nnU-Net, UX-NET, and SwinUNTR, the segmentation metric DSC of the present invention on the KiPA 22 dataset increased by 1.08%, 1.18%, and 2.9% respectively; HD95 decreased by 3.5987 mm, 3.5872 mm, and 3.9389 mm respectively; ASSD decreased by 0.5964 mm, 0.4949 mm, and 0.8713 mm respectively. On the ACDC dataset, the segmentation metric DSC increased by 1.48%, 2.65%, and 2.88% respectively; HD95 decreased by 0.4041 mm, 0.7633 mm, and 0.9737 mm respectively; ASSD decreased by 0.0926 mm, 0.3422 mm, and 0.3382 mm respectively.
[0107] Compared with the ResUNet model, the segmentation metric DSC of the present invention on the KiPA 22 dataset increased by 1.04%, HD95 decreased by 1.1150 mm, and ASSD decreased by 0.2146 mm. On the ACDC dataset, the segmentation metric DSC increased by 1.24%, HD95 decreased by 0.2961 mm, and ASSD decreased by 0.0665 mm.
[0108] From the comparison results in Table 1 and Table 2, it can be concluded that the model of the present invention significantly improves the segmentation accuracy of medical images with low contrast, highly blurred pathological tissue morphology and position compared with the existing medical 3D image segmentation methods.
[0109] The present invention proposes a medical image segmentation method based on a hierarchical shape prior enhanced ResUNet model; through a hierarchical shape prior module composed of three layers of shape prior modules, the hierarchical transfer and update of the shape prior are realized, enhancing the model's comprehensive understanding of medical images; a combined loss function composed of DiceLoss, Cross-EntropyLoss and is introduced to achieve balanced learning of the detailed features and overall structure of medical images, and ensure that the model has high training efficiency while having accurate segmentation accuracy in complex medical image segmentation scenarios such as high detail, low contrast between the segmentation target and surrounding tissues, and variable morphological positions of diseased organs. The present invention has good portability. The present invention enhances the skip connection part of the ResUNet model without modifying the encoder and decoder of the ResUNet model, so the present invention can be applied to variant models of other UNet models, with high flexibility and practicality. The present invention is an accurate and efficient 3D medical image segmentation method based on a hierarchical shape prior enhanced ResUNet model.
[0110] Figure 5It is a block diagram of a medical image segmentation device based on a hierarchical shape prior enhanced ResUNet model shown according to an exemplary embodiment. This device is used for a medical image segmentation method based on a hierarchical shape prior enhanced ResUNet model. Referring to Figure 5 As shown in Figure 5 , this device includes an image processing module 510, a model construction module 520, a model training module 530, a loss calculation module 540, a model optimization module 550, and an image segmentation module 560. Among them:
[0111] The image processing module 510 is configured to obtain an initial 3D medical image; based on preset processing parameters, perform data processing on the initial 3D medical image to obtain a training 3D medical image;
[0112] The model construction module 520 is configured to construct a medical image segmentation model based on the ResUnet model structure; the medical image segmentation model is a hierarchical shape prior enhanced ResUNet model;
[0113] The model training module 530 is configured to input the training 3D medical image into the medical image segmentation model for image segmentation prediction training to obtain a 3D segmentation image;
[0114] The loss calculation module 540 is configured to construct a loss function according to the characteristics of the preset 3D medical image; based on the loss function, calculate according to the preset labeled 3D medical image and the 3D segmentation image to obtain the model segmentation loss; the loss function includes a Dice loss function, a cross-entropy loss function, and a BoundaryDoU loss function;
[0115] The model optimization module 550 is configured to optimize the parameters of the medical image segmentation model according to the model segmentation loss to obtain an optimized image segmentation model;
[0116] The image segmentation module 560 is configured to obtain a 3D medical image to be segmented; perform image segmentation on the 3D medical image to be segmented through the optimized image segmentation model.
[0117] Optionally, the image processing module 510 is further configured to:
[0118] Perform a resampling operation on the initial 3D medical image to obtain a sampled 3D medical image with a reduced image size;
[0119] Perform Z-Score normalization processing on the sampled 3D medical image to obtain a processed 3D medical image;
[0120] Perform data augmentation operations on the processed 3D medical image to obtain a training 3D medical image; the data augmentation operations include random pixel perturbation, random image flipping, and random image rotation.
[0121] Among them, the medical image segmentation model includes an encoder module, a hierarchical shape prior module, and a decoder module;
[0122] The encoder module includes a first downsampling module, a second downsampling module, a third downsampling module, and a fourth downsampling module; the first downsampling module includes a compression convolutional layer, a comprehensive convolutional layer, and an expansion convolutional layer; the module structure of the second downsampling module is the same as that of the first downsampling module; the module structure of the third downsampling module is the same as that of the first downsampling module; the module structure of the fourth downsampling module is the same as that of the first downsampling module;
[0123] The hierarchical shape prior module includes a first shape prior module, a second shape prior module, and a third shape prior module; the model structure of the first shape prior module includes a first self-update module and a first cross-update module; the second shape prior module includes a second self-update module and a second cross-update module; the third shape prior module includes a third self-update module and a third cross-update module;
[0124] The decoder module includes a first upsampling module, a second upsampling module, a third upsampling module, and a fourth upsampling module; the first upsampling module includes a compression convolutional layer, a comprehensive convolutional layer, and an expansion convolutional layer; the module structure of the second upsampling module is the same as that of the first upsampling module; the module structure of the third upsampling module is the same as that of the first upsampling module; the module structure of the fourth upsampling module is the same as that of the first upsampling module.
[0125] Optionally, the model training module 530 is further configured to:
[0126] Input the training 3D medical image into the encoder module for feature extraction to obtain the first 3D image feature, the second 3D image feature, the third 3D image feature, and the fourth 3D image feature;
[0127] Input the first 3D image feature, the second 3D image feature, and the third 3D image feature into the hierarchical shape prior module for global information capture to obtain the first updated shape prior, the second updated shape prior, and the third updated shape prior;
[0128] Input the first updated shape prior, the second updated shape prior, the third updated shape prior, and the fourth 3D image feature into the decoder module to obtain the 3D segmentation image.
[0129] Optionally, the model training module 530 is further configured to:
[0130] Input the first 3D image feature into the first self-update module for prior capture to obtain the first shape prior; input the first 3D image feature and the first shape prior into the first cross-update module for prior update to obtain the first updated shape prior;
[0131] Input the second 3D image feature and the first updated shape prior into the second self-update module for prior capture to obtain the second shape prior; input the second 3D image feature and the second shape prior into the second cross-update module for prior update to obtain the second updated shape prior;
[0132] Input the third 3D image feature and the second updated shape prior into the third self-update module for prior capture to obtain the third shape prior; input the third 3D image feature and the third shape prior into the third cross-update module for prior update to obtain the third updated shape prior.
[0133] Optionally, the loss calculation module 540 is further configured to:
[0134] Calculate based on the Dice loss function according to the preset annotated 3D medical image and the 3D segmentation image to obtain the Dice loss;
[0135] Calculate based on the cross-entropy loss function according to the preset annotated 3D medical image and the 3D segmentation image to obtain the cross-entropy loss;
[0136] Calculate based on the BoundaryDoU loss function according to the preset annotated 3D medical image and the 3D segmentation image to obtain the BoundaryDoU loss;
[0137] Perform weighted calculation according to the Dice loss, cross-entropy loss, and BoundaryDoU loss to obtain the model segmentation loss.
[0138] The present invention proposes a medical image segmentation method based on a hierarchical shape prior enhanced ResUNet model; through a hierarchical shape prior module composed of three layers of shape prior modules, the hierarchical transfer and update of the shape prior are realized, enhancing the model's comprehensive understanding of medical images; a combined loss function composed of DiceLoss, Cross-EntropyLoss and is introduced to achieve balanced learning of the detailed features and overall structure of medical images, and ensure that the model has high training efficiency when facing complex medical image segmentation scenarios such as high detail, low contrast between the segmentation target and surrounding tissues, and variable morphological positions of diseased organs, while still having accurate segmentation accuracy. The present invention has good portability. The present invention enhances the skip connection part of the ResUNet model without modifying the encoder and decoder of the ResUNet model, so the present invention can be applied to variant models of other UNet models, with high flexibility and practicality. The present invention is an accurate and efficient 3D medical image segmentation method based on a hierarchical shape prior enhanced ResUNet model.
[0139] Figure 6 FIG. is a schematic structural diagram of a medical image segmentation device provided by an embodiment of the present invention, as Figure 6 shown, the medical image segmentation device may include the above-mentioned Figure 5 medical image segmentation device based on a hierarchical shape prior enhanced ResUNet model shown. Optionally, the medical image segmentation device 610 may include a first processor 2001.
[0140] Optionally, the medical image segmentation device 610 may further include a memory 2002 and a transceiver 2003.
[0141] Among them, the first processor 2001, the memory 2002 and the transceiver 2003 may be connected through a communication bus.
[0142] Next, in conjunction with Figure 6 each component of the medical image segmentation device 610 will be specifically introduced:
[0143] Among them, the first processor 2001 is the control center of the medical image segmentation device 610, which can be a single processor or a collective term for multiple processing elements. For example, the first processor 2001 is one or more central processing units (CPUs), or can be an application specific integrated circuit (ASIC), or one or more integrated circuits configured to implement the embodiments of the present invention, such as: one or more digital signal processors (DSPs), or one or more field programmable gate arrays (FPGAs).
[0144] Optionally, the first processor 2001 can execute various functions of the medical image segmentation device 610 by running or executing software programs stored in the memory 2002 and calling data stored in the memory 2002.
[0145] In a specific implementation, as an embodiment, the first processor 2001 can include one or more CPUs, such as Figure 6 the CPU0 and CPU1 shown in
[0146] In a specific implementation, as an embodiment, the medical image segmentation device 610 can also include multiple processors, such as Figure 6 the first processor 2001 and the second processor 2004 shown in. Each of these processors can be a single-core processor (single-CPU) or a multi-core processor (multi-CPU). Here, the processor can refer to one or more devices, circuits, and / or processing cores for processing data (such as computer program instructions).
[0147] Among them, the memory 2002 is used to store software programs for executing the solution of the present invention and is controlled by the first processor 2001 for execution. The specific implementation method can refer to the above method embodiments and will not be elaborated here.
[0148] Optionally, the memory 2002 can be a read-only memory (ROM) or other types of static storage devices that can store static information and instructions, a random access memory (RAM) or other types of dynamic storage devices that can store information and instructions, or can also be an electrically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (including compact discs, laser discs, optical discs, digital versatile discs, Blu-ray discs, etc.), magnetic disk storage media or other magnetic storage devices, or any other medium that can be used to carry or store the desired program code in the form of instructions or data structures and can be accessed by a computer, but is not limited thereto. The memory 2002 can be integrated with the first processor 2001 or can exist independently and be coupled to the first processor 2001 through an interface circuit ( Figure 6 not shown) of the medical image segmentation device 610. The embodiments of the present invention do not make specific limitations in this regard.
[0149] The transceiver 2003 is used to communicate with a network device or with a terminal device.
[0150] Optionally, the transceiver 2003 can include a receiver and a transmitter ( Figure 6 not shown separately). Among them, the receiver is used to implement the receiving function, and the transmitter is used to implement the sending function.
[0151] Optionally, the transceiver 2003 can be integrated with the first processor 2001 or can exist independently and be coupled to the first processor 2001 through an interface circuit ( Figure 6 not shown) of the medical image segmentation device 610. The embodiments of the present invention do not make specific limitations in this regard.
[0152] It should be noted that Figure 6 the structure of the medical image segmentation device 610 shown does not constitute a limitation on the router. The actual knowledge structure recognition device may include more or fewer components than shown, or combine certain components, or have different component arrangements.
[0153] In addition, the technical effects of the medical image segmentation device 610 can refer to the technical effects of the medical image segmentation method based on the hierarchical shape prior enhanced ResUNet model described in the above method embodiments, and will not be elaborated here.
[0154] It should be understood that the first processor 2001 in the embodiments of the present invention may be a central processing unit (CPU), and the processor may also be other general-purpose processors, digital signal processors (DSPs), application specific integrated circuits (ASICs), field programmable gate arrays (FPGAs) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.
[0155] It should also be understood that the memory in the embodiments of the present invention may be a volatile memory or a non-volatile memory, or may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable ROM (PROM), an erasable PROM (EPROM), an electrically erasable PROM (EEPROM) or a flash memory. The volatile memory may be a random access memory (RAM), which is used as an external cache. By way of example but not limitation, many forms of random access memory (RAM) are available, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchlink DRAM (SLDRAM) and direct rambus RAM (DR RAM).
[0156] The above embodiments can be implemented in whole or in part by software, hardware (such as circuits), firmware, or any combination thereof. When implemented using software, the above embodiments can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions or computer programs. When the computer instructions or computer programs are loaded or executed on a computer, the processes or functions described in the embodiments of the present invention are generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired (such as infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server or data center that contains one or more collections of available media. The available medium can be a magnetic medium (such as a floppy disk, hard disk, or magnetic tape), an optical medium (such as a DVD), or a semiconductor medium. The semiconductor medium can be a solid-state drive.
[0157] It should be understood that the term "and / or" in this document is merely a description of the association relationship between associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist simultaneously, and B exists alone. Here, A and B can be singular or plural. Additionally, the character " / " in this document generally represents an "or" relationship between the associated objects before and after, but it may also represent an "and / or" relationship, which can be specifically understood by referring to the context before and after.
[0158] In the present invention, "at least one" means one or more, and "a plurality" means two or more. "At least one of the following" or its similar expressions refer to any combination of these items, including any combination of single items or plural items. For example, at least one of a, b, or c can represent: a, b, c, a - b, a - c, b - c, or a - b - c, where a, b, and c can be single or multiple.
[0159] It should be understood that in various embodiments of the present invention, the magnitudes of the sequence numbers of the above processes do not imply the order of execution. The order of execution of each process should be determined by its function and internal logic, and should not constitute any limitation to the implementation process of the embodiments of the present invention.
[0160] Those of ordinary skill in the art can realize that the units and algorithm steps of each example described in combination with the embodiments disclosed herein can be implemented by electronic hardware, or by a combination of computer software and electronic hardware. Whether these functions are executed in a hardware or software manner depends on the specific application and design constraints of the technical solution. Professional technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present invention.
[0161] Those skilled in the art can clearly understand that for the convenience and brevity of description, the specific working processes of the above-described devices, apparatuses, and units can refer to the corresponding processes in the foregoing method embodiments and will not be elaborated herein.
[0162] In several embodiments provided by the present invention, it should be understood that the disclosed devices, apparatuses, and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed. Another point is that the displayed or discussed couplings or direct couplings or communication connections to each other can be through some interfaces. The indirect couplings or communication connections of the devices or units can be in electrical, mechanical, or other forms.
[0163] The units described as separate components may or may not be physically separated. The components displayed as units may or may not be physical units, that is, they can be located in one place, or they can be distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0164] In addition, the functional units in each embodiment of the present invention can be integrated in a processing unit, or each unit can exist physically alone, or two or more units can be integrated in one unit.
[0165] When the above-mentioned function is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in various embodiments of the present invention. The foregoing storage medium includes: various media that can store program codes, such as USB flash drives, mobile hard disks, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical discs.
[0166] As described above, the above are only specific embodiments of the present invention, but the protection scope of the present invention is not limited thereto. Any person skilled in the art within the technical scope disclosed by the present invention can easily think of changes or substitutions, which should all be covered by the protection scope of the present invention. Therefore, the protection scope of the present invention should be subject to the protection scope of the claims.
Claims
1. A medical image segmentation method based on a hierarchical shape prior enhanced ResUNet model, characterized in that: The method comprises: Acquire an initial 3D medical image; perform data processing on the initial 3D medical image based on preset processing parameters to obtain a training 3D medical image; Constructing a medical image segmentation model based on the ResUnet model structure; the medical image segmentation model is a ResUNet model enhanced based on hierarchical shape priors; Wherein, the medical image segmentation model includes an encoder module, a hierarchical shape prior module and a decoder module; Inputting the training 3D medical image into the medical image segmentation model to perform image segmentation prediction training to obtain a 3D segmented image; The step of inputting the training 3D medical image into the medical image segmentation model for image segmentation prediction training to obtain a 3D segmented image includes: Inputting the training 3D medical image into the encoder module for feature extraction to obtain a first 3D image feature, a second 3D image feature, a third 3D image feature, and a fourth 3D image feature; Inputting the first 3D image feature, the second 3D image feature and the third 3D image feature into the hierarchical shape prior module to capture global information, thereby obtaining a first updated shape prior, a second updated shape prior and a third updated shape prior; Inputting the first updated shape prior, the second updated shape prior, the third updated shape prior and the fourth 3D image feature into the decoder module to obtain a 3D segmented image; Constructing a loss function according to the preset 3D medical image characteristics; based on the loss function, calculating according to the preset annotated 3D medical image and the 3D segmented image to obtain the model segmentation loss; the loss function includes a Dice loss function, a cross entropy loss function and a BoundaryDoU loss function; According to the model segmentation loss, optimizing the parameters of the medical image segmentation model to obtain an optimized image segmentation model; Acquire a 3D medical image to be segmented; and perform image segmentation using the optimized image segmentation model according to the 3D medical image to be segmented.
2. The medical image segmentation method based on the hierarchical shape prior enhanced ResUNet model according to claim 1, characterized in that: The step of performing data processing on the initial 3D medical image based on preset processing parameters to obtain a training 3D medical image includes: Resampling the initial 3D medical image to obtain a sampled 3D medical image with a reduced image size; Performing Z-Score normalization processing on the sampled 3D medical image to obtain a processed 3D medical image; Performing a data enhancement operation on the processed 3D medical image to obtain a training 3D medical image; the data enhancement operation includes random pixel perturbation, random image flipping and random image rotation.
3. The medical image segmentation method based on the hierarchical shape prior enhanced ResUNet model according to claim 1, characterized in that: The encoder module includes a first down-sampling module, a second down-sampling module, a third down-sampling module and a fourth down-sampling module; the first down-sampling module includes a compressed convolution layer, a comprehensive convolution layer and an extended convolution layer; the module structure of the second down-sampling module is the same as the module structure of the first down-sampling module; the module structure of the third down-sampling module is the same as the module structure of the first down-sampling module; the module structure of the fourth down-sampling module is the same as the module structure of the first down-sampling module; The hierarchical shape prior module includes a first shape prior module, a second shape prior module and a third shape prior module; the model structure of the first shape prior module includes a first self-update module and a first cross-update module; the second shape prior module includes a second self-update module and a second cross-update module; the third shape prior module includes a third self-update module and a third cross-update module; The decoder module includes a first upsampling module, a second upsampling module, a third upsampling module and a fourth upsampling module; the first upsampling module includes a compressed convolution layer, a comprehensive convolution layer and an extended convolution layer; the module structure of the second upsampling module is the same as the module structure of the first upsampling module; the module structure of the third upsampling module is the same as the module structure of the first upsampling module; the module structure of the fourth upsampling module is the same as the module structure of the first upsampling module.
4. The medical image segmentation method based on the hierarchical shape prior enhanced ResUNet model according to claim 3, characterized in that: The step of inputting the first 3D image feature, the second 3D image feature and the third 3D image feature into the hierarchical shape prior module to capture global information and obtain a first updated shape prior, a second updated shape prior and a third updated shape prior comprises: Inputting the first 3D image feature into the first self-update module for prior capture to obtain a first shape prior; inputting the first 3D image feature and the first shape prior into the first cross-update module for prior update to obtain a first updated shape prior; Inputting the second 3D image feature and the first updated shape prior into the second self-update module for prior capture to obtain a second shape prior; inputting the second 3D image feature and the second shape prior into the second cross-update module for prior update to obtain a second updated shape prior; The third 3D image feature and the second updated shape prior are input into the third self-update module for prior capture to obtain a third shape prior; the third 3D image feature and the third shape prior are input into the third cross-update module for prior update to obtain a third updated shape prior.
5. The medical image segmentation method based on the hierarchical shape prior enhanced ResUNet model according to claim 1, characterized in that: The step of calculating based on the loss function according to the preset annotated 3D medical image and the 3D segmented image to obtain the model segmentation loss includes: Based on the Dice loss function, a Dice loss is obtained by performing calculation according to the preset annotated 3D medical image and the 3D segmented image; Based on the cross entropy loss function, a cross entropy loss is obtained by calculating according to the preset annotated 3D medical image and the 3D segmented image; Based on the BoundaryDoU loss function, a BoundaryDoU loss is obtained by performing calculation according to the preset annotated 3D medical image and the 3D segmented image; A weighted calculation is performed according to the Dice loss, the cross entropy loss, and the BoundaryDoU loss to obtain a model segmentation loss.
6. A medical image segmentation device based on a hierarchical shape prior enhanced ResUNet model, wherein the medical image segmentation device based on a hierarchical shape prior enhanced ResUNet model is used to implement the medical image segmentation method based on a hierarchical shape prior enhanced ResUNet model as claimed in any one of claims 1 to 5, characterized in that: The device comprises: An image processing module, used to obtain an initial 3D medical image; based on preset processing parameters, perform data processing on the initial 3D medical image to obtain a training 3D medical image; A model building module, used to build a medical image segmentation model based on the ResUNet model structure; the medical image segmentation model is a ResUNet model enhanced based on hierarchical shape priors; A model training module, used for inputting the training 3D medical image into the medical image segmentation model to perform image segmentation prediction training to obtain a 3D segmented image; A loss calculation module, used to construct a loss function according to the preset 3D medical image characteristics; based on the loss function, calculate according to the preset annotated 3D medical image and the 3D segmented image to obtain the model segmentation loss; the loss function includes a Dice loss function, a cross entropy loss function and a BoundaryDoU loss function; A model optimization module, used to optimize the parameters of the medical image segmentation model according to the model segmentation loss to obtain an optimized image segmentation model; The image segmentation module is used to obtain the 3D medical image to be segmented; and perform image segmentation based on the 3D medical image to be segmented using the optimized image segmentation model.
7. The medical image segmentation device based on the hierarchical shape prior enhanced ResUNet model according to claim 6, characterized in that: The image processing module is further used for: Resampling the initial 3D medical image to obtain a sampled 3D medical image with a reduced image size; Performing Z-Score normalization processing on the sampled 3D medical image to obtain a processed 3D medical image; Performing a data enhancement operation on the processed 3D medical image to obtain a training 3D medical image; the data enhancement operation includes random pixel perturbation, random image flipping and random image rotation.
8. A medical image segmentation device, characterized in that: The medical image segmentation device comprises: processor; A memory having computer-readable instructions stored thereon, wherein when the computer-readable instructions are executed by the processor, the method according to any one of claims 1 to 5 is implemented.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores program codes, which can be called by a processor to execute the method according to any one of claims 1 to 5.
Citation Information
Patent Citations
Full-automatic medical image segmentation method and device based on shape prior
CN113706494A
Medical image segmentation method based on shape prior U-Net
CN115239716A