A deep learning-based MRI image segmentation method
By using a method based on deep learning, combining image data enhancement and morphological methods to obtain prostate edge labels, transforming the U-Net network and using dual decoders, the problem of unsatisfactory prostate segmentation in MRI images is solved, achieving more efficient and accurate results. Prostate segmentation results.
Patent Information
- Application Number
- CN202011118130.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-10-19
- Publication Date
- 2024-10-18
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The existing technology's segmentation effect of prostate in MRI images is not ideal, mainly due to the lack of guidance on the edge of the organ and insufficient data, which makes it difficult for the network model to pay attention to the edge segmentation results.
Using a method based on deep learning, the prostate edge label is obtained through image data enhancement and morphological methods, combined with 3DResBlock and U-Net network, adding the IBN module, transforming the downsampling layer into a stride conv layer, and using dual decoders in the decoding part. Segmentation prediction of prostate whole and edge, using MICCAI competition dataset for model training.
It improves the precision and accuracy of prostate segmentation, enhances the generalization ability and detail information retention ability of the model, and can efficiently and accurately achieve the task of segmenting prostate organs.
Smart Images

Figure CN112508973B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of computer vision, and relates to MRI image processing, image semantic segmentation, and image segmentation using deep learning, and provides an MRI image segmentation method based on deep learning. Background Art
[0002] In the past few years, with the rise of artificial intelligence, the application of computer vision has gradually become common. Among them, image segmentation is a very important direction in the field of computer vision, and image semantic segmentation is the cornerstone technology of image segmentation. It has important applications in autonomous driving systems, address image research, modern industry, medical images, and other fields. For example, in the diagnosis of prostate diseases such as prostate cancer, prostatitis, and prostate hypertrophy, accurate prostate segmentation on three-dimensional MR images is of great significance for doctors to diagnose, understand, and propose targeted treatment plans for patients. At present, it is very time-consuming to manually segment the prostate area, and it places high demands on the rich experience of radiologists. Therefore, the automatic segmentation of prostate MRI images has attracted more and more attention in the field of medical image processing.
[0003] Semantic segmentation of images is a very important direction in the field of computer vision. With the development of deep learning technology, classification tasks and semantic segmentation tasks have also made great progress. Semantic segmentation is a pixel-level segmentation task for images.
[0004] In 1985, Hinton et al. proposed the back-propagation algorithm, making the training of neural networks simple and feasible. In terms of classification, in 1998, LeNet5 marked the true advent of CNN. In 2012, AlexNet was proposed and won the ImageNet classification competition of that year. In 2014, GoogLeNet used the Inception structure, making the network results not only deeper but also "wider". In 2015, He Kaiming et al. proposed the deep residual network ResNet, which used residual units and the number of network layers exceeded 1000. In 2016, Huang Gao et al. proposed DenseNet, which used dense connections. While achieving classification accuracy comparable to ResNet, the parameters and computational complexity were only half of ResNet. In 2017, the domestic autonomous driving company Momenta proposed (Squeeze and-Excitation Networks, SENet) which adopted the "feature recalibration" strategy and won the ImageNet image classification task championship in the same year. In terms of segmentation, in 2014, Long et al. proposed the fully convolutional network FCN, which enables convolutional neural networks to achieve dense pixel-level classification without the need for fully connected layers. The U-Net network proposed in 2015 uses an encoder-decoder structure and introduces shortcut connections between the encoder and the decoder to better restore the detailed information of the object, especially in the segmentation task on medical images, and has achieved good results. Although these classification methods have achieved very good results, the effect on the edge of the prostate has not been ideal. The main reason is that there is no guidance for the network model to learn the edge of the organ. As long as the network segments most of the organ, the loss can be effectively reduced, so that the network no longer pays attention to the segmentation results of the organ edge. Secondly, the small amount of image data brings difficulties to deep learning. Summary of the invention
[0005] The technical problem to be solved by the present invention is to provide an MRI image segmentation method based on deep learning. A deep learning-based image segmentation method that can effectively segment the prostate in MRI (Magnetic Resonance Imaging) images. First, the data is expanded using image data enhancement and extraction technology, and the label of the prostate edge is obtained using a morphological method. Then, 3DResBlock is used as the basic structure, an IBN module is added on the basis of the U-Net network, the maxpool layer is changed to a stride conv layer, and the downsampling adopts a combination of 2D and 3D downsampling as the encoding part; in the decoding part, two decoders are used, one of which performs segmentation prediction of the entire prostate, and the other decoder performs prediction of a separate prostate edge. The model is trained using the Promise12 competition data set of MICCAI in 2012.
[0006] The present invention proposes a prostate segmentation method based on deep learning. In the data preprocessing stage, the image enhancement technology is used to randomly change the brightness, gamma value, and randomly flip the original image horizontally to achieve the purpose of expanding the original data set. Then the data is randomly divided into five equal parts and 5-fold training is performed. Data preprocessing can make full use of the data of the small data set. In addition, by using a deeper network model and a network structure with multiple feature reuses, although the number of images in the data set is small, the information in the image can be learned as much as possible, so the segmentation task of the prostate organ can be achieved efficiently and accurately.
[0007] In order to achieve the above object, the present invention adopts the following technical solutions:
[0008] The Python language is preferred as the basis. In terms of image enhancement, the numpy library is used to flip the original image data left and right, randomly change the brightness, contrast, gamma value, randomly crop the image, add random Gaussian noise, etc., and then output the enhanced image data set. On this basis, the image is randomly divided into 5 equal parts for 5-fold training. Then the open source deep learning framework PyTorch is used to implement the network model and complete the model construction. By training the data set 5-fold, the best model on the validation set is selected for each fold, and the five selected models are fused to obtain the final result.
[0009] A deep learning-based MRI image segmentation method comprises the following steps:
[0010] Step 1: Obtain an MRI prostate original image dataset in a related field, and clean the obtained original image dataset.
[0011] The MRI prostate original image dataset includes images and prostate segmentation labels corresponding to the images;
[0012] Step 2: Use image enhancement technology to enhance the cleaned image data set to increase the number of samples and enrich the data content.
[0013] Step 3: Use morphological methods to corrode the prostate segmentation label corresponding to each image in the enhanced image data set, and then subtract the corroded label from the original label to obtain the label of the prostate edge corresponding to the image.
[0014] Step 4: randomly divide the image data set processed in step 4 into 5 equal data sets.
[0015] Step 5: Build an image segmentation model, add an IBN module to the encoding network of the image segmentation model, and change all the downsampling layers of the network from maxpool to stride conv. The first downsampling is performed using a 2D convolution kernel, and the other downsampling is performed using a 3D convolution kernel. Then, connect two decoders in the encoding network, one of which is used to output the segmentation result of the entire prostate, and the other decoder is used to output the segmentation result of the prostate edge.
[0016] Step 6: Based on the five data sets obtained in step 4, the image segmentation model is trained in five folds, and the optimal model obtained from each fold training is fused.
[0017] Furthermore, step 2 specifically includes the following steps:
[0018] Step 2.1, data morphology enhancement: perform horizontal mirror flipping on the cleaned original image dataset and its annotations.
[0019] Step 2.2, data space domain enhancement: Randomly change the brightness contrast and gamma value to a small extent, while ensuring the physical meaning of the image, increase the amount of image data. Experiments have found that this is effective data enhancement.
[0020] Step 2.3, randomly crop the image data, that is, use the prostate segmentation label of the image in the image data set to obtain the center of the prostate; then let the cropped center randomly jitter within a certain range in the center of the prostate to crop the 64*176*176 image.
[0021] Step 5 specifically includes the following steps:
[0022] Step 5.1, the encoding network of the image segmentation model, the image segmentation model adds the IBN module on the basis of the U-Net model; then the maxpool layer in the original downsampling stage in the U-Net model is changed to a stride conv layer, which is beneficial for the model to retain the detailed information of the image and has a good effect on improving the refinement of the segmentation results.
[0023] The IN is invariant to the appearance changes of the target, and BN has good performance in retaining the features of the feature map. Combining the two can greatly improve the model's learning ability and generalization performance for features.
[0024] Step 5.2, decoding stage: a dual decoder structure is used, where one decoder is used to output the segmentation result of the entire prostate, and the other decoder is used to output the segmentation result of the prostate edge, to help the network strengthen the learning of the segmentation edge.
[0025] Compared with the prior art, the present invention has the following obvious advantages:
[0026] Deep learning models generally require a large amount of data sets to train in order to find the best model. However, medical image data sets are relatively small in size due to the difficulty and high cost of obtaining them compared to natural images. This model adopts a strategy combining IN and BN to enhance the generalization ability of the model. At the same time, the original down-sampled maxpool layer is changed to a stride conv layer, so that the model's ability to retain image detail information is enhanced, making the segmentation result more refined. The method of combining 2D downsampling and 3D downsampling is adopted, that is, according to the characteristics of the data set, 2D convolution is used for downsampling in the first layer of the encoding stage, and 3D convolution is used for downsampling in other downsampling layers to solve the anisotropic characteristics of 3D images and further improve the accuracy of the model. In the decoding stage, a dual decoder strategy is adopted, in which one decoder is used to output the segmentation of the prostate as a whole, and the other decoder is used to output the segmentation of the prostate edge, so that the model can pay more attention to learning the prostate edge. Generally speaking, the present invention can segment the address salt layer image more efficiently and accurately. BRIEF DESCRIPTION OF THE DRAWINGS
[0027] Figure 1 A flow chart of the method involved in the present invention;
[0028] Figure 2 This is the overall structure diagram of the semantic segmentation network involved in the present invention;
[0029] Figure 3 is a network structure diagram of the present invention;
[0030] Figure 4 is the 2D ResBlock structure of the present invention;
[0031] Figure 5 This is the 3D ResBlock structure of the present invention.
[0032] The present invention will be further described in detail below in combination with specific implementations and with reference to the accompanying drawings.
[0033] The hardware equipment used in the present invention includes a PC and a 1080ti graphics card;
[0034] like Figure 1 As shown, the present invention provides a method for prostate segmentation in MR images based on deep learning, which specifically includes the following steps:
[0035] Step 1, obtain the geological salt layer image dataset in the relevant field, and perform the first deep learning-based MRI image segmentation method on these data, including the following steps:
[0036] Step 1: Obtain an MRI prostate original image dataset in a related field, and clean the obtained original image dataset.
[0037] The MRI prostate original image dataset includes images and prostate segmentation labels corresponding to the images;
[0038] Step 2: Use image enhancement technology to enhance the cleaned image data set to increase the number of samples and enrich the data content.
[0039] Step 3: Use morphological methods to corrode the prostate segmentation label corresponding to each image in the enhanced image data set, and then subtract the corroded label from the original label to obtain the label of the prostate edge corresponding to the image.
[0040] Step 4: randomly divide the image data set processed in step 4 into 5 equal data sets.
[0041] Step 5. Build an image segmentation model, use 3D ResBlock as the basic structure, add the IBN module to the encoding network of the image segmentation model, change the maxpool layer to the stride conv layer in the downsampling layer, where the first downsampling uses a 2D convolution kernel and the other downsampling uses a 3D convolution kernel; then connect two decoders in the encoding network, one of which is used to output the segmentation result of the entire prostate, and the other decoder is used to output the segmentation result of the prostate edge.
[0042] Step 6: Based on the five data sets obtained in step 4, the image segmentation model is trained in five folds, and the optimal model obtained from each fold training is fused.
[0043] like Figure 2 As shown in FIG. 1 , it is a structural diagram of the entire semantic segmentation network based on MR image prostate, which is composed of two major modules, the encoding module and the decoding module.
[0044] Step 5.1, encoding stage, adopt the encoding model improved on U-Net for the segmentation task requirements, add IBN structure, IN is invariant to the appearance change of the target, BN has good performance in retaining the features of the feature map, and the combination of the two can greatly improve the model's learning ability and generalization performance for features. Changing the maxpool layer in the original downsampling stage to a stride conv layer is conducive to the model retaining the detailed information of the image, which has a good effect on improving the refinement of the segmentation results.
[0045] like Figure 3 As shown in FIG. 1 , it is a network structure diagram of the present invention. As can be seen from the figure, the encoding network uses 2D downsampling in the first downsampling operation, and 3D downsampling is used in other downsampling operations. The decoder network includes two decoders, one of which performs the segmentation of the prostate as a whole, and the other performs the segmentation of the prostate edge.
[0046] Figure 4 It is the 2D ResBlock structure of the present invention.
[0047] like Figure 5 As shown in FIG. 1 , the 3D ResBlock structure of the present invention is shown. As can be seen from the figure, the IBN structure combining IN and BN is used.
[0048] Step 5.2: In the decoding stage, a dual decoder solution is adopted, in which one decoder is used to output the segmentation result of the entire prostate, and the other decoder is used to output the segmentation result of the prostate edge, so as to help the network strengthen the learning of the segmentation edge.
[0049] The specific implementation process of the model of the present invention is as follows:
[0050] like Figure 3 As shown in the figure, the preprocessed image passes through a 3D residual structure and then enters a 2D downsampling layer. The specific operation is to use a convolution kernel size of 2*2*1 and a convolution span of 2*2*1. Then it enters a structure of alternating 3D convolution and 3D downsampling. After repeating several times, the feature map output by the encoder is copied. The two feature maps obtained are input into two decoders respectively. One decoder outputs the overall segmentation of the prostate, and the other decoder outputs the edge segmentation of the prostate.
[0051] The image is input into the five models obtained by five-fold training respectively, and the overall segmentation result of each model is taken. The five segmentation results are averaged for each pixel. Then, the image is activated by Sigmoid function, and 0.5 is used as the threshold. Points greater than 0.5 are regarded as foreground, and points less than 0.5 are regarded as background to obtain the final segmentation result.
Claims
1. A deep learning-based MRI image segmentation method, characterized in that The following steps are involved: Step 1, obtaining an MRI prostate original image dataset in a related field, and cleaning the obtained original image dataset; The MRI prostate original image dataset includes images and prostate segmentation labels corresponding to the images; Step 2: Use image enhancement technology to enhance the cleaned image data set to increase the number of samples and enrich the data content; Step 3: Using morphological methods, the prostate segmentation label corresponding to each image in the enhanced image data set is corroded, and then the corroded label is subtracted from the original label to obtain the label of the prostate edge corresponding to the image; Step 4: randomly divide the image data set processed in step 3 into 5 equal data sets; Step 5: Build an image segmentation model, add an IBN module to the encoding network of the image segmentation model, then combine the 2D and 3D convolutional layers, and change the maxpool layer to a stride conv layer in the downsampling layer; then connect two decoders in the encoding network, one of which is used to output the segmentation result of the entire prostate, and the other decoder is used to output the segmentation result of the prostate edge; Step 6: Based on the five data sets obtained in step 4, the image segmentation model is trained in five folds, and the optimal model obtained from each fold training is fused; Step 2 specifically includes the following steps: Step 2.1, data morphology enhancement: perform horizontal mirror flipping on the cleaned original image dataset and its annotations; Step 2.2, data space domain enhancement: randomly change the brightness, contrast and gamma value within the set range, while ensuring the physical meaning of the image, and increase the amount of image data; Step 2.3, randomly crop the image data, that is, use the prostate segmentation label of the image in the image data set to obtain the center of the prostate; then let the cropped center randomly jitter within a certain range in the center of the prostate to crop the 64*176*176 image; Step 5 specifically includes the following steps: Step 5.1, the encoding network of the image segmentation model, the image segmentation model adds the IBN module on the basis of the U-Net model; then the maxpool layer in the original downsampling stage of the U-Net model is changed to the stride conv layer, which is conducive to the model retaining the detailed information of the image and has a good effect on improving the precision of the segmentation results; Step 5.2, decoding stage: a dual decoder structure is used, where one decoder is used to output the segmentation result of the entire prostate, and the other decoder is used to output the segmentation result of the prostate edge, to help the network strengthen the learning of the segmentation edge; The preprocessed image passes through a 3D residual structure and then enters a 2D downsampling layer. The specific operation is to use a convolution kernel size of 2*2*1 and a convolution span of 2*2*1; then it enters a structure that alternates 3D convolution and 3D downsampling. After repeating several times, the feature map output by the encoder is copied. The two feature maps obtained are input into two decoders respectively. One decoder outputs the overall segmentation result of the prostate, and the other decoder outputs the prostate edge segmentation result. The image is input into the five models obtained by five-fold training respectively, and the overall segmentation result of each model is taken. The five segmentation results are averaged for each pixel. Then, the image is activated by Sigmoid function, and 0.5 is used as the threshold. Points greater than 0.5 are regarded as foreground, and points less than 0.5 are regarded as background to obtain the final segmentation result.
