Segmentation Method, Device, Computer Equipment and Storage Medium for Brain Tumor Images
By acquiring brain medical images of different morphology and using a three-dimensional segmentation model to generate a fusion of multiple sub-segmented images, the problem of the inability to fully segment brain tumors in the prior art is solved, segmentation efficiency and accuracy are improved, and important organs are protected.
Patent Information
- Application Number
- CN202111612093.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-27
- Publication Date
- 2025-07-22
- Estimated Expiration
- 2041-12-27
AI Technical Summary
The existing brain tumor segmentation methods can only obtain segmentation images under a single quasi-position, and cannot provide detailed segmentation results of multiple quasi-positions, resulting in the inability to fully understand the situation of brain tumors.
By acquiring multiple brain medical images of different morphology, using the trained three-dimensional segmentation model to determine multiple sub-segment images, and fuse them to generate brain tumor segmentation images, the weighted sum method is used to process sub-segment images of different morphology, and improve segmentation efficiency and accuracy.
It realizes the processing of brain medical images of multiple morphological positions at the same time, improves segmentation efficiency, and obtains more detailed and accurate brain tumor segmentation results by fusing multiple sub-segment images, avoiding segmentation omissions and protecting important organs.
Smart Images

Figure CN114299010B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the technical field of medical image processing, and particularly to a method, apparatus, computer device, and storage medium for segmenting brain tumor images. Background Art
[0002] With the wide application of deep learning in medical imaging, in the treatment of brain tumors, in order to clearly display the lesions of brain tumors, an image segmentation method based on deep learning can be used to obtain the segmented images of brain tumors.
[0003] The existing brain tumor segmentation methods use a three-dimensional image segmentation model to automatically segment three-dimensional medical images of the brain to obtain the segmented images of brain tumors. However, the existing brain tumor segmentation methods can only obtain the segmented images of brain tumors in one sagittal position and cannot obtain the segmented images of brain tumors in multiple sagittal positions, and thus cannot obtain the detailed and comprehensive situation of brain tumors. Summary of the Invention
[0004] Based on this, in view of the above technical problems, there is a need to provide a method, apparatus, computer device, computer-readable storage medium, and computer program product for segmenting brain tumor images with high segmentation efficiency and accurate segmentation results.
[0005] In a first aspect, this application provides a method for segmenting brain tumor images. The method includes:
[0006] Obtaining a plurality of brain medical images in different sagittal positions, where the plurality of brain medical images are all three-dimensional images including brain tumors;
[0007] Based on the plurality of brain medical images and a trained three-dimensional segmentation model, determining a plurality of sub-segmented images in different sagittal positions;
[0008] Fusing the plurality of sub-segmented images in different sagittal positions to obtain a brain tumor segmented image.
[0009] In one embodiment, the determining a plurality of sub-segmented images in different sagittal positions based on the plurality of brain medical images and a trained three-dimensional segmentation model includes:
[0010] Converting the plurality of brain medical images into a preset size to obtain a plurality of candidate images;
[0011] Stitching the plurality of candidate images in a preset sagittal position order to obtain a stitched image;
[0012] Inputting the stitched image into a trained three-dimensional segmentation model to obtain a plurality of sub-segmented images in different sagittal positions.
[0013] In one embodiment, the step of fusing a plurality of sub-segmented images with different positions to obtain a brain tumor segmented image includes:
[0014] Determine the volume of the brain tumor in each sub-segmented image, and calculate the total volume based on the volume of the brain tumor in each sub-segmented image; for any sub-segmented image, use the ratio between the volume of the brain tumor in the any sub-segmented image and the total volume as the weight of the any sub-segmented image; perform weighted summation according to the any sub-segmented image and the weight of the any sub-segmented image to obtain a brain tumor segmented image; or, perform weighted summation on the plurality of sub-segmented images with different positions according to a preset weight set to obtain a brain tumor segmented image.
[0015] In one embodiment, the step of fusing a plurality of sub-segmented images with different positions to obtain a brain tumor segmented image includes:
[0016] Perform weighted summation on the plurality of sub-segmented images with different positions according to a preset weight set to obtain a brain tumor segmented image.
[0017] In one embodiment, the trained three-dimensional segmentation model is obtained by training the three-dimensional segmentation model based on a plurality of training image sets and the reference segmentation image of each training image set until the training is completed, wherein each training image set includes: a plurality of training brain medical images with different positions.
[0018] In one embodiment, the step of training the three-dimensional segmentation model based on a plurality of training image sets and the reference segmentation image of each training image set includes:
[0019] Obtain a training image set and the reference segmentation image of the training image set;
[0020] Sample the training brain medical images with each position in the training image set to obtain training sampled images with each position;
[0021] Stitch the training sampled images with each position to obtain a training stitched image;
[0022] Based on the training three-dimensional stitched image and the three-dimensional segmentation model, determine a training segmented image;
[0023] Modify the model parameters of the three-dimensional segmentation model based on the training segmented image and the reference segmentation image, and repeat the process of determining the training segmented image until a preset training condition is met to obtain the trained three-dimensional segmentation model.
[0024] In one embodiment, sampling the training brain medical images of each slice in the training image set to obtain the training sampled images of each slice includes:
[0025] Randomly determine the sampling interval, and sample the training brain medical images of each slice in the training image set according to the randomly determined sampling interval to obtain the training sampled images of each slice.
[0026] In one embodiment, modifying the model parameters of the three-dimensional segmentation model based on the training segmentation image and the reference segmentation image includes:
[0027] Based on the training segmentation image and the reference segmentation image, determine the first loss value through the dice loss function;
[0028] Based on the training segmentation image and the reference segmentation image, determine the second loss value through the focal loss function;
[0029] Perform weighted summation on the first loss value and the second loss value to obtain the total loss value, and modify the model parameters of the three-dimensional segmentation model based on the total loss value.
[0030] In a second aspect, the present application also provides a segmentation device for brain tumor images. The device includes:
[0031] An image acquisition module, configured to acquire a plurality of brain medical images of different slices, where the plurality of brain medical images are all three-dimensional images including brain tumors;
[0032] An image segmentation module, configured to determine a plurality of sub-segmentation images of different slices based on the plurality of brain medical images and the trained three-dimensional segmentation model;
[0033] A fusion module, configured to fuse the plurality of sub-segmentation images of different slices to obtain a brain tumor segmentation image.
[0034] In a third aspect, the present application also provides a computer device. The computer device includes a memory and a processor, the memory stores a computer program, and when the processor executes the computer program, the following steps are implemented:
[0035] Acquire a plurality of brain medical images of different slices, where the plurality of brain medical images are all three-dimensional images including brain tumors;
[0036] Based on the plurality of brain medical images and the trained three-dimensional segmentation model, determine a plurality of sub-segmentation images of different slices;
[0037] Fuse the plurality of sub-segmentation images of different slices to obtain a brain tumor segmentation image.
[0038] Fourthly, the present application also provides a computer-readable storage medium. On the computer-readable storage medium, there is a computer program stored, and when the computer program is executed by a processor, the following steps are implemented:
[0039] Obtain a plurality of brain medical images in different positions, where the plurality of brain medical images are all three-dimensional images including brain tumors;
[0040] Based on the plurality of brain medical images and a trained three-dimensional segmentation model, determine a plurality of sub-segmentation images in different positions;
[0041] Fuse the plurality of sub-segmentation images in different positions to obtain a brain tumor segmentation image.
[0042] Fifthly, the present application also provides a computer program product. The computer program product includes a computer program, and when the computer program is executed by a processor, the following steps are implemented:
[0043] Obtain a plurality of brain medical images in different positions, where the plurality of brain medical images are all three-dimensional images including brain tumors;
[0044] Based on the plurality of brain medical images and a trained three-dimensional segmentation model, determine a plurality of sub-segmentation images in different positions;
[0045] Fuse the plurality of sub-segmentation images in different positions to obtain a brain tumor segmentation image.
[0046] For the above-mentioned method, device, computer device, storage medium and computer program product for segmenting brain tumor images, a plurality of brain medical images in different positions are obtained, and a trained three-dimensional segmentation model is used to process a plurality of brain medical images simultaneously, without using different three-dimensional segmentation models to process brain medical images in different positions respectively, thereby improving the segmentation efficiency; the plurality of sub-segmentation images in different positions are fused to obtain a brain tumor segmentation image. Since it is based on a plurality of brain medical images in different positions to obtain a plurality of sub-segmentation images in different positions, and then the plurality of sub-segmentation images are fused to obtain a brain tumor segmentation image, the features extracted by the trained three-dimensional segmentation model are richer, and more accurate segmentation results can be obtained. BRIEF DESCRIPTION OF THE DRAWINGS
[0047] Figure 1 It is a schematic flowchart of a method for segmenting brain tumor images in an embodiment;
[0048] Figure 2 It is a schematic structural diagram of a trained three-dimensional segmentation model in an embodiment;
[0049] Figure 3Schematic diagram of a method for segmenting brain tumor images in another embodiment;
[0050] Figure 4 Structural block diagram of a device for segmenting brain tumor images in an embodiment;
[0051] Figure 5 Internal structure diagram of a computer device in an embodiment. Detailed implementation manners
[0052] In order to make the objectives, technical solutions and advantages of the present application clearer and more understandable, the present application will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0053] In one embodiment, as Figure 1 shown, a method for segmenting brain tumor images is provided. In this embodiment, an example is given where this method is applied to a terminal. In this embodiment, the method includes the following steps:
[0054] S101. Obtain multiple brain medical images in different positions.
[0055] Among them, the different positions at least include any two of transverse position, sagittal position and coronal position, and the multiple brain medical images are all three-dimensional images including brain tumors.
[0056] Specifically, the brain medical images can be three-dimensional medical images such as Computed Tomography (CT) images and Magnetic Resonance (MR) images. When the different positions include transverse position, sagittal position and coronal position, the medical imaging device scans the brain of the target object from the transverse position, sagittal position and coronal position respectively to obtain multiple brain medical images, including: transverse brain medical images, sagittal brain medical images and coronal brain medical images.
[0057] S102. Based on the multiple brain medical images and the trained three-dimensional segmentation model, determine multiple sub-segmentation images in different positions.
[0058] Specifically, preprocess the multiple brain medical images to obtain a spliced image, input the spliced image into the trained three-dimensional segmentation model, and obtain multiple sub-segmentation images in different positions from the output channels of the trained three-dimensional segmentation model. The spliced image is a three-dimensional image, and the dimension of the spliced image is equal to the sum of the dimensions of the multiple brain medical images. The multiple sub-segmentation images in different positions correspond one by one to the multiple brain medical images in different positions.
[0059] S103. Merge the multiple sub-segmentation images in different positions to obtain a brain tumor segmentation image.
[0060] Specifically, determine the weights of the multiple sub-segmentation images in different positions, and merge the multiple sub-segmentation images in different positions according to the weights of the multiple sub-segmentation images in different positions to obtain a brain tumor segmentation image. The weights are used to reflect the importance degree of the brain tumor in the multiple sub-segmentation images in different positions.
[0061] In the above method for segmenting a brain tumor image, when obtaining multiple brain medical images in different positions and using a trained three-dimensional segmentation model to process multiple brain medical images simultaneously, there is no need to use different three-dimensional segmentation models to process brain medical images in different positions respectively, which improves the segmentation efficiency; merge the multiple sub-segmentation images in different positions to obtain a brain tumor segmentation image. Since it is based on multiple brain medical images in different positions to obtain multiple sub-segmentation images in different positions, and then merge the multiple sub-segmentation images to obtain a brain tumor segmentation image, the features extracted by the trained three-dimensional segmentation model are richer, and a more accurate segmentation result can be obtained.
[0062] In one embodiment, S102 includes:
[0063] S211. Convert the multiple brain medical images into a preset size to obtain multiple candidate images.
[0064] Specifically, perform normalization processing on the multiple brain medical images to obtain multiple candidate images, and the multiple candidate images correspond to the multiple brain medical images one by one. When the multiple brain medical images include axial brain medical images, sagittal brain medical images, and coronal brain medical images, the multiple candidate images include axial candidate images, sagittal candidate images, and coronal candidate images.
[0065] For example, perform normalization processing on the axial brain medical image P11, the sagittal brain medical image P21, and the coronal brain medical image P31 to obtain the axial candidate image P12 of P11, the sagittal candidate image P22 of P21, and the coronal candidate image P32 of P31.
[0066] S212. Stitch the multiple candidate images in a preset position order to obtain a stitched image.
[0067] Specifically, the number of layers of the stitched image is equal to the sum of the number of layers of the multiple brain medical images. The size of the axial candidate image is: W*H*C1, the size of the sagittal candidate image is: W*H*C2, the size of the coronal candidate image is: W*H*C3, and the size of the stitched image is: W*H*C, where C = C1 + C2 + C3.
[0068] The preset slice position order is used to define the order of multiple candidate images of different slice positions in the stitched image. The preset slice position order can be: axial, sagittal, and coronal, or axial, coronal, and sagittal, or other orders.
[0069] If the preset slice position order is: axial, sagittal, and coronal, then in the stitched image, for layer numbers: 1 to C1, they are axial candidate images; for layer numbers: (C1)+1 to (C1)+C2, they are sagittal candidate images; for layer numbers: (C1)+(C2)+1 to (C1)+(C2)+C3, they are coronal candidate images.
[0070] S213. Input the stitched image into the trained 3D segmentation model to obtain multiple sub-segmented images of different slice positions.
[0071] Among them, the multiple sub-segmented images correspond one-to-one with the multiple brain medical images. In one implementation, input the stitched image into the trained 3D segmentation model. The trained 3D segmentation model is provided with multiple channels, and the multiple channels correspond one-to-one with the multiple brain medical images of different slice positions. The sub-segmented image of the corresponding brain medical image is obtained through each channel. For example, when the stitched image is determined based on three brain medical images of different slice positions, the trained 3D segmentation model has three channels, and the sub-segmented images corresponding to the brain medical images of each slice position are respectively taken out in each channel.
[0072] In another implementation, input the stitched image into the trained 3D segmentation model, and output a 3D segmentation image through the 3D segmentation model. The 3D segmentation image includes multiple sub-segmented images of different slice positions; according to the sizes of the multiple candidate images of different slice positions and the preset slice position order, determine multiple sub-segmented images of different slice positions in the 3D segmentation image.
[0073] Specifically, according to the sizes of the multiple candidate images of different slice positions and the preset slice position order, the layer numbers corresponding to the sub-segmented images of each slice position can be determined. For example, the preset slice position order is: sagittal, coronal, and axial. The layer number of the axial candidate image is C1, the layer number of the sagittal candidate image is C2, and the layer number of the coronal candidate image is C3. Then in the 3D segmentation image, for layer numbers: 1 to C2, they are the sub-segmented images of the sagittal position; for layer numbers: (C2)+1 to (C1)+C2, they are the sub-segmented images of the axial position; for layer numbers: (C1)+(C2)+1 to (C1)+(C2)+C3, they are the sub-segmented images of the coronal position.
[0074] The trained 3D segmentation model can be AnatomyNet; the core network of the trained 3D segmentation model is 3D Unet, which replaces the standard convolutional layers in 3D Unet with 3D SE (Squeeze-and-Excitation) residual blocks and only retains one downsampling module in 3D Unet to improve the segmentation performance of small anatomical structures.
[0075] As Figure 2 shown, the trained 3D segmentation model includes: downsampling module conv1, first SE module se1, second SE module se2,..., fifteenth SE module se15, first connection module concat1, second connection module concat2, third connection module concat3, fourth connection module concat4, transposed convolution module T-conv, first convolution module conv2, and second convolution module conv3.
[0076] In one embodiment, S103 includes:
[0077] S311A, determining the volume of the brain tumor in each sub-segmented image and calculating the total volume based on the volume of the brain tumor in each sub-segmented image.
[0078] Specifically, the sub-segmented image is a 3D image, and the trained 3D segmentation model is used to classify each voxel in the candidate image. In the obtained sub-segmented image, there are multiple voxels classified as the tumor region and multiple voxels classified as the non-tumor region; for any sub-segmented image, the volume of the brain tumor in the any sub-segmented image is determined according to the multiple voxels classified as the tumor region in the any sub-segmented image. Adding up the volumes of the brain tumors in each sub-segmented image gives the total volume.
[0079] S312A, for any sub-segmented image, taking the ratio between the volume of the brain tumor in the any sub-segmented image and the total volume as the weight of the any sub-segmented image.
[0080] Specifically, the weight of the any sub-segmented image is used to reflect the size of the volume of the brain tumor in the any sub-segmented image. For example, if the volume of the brain tumor in the sagittal sub-segmented image is V1, the volume of the brain tumor in the transverse sub-segmented image is V2, and the volume of the brain tumor in the coronal sub-segmented image is V3, and the total volume is: V = V1 + V2 + V3, then the weight of the sagittal sub-segmented image can be obtained as: V1 / V, the weight of the transverse sub-segmented image is: V2 / V, and the weight of the coronal sub-segmented image is: V3 / V.
[0081] S313A, perform a weighted sum based on any of the sub-segmented images and the weight of any of the sub-segmented images to obtain a brain tumor segmented image.
[0082] Specifically, for any pixel point in the brain medical image, determine the pixel value of the any pixel point in each sub-segmented image, and perform a weighted sum according to the pixel value of the any pixel point in each sub-segmented image and the weight of each sub-segmented image to obtain the segmentation value of the any pixel point. According to the segmentation values of each pixel point in the brain medical image, obtain a brain tumor segmented image.
[0083] In this embodiment, the ratio between the volume of the brain tumor in any of the sub-segmented images and the total volume is used as the weight of any of the sub-segmented images. The obtained brain tumor segmented image tends to the sub-segmentation result with a larger volume, which can avoid the omission of the target area segmentation to a certain extent and protect the organs at risk and kill the tumor as much as possible.
[0084] In another embodiment, S103 includes:
[0085] S311B, perform a weighted sum on the multiple sub-segmented images of different positions according to a preset weight set to obtain a brain tumor segmented image.
[0086] Specifically, preset the weight of each position. After obtaining the multiple sub-segmented images of different positions, perform a weighted sum according to the weight of each position and the sub-segmented image of each position to obtain a brain tumor segmented image.
[0087] For example, the preset weight set includes: the weight w1 of the sagittal position = 1 / 3, the weight w2 of the transverse position = 1 / 3, and the weight w1 of the coronal position = 1 / 3.
[0088] In one embodiment, after S103, it further includes: performing Gaussian smoothing on the brain tumor segmented image, and calculating the largest connected component operation to obtain a target segmented image, and replacing the brain tumor segmented image with the target segmented image.
[0089] Specifically, both Gaussian smoothing and the operation of calculating the largest connected component can be implemented by existing methods. Performing Gaussian smoothing on the brain tumor segmented image can filter out noise; there may be some false positive regions (small useless contours) in the brain tumor segmented image obtained according to the trained 3D segmentation model. By the largest connected component operation, the small independent regions with smaller areas can be removed, and the larger connected regions can be retained to obtain a target segmented image. The larger region in the target segmented image corresponds to the brain tumor.
[0090] The process of the segmentation method of the brain tumor image is as Figure 3As shown, a spliced image F1 is determined based on a transverse brain medical image E1, a coronal brain medical image E2 and a sagittal brain medical image E3; the spliced image F1 is input into a trained three-dimensional segmentation model to obtain a transverse sub-segmented image G1, a coronal sub-segmented image G2 and a sagittal sub-segmented image G3, and the weights of G1, G2 and G3 are determined respectively, and a weighted sum is performed on G1, G2 and G3 to obtain a brain segmentation image H.
[0091] In one embodiment, the trained three-dimensional segmentation model is obtained by training the three-dimensional segmentation model based on multiple training image sets and a reference segmentation image of each training image set until the training is completed.
[0092] Wherein, each training image set includes: a plurality of training brain medical images in different positions. When using the trained three-dimensional segmentation model, the positions of the plurality of brain medical images are the same as the positions of the plurality of training brain medical images when training the three-dimensional segmentation model. For example, when training, the plurality of training brain medical images in different positions include: sagittal training brain medical images, coronal training brain medical images and transverse training brain medical images, then when using, the plurality of brain medical images in different positions include: sagittal brain medical images, coronal brain medical images and transverse brain medical images.
[0093] Specifically, the training of the three-dimensional segmentation model based on multiple training image sets and a reference segmentation image of each training image set includes:
[0094] S01, obtaining a training image set and a reference segmented image of the training image set.
[0095] Specifically, a training image set is obtained from multiple training image sets, the training image set includes multiple training brain medical images of different positions, and the reference segmentation image of the training image set is a delineation image of a brain tumor, which is equivalent to the gold standard of the training image set. The training brain medical images of different positions in a training image set are brain medical images of the same patient, and the reference segmentation image of the training image set is an image obtained by delineating the brain tumor of the patient layer by layer.
[0096] S02, sampling the training brain medical image of each state position in the training image set to obtain a training sampling image of each state position.
[0097] Specifically, the training brain medical images can be regarded as multi-layer two-dimensional brain medical images. Since directly stitching multiple sagittal training brain medical images together, the number of layers will be very large, resulting in a large amount of computation and a slow training speed of the model. Therefore, each sagittal training brain medical image is sampled to obtain the training sampled image for each sagittal. Any part of the two-dimensional brain medical image in any sagittal training brain medical image is included in the training sampled image for any sagittal.
[0098] In one implementation, a preset sampling interval is used to sample each sagittal training brain medical image in the training image set to obtain the training sampled image for each sagittal. The preset sampling interval can be determined according to the number of layers of the two-dimensional brain medical images in the training image set.
[0099] In another implementation, the sampling interval is randomly determined, and each sagittal training brain medical image in the training image set is sampled according to the randomly determined sampling interval to obtain the training sampled image for each sagittal.
[0100] Specifically, each time of training, the sampling interval is randomly determined, and the training image set is sampled according to the randomly determined sampling interval; since the sampling interval is randomly determined, the sampling intervals used in multiple trainings may be different. In addition to reducing the amount of computation, it can also make the input features of the 3D segmentation model more diverse.
[0101] S03, Stitch the training sampled images for each sagittal to obtain the training stitched image. Based on the training three-dimensional stitched image and the 3D segmentation model, determine the training segmented image.
[0102] Specifically, the training sampled images for each sagittal are stitched in a preset sagittal order to obtain the training stitched image. The preset sagittal order used to stitch multiple candidate images in S212 is the same as the preset sagittal order for stitching the training sampled images for each sagittal here.
[0103] Input the training three-dimensional stitched image into the 3D segmentation model to obtain the training sub-segmented image for each sagittal, determine the volume of the brain tumor in the training sub-segmented image for each sagittal, and calculate the total training volume based on the volume of the brain tumor in each training sub-segmented image. For any training sub-segmented image, the ratio between the volume of the brain tumor in the any training sub-segmented image and the total training volume is used as the weight of the any training sub-segmented image. Weighted solution is performed according to any sub-training segmented image and the weight of any sub-training segmented image to obtain the training segmented image.
[0104] S04. Modify the model parameters of the three-dimensional segmentation model based on the training segmentation image and the reference segmentation image, and repeat the above process of determining the training segmentation image until the preset training conditions are met, and obtain the trained three-dimensional segmentation model.
[0105] Specifically, calculate the loss function value according to the reference segmentation image and the training segmentation image, and then modify the model parameters of the three-dimensional segmentation model according to the loss function value, then one training is completed. Repeat the above process of the training segmentation image to repeat the training multiple times until the preset training conditions are met, and obtain the trained three-dimensional segmentation model. The preset training condition may be that the three-dimensional segmentation model converges. The model structures of the three-dimensional segmentation model and the trained three-dimensional segmentation model are the same.
[0106] The modifying the model parameters of the three-dimensional segmentation model based on the training segmentation image and the reference segmentation image includes:
[0107] Based on the training segmentation image and the reference segmentation image, determine the first loss value through the Dice loss function; based on the training segmentation image and the reference segmentation image, determine the second loss value through the Focus loss function; perform weighted summation on the first loss value and the second loss value to obtain the total loss value, and modify the model parameters of the three-dimensional segmentation model based on the total loss value.
[0108] Specifically, calculate the first loss value between the training segmentation image and the reference segmentation image through the Dice loss function, calculate the second loss value between the training segmentation image and the reference segmentation image through the Focus loss function, determine the first loss weight of the Dice loss and the second loss weight of the Focus loss, obtain the total loss value according to the first loss weight, the first loss value, the second loss weight and the second loss value, and modify the model parameters of the three-dimensional segmentation model through the total loss value. Using the Dice loss and the Focus loss to jointly train the three-dimensional segmentation model can improve the detection ability of the three-dimensional segmentation model for small targets. During the training process, the first loss weight and the second loss weight can be adjusted to adjust the balance of the learning objectives of the three-dimensional segmentation model.
[0109] Since random interval sampling is used when sampling the training brain medical images for each slice position, in the next training, the training image set used in the previous training can also be used, and the number of times each training image set is used can be set according to requirements.
[0110] In the process of training a 3D segmentation model to obtain the trained 3D segmentation model, random interval sampling is performed on the training brain medical images in each sagittal position, reducing the dimension of the images input into the 3D segmentation model. Random interval sampling also increases the diversity of the input features, which can improve the segmentation efficiency and accuracy of the model.
[0111] In a specific embodiment, the method for segmenting a brain tumor image includes:
[0112] M01, obtaining a plurality of training image sets and the reference segmentation images corresponding to each training image set, where each training image set includes: sagittal training brain medical images, coronal training brain medical images, and transverse training brain medical images.
[0113] M02, obtaining a training image set A1 from the plurality of training image sets. A1 includes: a sagittal training brain medical image a1, a coronal training brain medical image b1, and a transverse training brain medical image c1. Denote the reference image of A1 as: d1.
[0114] M03, performing random interval sampling on a1, b1, and c1 respectively to obtain a2, b2, and c2.
[0115] M04, converting a2, b2, and c2 to a preset size, and then splicing them in a preset sagittal position order to obtain a training spliced image Q1. Input Q1 into the 3D segmentation model to obtain a training segmentation image e1.
[0116] M05, calculating the loss function value according to e1 and d1, and modifying the model parameters of the 3D segmentation model according to the loss function value.
[0117] M06, continue to execute M02 to M05 until the preset training conditions are met to obtain the trained 3D segmentation model.
[0118] M10, obtaining a sagittal brain medical image a3, a coronal brain medical image b3, and a transverse brain medical image c3 of a patient;
[0119] M11, converting a3, b3, and c3 to a preset size, and then splicing them in a preset sagittal position order to obtain a spliced image Q2;
[0120] M12, inputting Q2 into the trained 3D segmentation model, and obtaining a sagittal sub-segmentation image a4, a coronal sub-segmentation image b4, and a transverse sub-segmentation image c4 from the channels of the trained 3D segmentation model;
[0121] M13, respectively determining the volumes of the brain tumors in a4, b4, and c4, and determining the weights of a4, b4, and c4 according to the volumes of the brain tumors in a4, b4, and c4;
[0122] M14 performs weighted summation based on a4, b4, c4, and the weights of a4, b4, and c4 to obtain a brain tumor segmentation image.
[0123] In this embodiment, during the process of training the 3D segmentation model, random interval sampling is performed on the training brain medical images in each sagittal position, reducing the dimension of the images input to the 3D segmentation model. Random interval sampling also increases the diversity of the input features, which can improve the segmentation efficiency and accuracy of the model.
[0124] During the use of the trained 3D segmentation model, multiple brain medical images in different sagittal positions are obtained. By using a trained 3D segmentation model to simultaneously process multiple brain medical images in different sagittal positions, it is not necessary to use different 3D segmentation models to separately process the brain medical images in different sagittal positions, improving the segmentation efficiency.
[0125] Based on the trained 3D segmentation model, multiple brain medical images in different sagittal positions are obtained. The ratio between the volume of the brain tumor in any sub-segmentation image and the total volume is used as the weight of the any sub-segmentation image. The brain tumor segmentation image calculated by weighted summation tends to the sub-segmentation result with a larger volume, which can avoid the omission of the target area in segmentation to a certain extent and protect the organs at risk and kill tumors as much as possible.
[0126] Since the brain tumor segmentation image is obtained based on multiple brain medical images in different sagittal positions, the features extracted by the trained 3D segmentation model are more abundant, making the brain tumor segmentation image more accurate.
[0127] It should be understood that although the steps in the flowcharts involved in the above-mentioned embodiments are shown in sequence according to the indication of the arrows, these steps do not necessarily need to be executed in the order indicated by the arrows. Unless there is a clear indication in this article, the execution of these steps has no strict order limit, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments may include multiple steps or multiple stages. These steps or stages do not necessarily need to be executed at the same moment, but can be executed at different moments. The execution order of these steps or stages is not necessarily sequential, but can be executed alternately or in turn with at least a part of other steps or steps in other steps.
[0128] Based on the same inventive concept, an embodiment of the present application further provides a brain tumor image segmentation device for implementing the above-mentioned brain tumor image segmentation method. The solution provided by this device for solving problems is similar to the solution described in the above method. Therefore, the specific limitations in one or more embodiments of the brain tumor image segmentation device provided below can refer to the limitations on the brain tumor image segmentation method in the foregoing, and will not be elaborated here.
[0129] In one embodiment, as Figure 4 shown, a brain tumor image segmentation device is provided, including:
[0130] An image acquisition module, configured to acquire a plurality of brain medical images in different positions, wherein the plurality of brain medical images are all three-dimensional images including brain tumors;
[0131] An image segmentation module, configured to determine a plurality of sub-segmented images in different positions based on the plurality of brain medical images and a trained three-dimensional segmentation model;
[0132] A fusion module, configured to fuse the plurality of sub-segmented images in different positions to obtain a brain tumor segmentation image.
[0133] In one embodiment, the image segmentation module includes:
[0134] A preprocessing unit, configured to convert the plurality of brain medical images into a preset size to obtain a plurality of candidate images;
[0135] A splicing unit, configured to splice the plurality of candidate images in a preset position order to obtain a spliced image;
[0136] A sub-segmented image determination unit, configured to input the spliced image into a trained three-dimensional segmentation model to obtain a plurality of sub-segmented images in different positions.
[0137] In one embodiment, the fusion module includes:
[0138] A first fusion unit, configured to determine the volume of the brain tumor in each sub-segmented image, and calculate the total volume based on the volume of the brain tumor in each sub-segmented image; for any one of the sub-segmented images, use the ratio between the volume of the brain tumor in the any one of the sub-segmented images and the total volume as the weight of the any one of the sub-segmented images; perform weighted summation according to the any one of the sub-segmented images and the weight of the any one of the sub-segmented images to obtain a brain tumor segmentation image; or,
[0139] A second fusion unit, configured to perform weighted summation on the plurality of sub-segmented images in different positions according to a preset weight set to obtain a brain tumor segmentation image.
[0140] In one embodiment, the trained 3D segmentation model is obtained by training a 3D segmentation model based on a plurality of training image sets and the reference segmentation images of each training image set until the training is completed, wherein each training image set includes: a plurality of training brain medical images in different positions.
[0141] In one embodiment, the training of the 3D segmentation model based on a plurality of training image sets and the reference segmentation images of each training image set includes:
[0142] Obtain a training image set and the reference segmentation image of the training image set;
[0143] Sample the training brain medical images in each position of the training image set to obtain training sampled images for each position;
[0144] Stitch the training sampled images for each position to obtain a training stitched image;
[0145] Based on the training 3D stitched image and the 3D segmentation model, determine a training segmentation image;
[0146] Modify the model parameters of the 3D segmentation model based on the training segmentation image and the reference segmentation image, and repeat the process of determining the training segmentation image until a preset training condition is met to obtain the trained 3D segmentation model.
[0147] In one embodiment, the sampling of the training brain medical images in each position of the training image set to obtain training sampled images for each position includes:
[0148] Randomly determine a sampling interval, and sample the training brain medical images in each position of the training image set according to the randomly determined sampling interval to obtain training sampled images for each position.
[0149] The modification of the model parameters of the 3D segmentation model based on the training segmentation image and the reference segmentation image includes:
[0150] Based on the training segmentation image and the reference segmentation image, determine a first loss value through a dice loss function;
[0151] Based on the training segmentation image and the reference segmentation image, determine a second loss value through a focal loss function;
[0152] Perform a weighted sum of the first loss value and the second loss value to obtain a total loss value, and modify the model parameters of the 3D segmentation model based on the total loss value.
[0153] Each module in the above-mentioned brain tumor image segmentation device can be implemented in whole or in part by software, hardware, and their combination. Each of the above modules can be embedded in the processor of the computer device in hardware form or be independent of it, or be stored in the memory of the computer device in software form, so as to facilitate the processor to call and execute the operations corresponding to each of the above modules.
[0154] In one embodiment, a computer device is provided. The computer device can be a terminal, and its internal structure diagram can be as Figure 5 shown. The computer device includes a processor, a memory, a communication interface, a display screen, and an input device connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner. The wireless manner can be implemented through WIFI, a mobile cellular network, NFC (Near Field Communication), or other technologies. When the computer program is executed by the processor, it realizes a method for segmenting brain tumor images. The display screen of the computer device can be a liquid crystal display screen or an electronic ink display screen. The input device of the computer device can be a touch layer covering the display screen, or a button, a trackball, or a touchpad provided on the housing of the computer device, or an external keyboard, a touchpad, or a mouse, etc.
[0155] Those skilled in the art can understand that Figure 5 the structure shown in
[0156] is only a block diagram of some structures related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine some components, or have different component arrangements.
[0157] Obtain multiple brain medical images in different positions, where the multiple brain medical images are all three-dimensional images including brain tumors;
[0158] Based on the multiple brain medical images and the trained three-dimensional segmentation model, determine multiple sub-segmentation images in different positions;
[0159] Fuse the multiple sub-segmentation images in different positions to obtain a brain tumor segmentation image.
[0160] In one embodiment, when the processor executes the computer program, the following steps are further implemented:
[0161] Based on the multiple brain medical images and the trained three-dimensional segmentation model, determining multiple sub-segmentation images in different sagittal positions, including:
[0162] Converting the multiple brain medical images into a preset size to obtain multiple candidate images;
[0163] Stitching the multiple candidate images in a preset sagittal order to obtain a stitched image;
[0164] Inputting the stitched image into the trained three-dimensional segmentation model to obtain multiple sub-segmentation images in different sagittal positions.
[0165] In one embodiment, when the processor executes the computer program, the following steps are further implemented:
[0166] Fusing the multiple sub-segmentation images in different sagittal positions to obtain a brain tumor segmentation image, including:
[0167] Determining the volume of the brain tumor in each sub-segmentation image, and calculating the total volume based on the volume of the brain tumor in each sub-segmentation image; for any one of the sub-segmentation images, taking the ratio between the volume of the brain tumor in the any one of the sub-segmentation images and the total volume as the weight of the any one of the sub-segmentation images; performing weighted summation according to the any one of the sub-segmentation images and the weight of the any one of the sub-segmentation images to obtain a brain tumor segmentation image; or,
[0168] Performing weighted summation on the multiple sub-segmentation images in different sagittal positions according to a preset weight set to obtain a brain tumor segmentation image.
[0169] In one embodiment, when the processor executes the computer program, the following steps are further implemented:
[0170] The trained three-dimensional segmentation model is obtained by training the three-dimensional segmentation model based on multiple training image sets and the reference segmentation image of each training image set, wherein each training image set includes: multiple training brain medical images in different sagittal positions.
[0171] In one embodiment, when the processor executes the computer program, the following steps are further implemented:
[0172] Training the three-dimensional segmentation model based on multiple training image sets and the reference segmentation image of each training image set, including:
[0173] Obtaining a training image set and the reference segmentation image of the training image set;
[0174] Sample the training brain medical images at each slice position in the training image set to obtain the training sampled images at each slice position;
[0175] Stitch the training sampled images at each slice position to obtain a training stitched image;
[0176] Based on the training 3D stitched image and the 3D segmentation model, determine a training segmentation image;
[0177] Modify the model parameters of the 3D segmentation model based on the training segmentation image and the reference segmentation image, and repeat the process of determining the training segmentation image above until a preset training condition is met to obtain the trained 3D segmentation model.
[0178] In one embodiment, when the processor executes the computer program, the following steps are further implemented:
[0179] The sampling of the training brain medical images at each slice position in the training image set to obtain the training sampled images at each slice position includes:
[0180] Randomly determine a sampling interval, and sample the training brain medical images at each slice position in the training image set according to the randomly determined sampling interval to obtain the training sampled images at each slice position.
[0181] In one embodiment, when the processor executes the computer program, the following steps are further implemented:
[0182] The modifying the model parameters of the 3D segmentation model based on the training segmentation image and the reference segmentation image includes:
[0183] Based on the training segmentation image and the reference segmentation image, determine a first loss value through a dice loss function;
[0184] Based on the training segmentation image and the reference segmentation image, determine a second loss value through a focal loss function;
[0185] Perform a weighted sum of the first loss value and the second loss value to obtain a total loss value, and modify the model parameters of the 3D segmentation model based on the total loss value.
[0186] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:
[0187] Obtain multiple brain medical images at different slice positions, where the multiple brain medical images are all 3D images including brain tumors;
[0188] Based on the multiple brain medical images and the trained 3D segmentation model, determine multiple sub-segmentation images at different slice positions;
[0189] Fuse the multiple sub-segmentation images in different positions to obtain a brain tumor segmentation image.
[0190] In one embodiment, when the computer program is executed by a processor, the following steps are further implemented:
[0191] Determining the multiple sub-segmentation images in different positions based on the multiple brain medical images and the trained three-dimensional segmentation model includes:
[0192] Convert the multiple brain medical images into a preset size to obtain multiple candidate images;
[0193] Stitch the multiple candidate images in a preset position order to obtain a stitched image;
[0194] Input the stitched image into the trained three-dimensional segmentation model to obtain multiple sub-segmentation images in different positions.
[0195] In one embodiment, when the computer program is executed by a processor, the following steps are further implemented:
[0196] The step of fusing the multiple sub-segmentation images in different positions to obtain a brain tumor segmentation image includes: determining the volume of the brain tumor in each sub-segmentation image, and calculating the total volume based on the volume of the brain tumor in each sub-segmentation image; for any one of the sub-segmentation images, taking the ratio between the volume of the brain tumor in the any one of the sub-segmentation images and the total volume as the weight of the any one of the sub-segmentation images; performing weighted summation according to the any one of the sub-segmentation images and the weight of the any one of the sub-segmentation images to obtain a brain tumor segmentation image; or,
[0197] Perform weighted summation on the multiple sub-segmentation images in different positions according to a preset weight set to obtain a brain tumor segmentation image.
[0198] In one embodiment, when the computer program is executed by a processor, the following steps are further implemented:
[0199] The trained three-dimensional segmentation model is obtained by training the three-dimensional segmentation model based on multiple training image sets and the reference segmentation image of each training image set until the training is completed, wherein each training image set includes: multiple training brain medical images in different positions.
[0200] In one embodiment, when the computer program is executed by a processor, the following steps are further implemented:
[0201] The training of the three-dimensional segmentation model based on multiple training image sets and the reference segmentation image of each training image set includes:
[0202] Obtain a training image set and a reference segmentation image of the training image set;
[0203] Sample the training brain medical images at each slice position in the training image set to obtain training sampled images at each slice position;
[0204] Stitch the training sampled images at each slice position to obtain a training stitched image;
[0205] Based on the training three-dimensional stitched image and the three-dimensional segmentation model, determine a training segmentation image;
[0206] Modify the model parameters of the three-dimensional segmentation model based on the training segmentation image and the reference segmentation image, and repeat the process of determining the training segmentation image until a preset training condition is met to obtain the trained three-dimensional segmentation model.
[0207] In one embodiment, when the computer program is executed by a processor, the following steps are further implemented:
[0208] The sampling of the training brain medical images at each slice position in the training image set to obtain training sampled images at each slice position includes:
[0209] Randomly determine a sampling interval, and sample the training brain medical images at each slice position in the training image set according to the randomly determined sampling interval to obtain training sampled images at each slice position.
[0210] In one embodiment, the modifying the model parameters of the three-dimensional segmentation model based on the training segmentation image and the reference segmentation image includes:
[0211] Based on the training segmentation image and the reference segmentation image, determine a first loss value through a dice loss function;
[0212] Based on the training segmentation image and the reference segmentation image, determine a second loss value through a focal loss function;
[0213] Perform a weighted sum of the first loss value and the second loss value to obtain a total loss value, and modify the model parameters of the three-dimensional segmentation model based on the total loss value.
[0214] In one embodiment, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, the following steps are implemented:
[0215] Obtain multiple brain medical images at different slice positions, where the multiple brain medical images are all three-dimensional images including brain tumors;
[0216] Based on the multiple brain medical images and the trained three-dimensional segmentation model, determine multiple sub-segmentation images at different slice positions;
[0217] Fuse the multiple sub-segmentation images in different positions to obtain a brain tumor segmentation image.
[0218] In one embodiment, when the computer program is executed by a processor, the following steps are further implemented:
[0219] Determining the multiple sub-segmentation images in different positions based on the multiple brain medical images and the trained three-dimensional segmentation model includes:
[0220] Convert the multiple brain medical images into a preset size to obtain multiple candidate images;
[0221] Stitch the multiple candidate images in a preset position order to obtain a stitched image;
[0222] Input the stitched image into the trained three-dimensional segmentation model to obtain multiple sub-segmentation images in different positions.
[0223] In one embodiment, when the computer program is executed by a processor, the following steps are further implemented:
[0224] The step of fusing the multiple sub-segmentation images in different positions to obtain a brain tumor segmentation image includes:
[0225] Determine the volume of the brain tumor in each sub-segmentation image, and calculate the total volume based on the volume of the brain tumor in each sub-segmentation image; for any one of the sub-segmentation images, use the ratio between the volume of the brain tumor in the any one of the sub-segmentation images and the total volume as the weight of the any one of the sub-segmentation images; perform weighted summation according to the any one of the sub-segmentation images and the weight of the any one of the sub-segmentation images to obtain a brain tumor segmentation image; or,
[0226] Perform weighted summation on the multiple sub-segmentation images in different positions according to a preset weight set to obtain a brain tumor segmentation image.
[0227] In one embodiment, when the computer program is executed by a processor, the following steps are further implemented:
[0228] The trained three-dimensional segmentation model is obtained by training the three-dimensional segmentation model based on multiple training image sets and the reference segmentation image of each training image set until the training is completed, wherein each training image set includes: multiple training brain medical images in different positions.
[0229] In one embodiment, when the computer program is executed by a processor, the following steps are further implemented:
[0230] The training of the three-dimensional segmentation model based on multiple training image sets and the reference segmentation image of each training image set includes:
[0231] Obtain a training image set and a reference segmentation image of the training image set;
[0232] Sample the training brain medical images at each slice position in the training image set to obtain training sampled images at each slice position;
[0233] Stitch the training sampled images at each slice position to obtain a training stitched image;
[0234] Based on the training 3D stitched image and the 3D segmentation model, determine a training segmentation image;
[0235] Modify the model parameters of the 3D segmentation model based on the training segmentation image and the reference segmentation image, and repeat the process of determining the training segmentation image until a preset training condition is satisfied, to obtain the trained 3D segmentation model.
[0236] In one embodiment, when the computer program is executed by a processor, the following steps are further implemented:
[0237] The step of sampling the training brain medical images at each slice position in the training image set to obtain training sampled images at each slice position includes:
[0238] Randomly determine a sampling interval, and sample the training brain medical images at each slice position in the training image set according to the randomly determined sampling interval to obtain training sampled images at each slice position.
[0239] In one embodiment, the step of modifying the model parameters of the 3D segmentation model based on the training segmentation image and the reference segmentation image includes:
[0240] Based on the training segmentation image and the reference segmentation image, determine a first loss value through a dice loss function;
[0241] Based on the training segmentation image and the reference segmentation image, determine a second loss value through a focal loss function;
[0242] Perform a weighted sum of the first loss value and the second loss value to obtain a total loss value, and modify the model parameters of the 3D segmentation model based on the total loss value.
[0243] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data for analysis, stored data, displayed data, etc.) involved in this application are all information and data that have been authorized by the user or fully authorized by all parties.
[0244] Those of ordinary skill in the art can understand that all or part of the processes in the methods of the above embodiments can be completed by instructing relevant hardware through a computer program. The computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above methods. Among them, any reference to a memory, database, or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memories. Non-volatile memories can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memories can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM), etc. The databases involved in the embodiments provided in the present application can include at least one of relational databases and non-relational databases. Non-relational databases can include distributed databases based on blockchain, etc., without limitation. The processors involved in the embodiments provided in the present application can be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, data processing logics based on quantum computing, etc., without limitation.
[0245] The technical features of the above embodiments can be combined arbitrarily. For the sake of concise description, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, it should be considered as the scope described in this specification.
[0246] The above-described embodiments merely represent several implementation manners of the present application. Their descriptions are relatively specific and detailed, but they should not be construed as limiting the patent scope of the present application. It should be noted that for those of ordinary skill in the art, without departing from the concept of the present application, several modifications and improvements can still be made, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the appended claims.
Claims
1. A method for segmenting brain tumor images, characterized in that, The method includes: Obtaining multiple brain medical images in different positions, where the multiple brain medical images are all three-dimensional images including brain tumors; Based on the multiple brain medical images and a trained three-dimensional segmentation model, determining multiple sub-segmentation images in different positions; Fusing the multiple sub-segmentation images in different positions to obtain a brain tumor segmentation image; performing Gaussian smoothing on the brain tumor segmentation image and calculating the largest connected component operation to obtain a target segmentation image, and replacing the brain tumor segmentation image with the target segmentation image; Among them, the determining multiple sub-segmentation images in different positions based on the multiple brain medical images and the trained three-dimensional segmentation model includes: Converting the multiple brain medical images into a preset size to obtain multiple candidate images; Stitching the multiple candidate images in a preset position order to obtain a stitched image; Inputting the stitched image into the trained three-dimensional segmentation model to obtain multiple sub-segmentation images in different positions; The fusing the multiple sub-segmentation images in different positions to obtain a brain tumor segmentation image includes: Determining the volume of the brain tumor in each sub-segmentation image, and calculating the total volume based on the volume of the brain tumor in each sub-segmentation image; for any sub-segmentation image, taking the ratio between the volume of the brain tumor in the any sub-segmentation image and the total volume as the weight of the any sub-segmentation image; performing weighted summation according to the any sub-segmentation image and the weight of the any sub-segmentation image to obtain a brain tumor segmentation image.
2. The method according to claim 1, wherein The trained three-dimensional segmentation model is obtained by training the three-dimensional segmentation model based on multiple training image sets and the reference segmentation image of each training image set until the training is completed, where each training image set includes: multiple training brain medical images in different positions.
3. The method according to claim 2, characterized in that The training the three-dimensional segmentation model based on multiple training image sets and the reference segmentation image of each training image set includes: Obtaining a training image set and the reference segmentation image of the training image set; Sampling the training brain medical images in each position of the training image set to obtain training sampling images in each position; Stitching the training sampling images in each position to obtain a training stitched image; Based on the training three-dimensional stitched image and the three-dimensional segmentation model, determining a training segmentation image; Modifying the model parameters of the three-dimensional segmentation model based on the training segmentation image and the reference segmentation image, and repeating the process of determining the training segmentation image until a preset training condition is met to obtain the trained three-dimensional segmentation model.
4. The method according to claim 3, characterized in that, The sampling the training brain medical images in each position of the training image set to obtain training sampling images in each position includes: Randomly determining a sampling interval, and sampling the training brain medical images in each position of the training image set according to the randomly determined sampling interval to obtain training sampling images in each position.
5. The method according to claim 3, wherein The modifying the model parameters of the three-dimensional segmentation model based on the training segmentation image and the reference segmentation image includes: Based on the training segmentation image and the reference segmentation image, determine a first loss value through a dice loss function; Based on the training segmentation image and the reference segmentation image, determine a second loss value through a focal loss function; Perform weighted summation on the first loss value and the second loss value to obtain a total loss value, and modify the model parameters of the three-dimensional segmentation model based on the total loss value.
6. The method according to claim 1, wherein The inputting the stitched image into the trained three-dimensional segmentation model to obtain multiple sub-segmentation images in different positions includes: Input the stitched image into the trained three-dimensional segmentation model to obtain a three-dimensional segmentation image; According to the sizes of the multiple candidate images in different positions and the preset position order, determine multiple sub-segmentation images in different positions in the three-dimensional segmentation image.
7. A segmentation device for brain tumor images, characterized in that, The device includes: An image acquisition module, configured to acquire multiple brain medical images in different positions, where the multiple brain medical images are all three-dimensional images including brain tumors; An image segmentation module, configured to determine multiple sub-segmentation images in different positions based on the multiple brain medical images and the trained three-dimensional segmentation model; A fusion module, configured to fuse the multiple sub-segmentation images in different positions to obtain a brain tumor segmentation image; perform Gaussian smoothing on the brain tumor segmentation image, and perform a maximum connected component operation to obtain a target segmentation image, and use the target segmentation image to replace the brain tumor segmentation image; The image segmentation module includes: A preprocessing unit, configured to convert the multiple brain medical images into a preset size to obtain multiple candidate images; A stitching unit, configured to stitch the multiple candidate images in a preset position order to obtain a stitched image; A sub-segmentation image determination unit, configured to input the stitched image into the trained three-dimensional segmentation model to obtain multiple sub-segmentation images in different positions; The fusion module includes: A first fusion unit, configured to determine the volume of the brain tumor in each sub-segmentation image, and calculate the total volume based on the volume of the brain tumor in each sub-segmentation image; for any one sub-segmentation image, use the ratio between the volume of the brain tumor in the any one sub-segmentation image and the total volume as the weight of the any one sub-segmentation image; perform weighted summation according to the any one sub-segmentation image and the weight of the any one sub-segmentation image to obtain a brain tumor segmentation image.
8. A computer device, comprising a memory and a processor, the memory storing a computer program, characterized in that, When the processor executes the computer program, the steps of the method according to any one of claims 1 to 6 are implemented.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, the steps of the method according to any one of claims 1 to 6 are implemented.
10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by the processor, the steps of the method according to any one of claims 1 to 6 are implemented.
Citation Information
Patent Citations
Atrium full-automatic segmentation tracking and positioning method based on multi-view learning
CN111242928A
Pituitary tumor image classification method, pituitary tumor image classification system and electronic equipment
CN112190250A