Weakly supervised two-stage medical image segmentation method and device based on graffiti annotation
Through a two-stage medical image segmentation method based on graffiti annotation, using data enhancement and pseudo label generation modules, the problems of high annotation cost and model overfitting in the existing technology are solved, and high-quality three-dimensional medical image segmentation results are achieved.
Patent Information
- Application Number
- CN202410758130.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-13
- Publication Date
- 2024-09-10
AI Technical Summary
Existing medical image segmentation methods rely on large-scale data sets and high-quality dense annotation, and fail to fully utilize the features within the image volume in 3D medical images, resulting in high annotation costs and overfitting of the segmentation model, especially when training samples are scarce. The performance is inaccurate.
A two-stage medical image segmentation method based on graffiti annotation is adopted, high-dimensional features are extracted through data enhancement and weight-sharing encoder structure, segmentation results are generated by combining unperturbed and perturbed decoders, and supervised training is performed through dynamic mixing and pseudo-label generation modules. Reduce labeling burden and model overfitting.
It achieves high-quality segmentation results while reducing annotation data and model training. Only 6% of the graffiti annotation labels are needed to obtain excellent segmentation results, reducing the cost and time of medical image annotation.
Smart Images

Figure CN118628694A
Abstract
Description
Technical Field
[0001] The present disclosure relates to the technical field of medical image processing, and in particular to a two-stage medical image segmentation method and device based on weak supervision of graffiti annotation. Background Art
[0002] Medical image segmentation plays a vital role in clinical diagnosis and medical research. In recent years, with the rise of deep learning methods, especially the application of technologies such as CNN and Transformer, medical image segmentation has made significant progress. However, to train a powerful segmentation network, a large amount of carefully annotated pixel-level data is usually required, which is time-consuming, labor-intensive and costly. Therefore, in order to reduce the annotation cost, many researchers have begun to explore semi-supervised and weakly supervised learning methods.
[0003] Weakly supervised learning methods abandon pixel-level annotations and instead use annotations in the form of bounding boxes, extreme points, and scribbles. Among them, scribble annotations have attracted much attention due to their flexibility and adaptability, especially in the case of irregular segmented areas. The emergence of these methods has greatly reduced the burden on clinical experts and brought new possibilities to the field of medical image segmentation.
[0004] Recent studies have shown that there is an increasing number of deep learning methods based on scribble annotations. These methods use semi-supervised losses to initialize the model and gradually generate reliable pixel-level pseudo-labels for supplementary supervision. Some methods use data augmentation techniques to generate virtual training sets, or directly use scribble annotations to design training strategies and objective functions. Although these methods have made some progress in reducing the cost and time of annotation, they still require medical professionals to manually label images. Especially for 3D medical images, the inherent features within the image volume are not fully utilized to reduce the annotation burden. In addition, due to the limited supervision information of scribble annotations, segmentation models may still perform inaccurately, especially when training samples are scarce.
[0005] In view of the above situation, there is an urgent need to develop a training method that does not rely on large-scale datasets and high-quality dense annotations, and can alleviate the overfitting of labeled data and models one by one, so as to overcome the shortcomings in current practical applications. Summary of the invention
[0006] In order to overcome the above-mentioned deficiencies of the prior art, the present disclosure provides a two-stage medical image segmentation method and device based on graffiti annotation and weak supervision.
[0007] According to a first aspect of the present disclosure, a two-stage medical image segmentation method based on weak supervision of graffiti annotation is provided, characterized in that:
[0008] The following steps are involved:
[0009] S1, obtaining a two-dimensional medical image as a first-stage source image and transforming it through data enhancement, wherein the first-stage source image is a grayscale image;
[0010] S2, passing the source image of the first stage after data enhancement transformation through two weight-sharing encoder structures to obtain high-dimensional feature representation, and passing the high-dimensional features through an unperturbed decoder and a perturbed decoder respectively to obtain two segmentation results;
[0011] S3, dynamically mixing the two segmentation results and training according to a two-dimensional supervision strategy to update encoder parameters to obtain initial parameters;
[0012] S4, acquiring a three-dimensional medical image as a second-stage source image, and cropping the second-stage source image into a grayscale image of a specified dimension;
[0013] S5, after passing the processed two-stage source image through two weight-sharing encoder structures, through an unperturbed decoder and a perturbed decoder, two three-dimensional segmentation results are obtained, the two three-dimensional segmentation results are passed through a pseudo-label generation module, and training is performed according to a three-dimensional supervision strategy to continue updating encoder parameters;
[0014] S6. Combining the encoder and the unperturbed decoder, processing the image to be segmented and inputting the processed image to obtain a segmentation result.
[0015] Preferably, the data enhancement process includes:
[0016] Random noise, random flipping and random rotation are added to the source image of the first stage, and the enhanced image is cropped or padded to ensure that the image size is consistent with the specified input pixel size.
[0017] Preferably, the process of inputting the enhanced image into a one-stage network includes:
[0018] The source image of the first stage is input into two weight-sharing encoders to extract high-level features; the encoder is composed of four layers of convolution blocks and the high-level features are integrated by a fully connected layer; the high-level features are respectively passed through an unperturbed decoder and a perturbed decoder to obtain two segmentation results; the perturbation decoder is composed of four layers of convolution blocks after adding feature-level perturbations.
[0019] Preferably, the process of implementing the supervision strategy to train the initial network parameters includes:
[0020] The two segmentation results are dynamically mixed to form hard false labels; the consistency supervision loss is calculated for the two segmentation results through the hard false labels; the partial cross entropy loss is calculated for the two segmentation results through the graffiti label supervision in the weak supervision; the overall one-stage loss function is composed of the graffiti label supervision and the hard false label consistency supervision, and the calculation method includes:
[0021]
[0022] In the formula, λ represents the weight of consistency supervision, Y 1 and Y 2 Represents the two segmentation results, Y pseudo Indicates dynamic mixed hard and fake labels, L total-2d Represents the loss function of one-stage network training.
[0023] Where, L pce Represents the partial cross entropy loss of graffiti supervision, and the calculation method includes:
[0024]
[0025] In the formula, Ω L represents the set of annotated pixels in the graffiti annotation S, Y represents the first-stage segmentation result, i represents the index of a given pixel; the variable c represents the category index; and Y i c They represent the probability that the i-th pixel in the graffiti belongs to the c-th class, and the probability that the i-th pixel in the prediction result belongs to the c-th class, respectively. pl Represents the consistency supervision loss of hard pseudo-label supervision, and the calculation method includes:
[0026]
[0027] Preferably, the calculation method of dynamically mixing the two segmentation results comprises:
[0028] Y pseudo =argmax[α×Y 1 +(1-α)×Y 2 ]
[0029] Where Y pseudo Indicates two segmentation results Y in one stage 1 and Y 2 The result of dynamic mixing, α represents a random number between (0,1).
[0030] Preferably, the process of acquiring a three-dimensional medical image includes:
[0031] Acquire the three-dimensional volume to which the two-dimensional medical source image belongs; calculate the index of the two-dimensional medical source image in the three-dimensional volume, that is, the index of the middle slice; take an equal number of slices before and after the index and together with the two-dimensional medical source image form a three-dimensional medical image of fixed dimension; perform data enhancement on the three-dimensional medical image.
[0032] Preferably, the process of inputting the enhanced three-dimensional medical image into the two-stage network includes:
[0033] The three-dimensional medical image continues to pass through the weight sharing encoder, and continues to pass through the unperturbed and perturbed decoders to obtain two segmentation results; the two segmentation results obtain mixed pseudo labels through the dynamic mixing strategy; the mixed pseudo labels and the three-dimensional medical image pass through a pseudo label generation module to obtain generated pseudo labels; the consistency supervision loss is calculated for the two segmentation results through the mixed pseudo labels; the cross entropy loss is calculated for the two segmentation results through the generated pseudo labels; the overall two-stage loss function is composed of the mixed pseudo labels and the generated pseudo label supervision, and the calculation method includes:
[0034]
[0035] In the formula, w represents the weight matrix for generating pseudo labels, λ represents the weight of mixed pseudo labels, and L pl-3d and L ce They respectively represent the loss functions based on mixed pseudo-labels and generated pseudo-labels. The two-stage network adopts the overall two-stage loss function and a dynamic weight adjustment mechanism based on the quality of pseudo-labels.
[0036] Preferably, the features and implementation of the pseudo-label generation module include:
[0037] The module is an autonomous module that runs independently of the network gradient propagation, and is intended to provide a wider range of supervision information; the module mainly utilizes the inherent spatial attributes and dimensional information of three-dimensional medical images and is mainly designed for the shape and size of the region of interest in the medical image; the method of the module mainly relies on medical image registration technology, by finding a suitable deformation field between images, and applying the deformation field to the pseudo-label to form a generated pseudo-label; the spatial deformation field needs to utilize the three-dimensional medical image, and is combined with the mixed pseudo-label to jointly update the generated pseudo-label; the middle slice of the index of the generated pseudo-label is replaced with the graffiti annotation label.
[0038] Preferably, the specific strategy of the overall two-stage loss function includes:
[0039] The loss function is composed of the mixed pseudo-label supervision loss L pl-3d and generate pseudo-supervision loss L ceTogether, the mixed pseudo-label supervision L pl-3d The calculation method is consistent with the calculation idea of the hard pseudo-label supervision in the first stage, and includes:
[0040]
[0041] Where P 1 and P 2 represents the two segmentation results of the second stage, P pseudo Indicates generating a pseudo label. The pseudo label generation supervision uses a cross entropy loss, and a partial cross entropy loss function is used on the replaced slice of the index; different weights are assigned to each slice of the pseudo label generation to form a weight matrix, and the weight setting is related to the distance from the pseudo label generation slice to the middle slice of the index, and the calculation method includes:
[0042]
[0043] Wherein, m represents the middle slice of the index, d represents the distance, a is a weight variable, and the value range is (0,1). The calculation method for generating pseudo-label supervision includes:
[0044]
[0045] Preferably, the dynamic weight adjustment mechanism includes:
[0046] By calculating the comprehensive similarity of the mixed pseudo-label and the generated pseudo-label, the comprehensive similarity combines the structural similarity SSIM and Jaccard similarity. The calculation method includes:
[0047]
[0048] In the formula, represents the generation of pseudo labels, and N represents normalization. The dynamic adjustment mechanism adjusts the weight variable a according to the comprehensive similarity and the instant training result of the two-stage network.
[0049] According to a second aspect of the present disclosure, a two-stage medical image segmentation device based on weak supervision of graffiti annotation comprises:
[0050] A two-dimensional image data acquisition module, used to acquire a two-dimensional medical image as a source image and transform it through data enhancement, wherein the source image is a grayscale image;
[0051] A first-stage segmentation module, used for passing the source image through a feature perturbation segmentation module, outputting two segmentation results according to two encoder and decoder structures, and supervising the segmentation results according to a supervision strategy to train network parameters;
[0052] The dynamic mixed pseudo-label module is used to generate hard pseudo-labels by randomly and dynamically mixing the two segmentation results, and calculate the loss function between the hard pseudo-labels and the two segmentation results according to the hard pseudo-label supervision strategy, update the encoder parameters, and obtain the network initial parameters;
[0053] A three-dimensional image data acquisition module, used to acquire a three-dimensional medical image as a source image, and crop the source image into a grayscale image of a specified dimension;
[0054] A two-stage segmentation and pseudo-label generation module, which obtains a mixed pseudo-label according to the source image after passing it through a dynamic hybrid training module, and passes the mixed pseudo-label through a pseudo-label generation module to obtain a generated pseudo-label;
[0055] The target result segmentation module is used to combine the encoder with the unperturbed decoder, process the image to be segmented and input it to obtain the segmentation result.
[0056] The principle of the technical solution disclosed in this disclosure is:
[0057] In the first stage, a small number of two-dimensional medical images and their graffiti annotations are used as input to the network architecture of weight-sharing encoders and unperturbed and perturbed decoders, and the network parameters are updated by combining graffiti supervision and hard pseudo-label supervision strategies. In the second stage, the three-dimensional images to which the two-dimensional medical images in the previous stage belong are used, and pseudo-label generation modules are used to generate pseudo-labels for images without graffiti annotations. The network parameters are continued to be updated by combining pseudo-label generation and dynamic hybrid pseudo-label joint supervision, and a dynamic weight adjustment mechanism based on pseudo-label quality is adopted during the second stage training process.
[0058] The technical effects of the present disclosure are:
[0059] The present disclosure is a new two-stage training method with weak supervision for three-dimensional medical image segmentation. By utilizing the inherent spatial characteristics of three-dimensional medical images and the similarity of regions of interest in adjacent slices, the number of graffiti-annotated slices used is further reduced on the basis of reducing single pixel-level annotations, i.e., graffiti annotations. Through dynamic hybrid strategies and pseudo-label generation modules, more diverse supervision information is provided to the network architecture, and pseudo-label errors are minimized through a dynamic adjustment weight mechanism. The present disclosure obtains high-quality segmentation results by combining an encoder and an unperturbed decoder. Using the method of the present disclosure, only 6% of the graffiti annotation labels can be used during training to obtain high-quality segmentation results, solving the problem of expensive and time-consuming medical image annotation. BRIEF DESCRIPTION OF THE DRAWINGS
[0060] The above and other features, advantages and aspects of the embodiments of the present disclosure will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. The accompanying drawings are used to better understand the present solution and do not constitute a limitation of the present disclosure. In the accompanying drawings, the same or similar reference numerals represent the same or similar elements, among which:
[0061] Figure 1 A flowchart of a two-stage medical image segmentation method based on weak supervision of graffiti annotation provided by the present disclosure;
[0062] Figure 2 A process framework diagram of a two-stage medical image segmentation method based on weak supervision of graffiti annotation provided by the present disclosure;
[0063] Figure 3 A schematic diagram of the structure of a two-stage medical image segmentation device based on weak supervision of graffiti annotation provided by the present disclosure;
[0064] Figure 4 The present invention provides a two-stage medical image segmentation method based on graffiti annotation and weak supervision, and the segmentation results on two data sets. DETAILED DESCRIPTION
[0065] In order to make the purpose, technical solution and advantages of the embodiments of the present disclosure clearer, the technical solution in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present disclosure.
[0066] like Figure 1 and Figure 2 As shown, in one embodiment, a two-stage medical image segmentation method based on weak supervision of graffiti annotation is provided, comprising the following steps:
[0067] S1, obtaining a two-dimensional medical image as a first-stage source image and transforming it through data enhancement, wherein the first-stage source image is a grayscale image;
[0068] The grayscale image is the middle slice of the three-dimensional medical image, that is, the two-dimensional medical image X c ; And perform random rotation of 0°, 90°, 180°, and 270° on the z-axis, and perform random flipping and adding noise on the x-axis and y-axis to enhance the data;
[0069] S2, passing the source image of the first stage after the array enhancement transformation through two weight-sharing encoder structures to obtain a high-dimensional feature representation, and passing the high-dimensional features through a decoder to obtain an unperturbed decoder and a perturbed decoder to obtain two segmentation results;
[0070] The image is input into two weight-sharing encoders to extract high-level features. The two weight-sharing encoders have the same structure and are composed of 4 layers of convolution blocks. Each convolution block includes two convolution kernels, batch normalization BN, activation function ReLU and downsampling layer;
[0071] After extracting high-level features, they are integrated using a fully connected layer;
[0072] The high-level features are input into the unperturbed decoder and the perturbed decoder to obtain two segmentation results Y 1 and Y 2 The decoder uses symmetric operations with the encoder, and the convolution blocks are connected by jumps. The perturbation decoder randomly loses part of the neuron output by adding a dropout layer between each convolution layer.
[0073] S3, dynamically mixing the two segmentation results and training according to a two-dimensional supervision strategy to update encoder parameters to obtain initial parameters;
[0074] The two segmentation results are dynamically mixed to form a hard pseudo label Y pseudo ; The calculation method of dynamic hybrid strategy includes:
[0075] Y pseudo =argmax[a×Y 1 +(1-a)×Y 2 ]
[0076] Among them, α represents a random number between (0,1),
[0077] Through hard fake label Y pseudo Supervising two segmentation results, the consistency supervision loss calculation method includes:
[0078]
[0079] By supervising the two segmentation results with the graffiti label S, some cross entropy loss calculation methods include:
[0080]
[0081] Among them, Ω L represents the set of annotated pixels in the graffiti annotation S, Y represents the segmentation result, i represents the index of a given pixel; the variable c represents the category index; and Y ic They represent the probability that the i-th pixel in the graffiti belongs to the c-th class, and the probability that the i-th pixel in the prediction result belongs to the c-th class;
[0082] The overall first-stage loss function is composed of graffiti supervision and hard pseudo-label consistency supervision;
[0083] In an embodiment, the loss function calculation method includes:
[0084]
[0085] Among them, λ represents the weight of consistency supervision;
[0086] S4, acquiring a three-dimensional medical image as a second-stage source image, and cropping the second-stage source image into a grayscale image of a specified dimension;
[0087] Acquire the three-dimensional volume to which the two-dimensional medical source image belongs;
[0088] The three-dimensional medical image is taken as an intermediate slice X c The three-dimensional volume to which it belongs;
[0089] Calculate the index of the two-dimensional medical source image in the three-dimensional volume, that is, the index of the middle slice, and take the same number of slices before and after the index and compare them with X c Together they form a three-dimensional medical image of fixed dimension;
[0090] Take X c and the two slices before and after it, together forming a three-dimensional medical image X in the same order as the three-dimensional volume;
[0091] S5, after the processed two-stage three-dimensional source image continues to pass through two weight-sharing encoder structures, through an unperturbed decoder and a perturbed decoder, two three-dimensional segmentation results are obtained, the two three-dimensional segmentation results are passed through a pseudo-label generation module, and training is performed according to a three-dimensional supervision strategy to continue updating encoder parameters;
[0092] The two-stage three-dimensional medical image continues to pass through two weight-sharing encoder structures, and then passes through the unperturbed decoder and the perturbed decoder to obtain two segmentation results P 1 and P 2 ;
[0093] Two segmentation results P in the second stage 1 and P 2 The mixed pseudo-label P is obtained by dynamic mixing strategy pseudo ;
[0094] Mixed pseudo-label P pseudo And the three-dimensional medical image X is passed through the pseudo label generation module to generate pseudo labels
[0095] Using X c and its corresponding dynamic hybrid pseudo-label P c As a floating image pair (X c ,P c ), X u is a fixed image, predict X c and X u The displacement field of The same spatial deformation field can be used to generate pseudo labels for non-intermediate slices Right now Each P u By close to P c Pseudo-label generation, after generation, P c Replace it with its real graffiti annotation S, and finally get the generated pseudo label
[0096] By dynamically mixing pseudo labels P pseudo Supervise two segmentation results;
[0097] The consistency supervision loss calculation method includes:
[0098]
[0099] By generating a pseudo label P pseudo Supervise two segmentation results;
[0100] Generate pseudo-label supervision using cross entropy loss, use partial cross entropy loss function on S, and set a weight matrix. The calculation method includes:
[0101]
[0102] Where m represents the middle slice X c The index of d indicates the slice to X c The distance, a is the weight variable, and its value range is (0,1);
[0103] The pseudo-label supervision is generated and the calculation method includes:
[0104]
[0105] The overall two-stage loss function is composed of the mixed pseudo-label supervision loss L pl-3d and generate pseudo-supervision loss L ce Together, the loss function calculation method includes:
[0106]
[0107] Among them, λ represents the weight of consistency supervision, and w represents the weight matrix;
[0108] S6. Combining the encoder and the unperturbed decoder, processing the image to be segmented and inputting the processed image to obtain a segmentation result.
[0109] The dynamic weight adjustment mechanism is used in the two-stage training process. The dynamic weight adjustment mechanism calculates the comprehensive similarity of the mixed pseudo-label and the generated pseudo-label. The comprehensive similarity combines the structural similarity SSIM and Jaccard similarity. The calculation method includes:
[0110]
[0111] The dynamic adjustment mechanism adjusts the weight variable a according to the comprehensive similarity and the real-time training results of the two-stage network. When the comprehensive similarity is lower than the threshold or the network performance drops significantly, the weight variable a is lowered, and vice versa.
[0112] To further illustrate the beneficial effects of the present disclosure, in some embodiments, experiments are conducted on two heart segmentation datasets, ACDC and MSCMRSeg. When only 6% of the graffiti-annotated data are used on the two datasets, the results obtained are compared with the results obtained by other medical image segmentation methods based on graffiti annotation. In order to objectively evaluate the comparison results, the results of each segmentation method are calculated and presented through three indicators, and the results are shown in Table 1. The larger the objective evaluation index value Dice in the table, the better the segmentation effect, and the smaller the HD95, the better the segmentation effect. It can be observed from Table 1 that in some embodiments, the HD95 result of MSCMRSeg performs second best, and the best results are obtained in all other cases.
[0113]
[0114]
[0115] Table 1
[0116] In some embodiments, Figure 3 As shown, a two-stage medical image segmentation device 100 based on weak supervision of graffiti annotation is provided, comprising:
[0117] A two-dimensional image data acquisition module 10, used to acquire a two-dimensional medical image as a source image and transform it through data enhancement, wherein the source image is a grayscale image;
[0118] A first-stage segmentation module 20, used for passing the source image through a feature perturbation segmentation module, outputting two segmentation results according to two encoder and decoder structures, and supervising the segmentation results according to a supervision strategy to train network parameters;
[0119] The dynamic mixed pseudo-label module 30 is used to generate a hard pseudo-label by randomly dynamically mixing the two segmentation results, and calculate the loss function between the hard pseudo-label and the two segmentation results according to the hard pseudo-label supervision strategy, update the encoder parameters, and obtain the network initial parameters;
[0120] A three-dimensional image data acquisition module 40, used to acquire a three-dimensional medical image as a source image, and to crop the source image into a grayscale image of a specified dimension;
[0121] A second-stage segmentation and pseudo-label generation module 50, which obtains a mixed pseudo-label according to the source image after passing through the dynamic hybrid training module, and passes the mixed pseudo-label through the pseudo-label generation module to obtain a generated pseudo-label;
[0122] The target result segmentation module 60 is used to combine the encoder with the unperturbed decoder, process the image to be segmented and input it to obtain a segmentation result.
[0123] The embodiments described above are only descriptions of the preferred embodiments of the present invention and are not intended to limit the scope of the present invention. Without departing from the design spirit of the present invention, ordinary technicians in this field may make various modifications and improvements to the technical solutions of the present invention, which should all fall within the scope of protection determined by the claims of the present invention.
Claims
1. A two-stage medical image segmentation method based on weak supervision of scribble annotation, characterized in that: The following steps are involved: S1, obtaining a two-dimensional medical image as a first-stage source image and transforming it through data enhancement, wherein the first-stage source image is a grayscale image; S2, passing the source image of the first stage after data enhancement transformation through two weight-sharing encoder structures to obtain high-dimensional feature representation, and passing the high-dimensional features through an unperturbed decoder and a perturbed decoder respectively to obtain two segmentation results; S3, dynamically mixing the two segmentation results and training according to a two-dimensional supervision strategy to update encoder parameters to obtain initial parameters; S4, acquiring a three-dimensional medical image as a second-stage source image, and cropping the second-stage source image into a grayscale image of a specified dimension; S5, after passing the processed two-stage source image through two weight-sharing encoder structures, through an unperturbed decoder and a perturbed decoder, two three-dimensional segmentation results are obtained, the two three-dimensional segmentation results are passed through a pseudo-label generation module, and training is performed according to a three-dimensional supervision strategy to continue updating encoder parameters; S6. Combining the encoder and the unperturbed decoder, processing the image to be segmented and inputting the processed image to obtain a segmentation result.
2. The two-stage medical image segmentation method based on weak supervision of graffiti annotation according to claim 1 is characterized in that: The data augmentation transformation in S1 includes: adding random noise, random flipping and random rotation to the source image of the first stage, and cropping or padding the augmented image to ensure that the image size is consistent and is the specified input pixel size.
3. The two-stage medical image segmentation method based on weak supervision of graffiti annotation according to claim 1 is characterized in that: The process of inputting the one-stage source image into the one-stage network in S2 includes: inputting the one-stage source image into two weight-shared encoders to extract high-level features; the encoder is composed of four layers of convolution blocks and the high-level features are integrated by a fully connected layer; the high-level features are respectively passed through a decoder and a perturbation decoder to obtain two segmentation results; the perturbation decoder is composed of a four-layer convolution block after adding feature-level perturbations.
4. The two-stage medical image segmentation method based on weak supervision of graffiti annotation according to claim 1, characterized in that: The process of training in S3 according to the two-dimensional supervision strategy to update the encoder parameters includes: the two segmentation results in S2 are dynamically mixed to form hard pseudo labels; the consistency supervision loss of the two segmentation results is calculated by the hard pseudo labels; a specific implementation form of weak supervision, graffiti label supervision, is adopted, and a partial cross entropy loss is calculated for the two segmentation results by graffiti label supervision; the overall one-stage loss function is composed of the graffiti label supervision and the hard pseudo label consistency supervision, and the calculation method includes: In the formula, λ represents the loss of consistency supervision, Y1 and Y2 represent the two segmentation results in S2, and Y pseudo Indicates dynamic mixed hard and fake labels, L total-2d Represents the loss function of one-stage network training; Where, L pce Represents the partial cross entropy loss of graffiti label supervision, and the calculation method includes: In the formula, Ω L represents the set of annotated pixels in the graffiti annotation S, Y represents the segmentation result in S2, i represents the index of a given pixel; the variable c represents the category index; S i c and Y i c They represent the probability that the i-th pixel in the graffiti belongs to the c-th class, and the probability that the i-th pixel in the prediction result belongs to the c-th class, respectively. pl Represents the consistency supervision loss of hard pseudo-label supervision, and the calculation method includes:
5. The two-stage medical image segmentation method based on weak supervision of graffiti annotation according to claim 1, characterized in that: The calculation method of dynamically mixing the two segmentation results includes: Y pseudo =argmax[α×Y1+(1-α)×Y2] Where Y pseudo It represents the result of dynamic mixing of the two segmentation results Y1 and Y2 in S2, and α represents a random number between (0,1).
6. The two-stage medical image segmentation method based on weak supervision of graffiti annotation according to claim 1, characterized in that: The process of acquiring a three-dimensional medical image in S4 includes: acquiring the three-dimensional volume to which the two-dimensional medical image belongs; calculating the index of the two-dimensional medical image in the three-dimensional volume, that is, the index of the middle slice; taking an equal number of slices before and after the index and forming a three-dimensional medical image of fixed dimension together with the two-dimensional medical image; and performing data enhancement on the three-dimensional medical image.
7. The two-stage medical image segmentation method based on weak supervision of graffiti annotation according to claim 1, characterized in that: In S5, after the processed two-stage source image passes through two weight-sharing encoder structures, the process of passing through an unperturbed decoder and a perturbed decoder includes: the three-dimensional medical image continues to pass through the weight-sharing encoder, and continues to pass through the unperturbed and perturbed decoders to obtain two segmentation results; the two segmentation results obtain mixed pseudo labels through the same dynamic mixing strategy of the first stage; the mixed pseudo labels and the three-dimensional medical image pass through a pseudo label generation module to obtain generated pseudo labels; the consistency supervision loss of the two segmentation results is calculated by the mixed pseudo labels; the cross entropy loss of the two segmentation results is calculated by the generated pseudo labels; the overall two-stage loss function is composed of the mixed pseudo labels and the generated pseudo label supervision, and the calculation method includes: In the formula, w represents the weight matrix for generating pseudo labels, λ represents the weight of mixed pseudo labels, and L pl-3d and L ce They represent the loss functions based on mixed pseudo-labels and generated pseudo-labels respectively. The two-stage network adopts the overall two-stage loss function and a dynamic weight adjustment mechanism based on the quality of pseudo-labels.
8. The two-stage medical image segmentation method based on weak supervision of graffiti annotation according to claim 7, characterized in that: The specific strategy of the overall two-stage loss function includes: the loss function is composed of a mixed pseudo-label supervision loss L pl-3d and generate pseudo-supervision loss L ce Together, the mixed pseudo-label supervision L pl-3d The calculation method is consistent with the calculation idea of the hard pseudo-label supervision in the first stage, and includes: Where P1 and P2 represent the two segmentation results of the second stage, P pseudo Indicates generating a pseudo label. The pseudo label generation supervision uses a cross entropy loss, and a partial cross entropy loss function is used on the replaced slice of the index; different weights are assigned to each slice of the pseudo label generation to form a weight matrix, and the weight setting is related to the distance from the pseudo label generation slice to the middle slice of the index, and the calculation method includes: Wherein, m represents the middle slice of the index, d represents the distance, a is a weight variable, and the value range is (0,1). The calculation method for generating pseudo-label supervision includes:
9. The two-stage medical image segmentation method based on weak supervision of graffiti annotation according to claim 7, characterized in that: The dynamic weight adjustment mechanism calculates the comprehensive similarity of the mixed pseudo-label and the generated pseudo-label. The comprehensive similarity combines the structural similarity SSIM and the Jaccard similarity. The calculation method includes: In the formula, It represents generating a pseudo label, N represents normalization, and the dynamic adjustment mechanism adjusts the weight variable a according to the comprehensive similarity and the instant training result of the two-stage network.
10. A two-stage medical image segmentation device based on weak supervision of graffiti annotation, the device comprising: A two-dimensional image data acquisition module, used to acquire a two-dimensional medical image as a source image and transform it through data enhancement, wherein the source image is a grayscale image; A first-stage segmentation module, used for passing the source image through a feature perturbation segmentation module, outputting two segmentation results according to two encoder and decoder structures, and supervising the segmentation results according to a supervision strategy to train network parameters; The dynamic mixed pseudo-label module is used to generate hard pseudo-labels by randomly and dynamically mixing the two segmentation results, and calculate the loss function between the hard pseudo-labels and the two segmentation results according to the hard pseudo-label supervision strategy, update the encoder parameters, and obtain the network initial parameters; A three-dimensional image data acquisition module, used for acquiring a three-dimensional medical image as a source image, and cropping the source image into a grayscale image of a specified dimension; A two-stage segmentation and pseudo-label generation module, used to obtain a mixed pseudo-label according to the source image after passing through the dynamic hybrid training module, and pass the mixed pseudo-label through the pseudo-label generation module to obtain a generated pseudo-label; The target result segmentation module is used to combine the encoder with the unperturbed decoder, process the image to be segmented and input it to obtain the segmentation result.
Citation Information
Cited By
Pheochromocytoma medical image segmentation method and device, equipment and medium
CN119648717A
Medical image segmentation method and device for pheochromocytoma, equipment and medium
CN119648717B
Weak semi-supervised heart MRI segmentation method based on pseudo label frequency domain dynamic mixed supervision
CN120182295A
Basic hole semi-supervised segmentation method for aviation structural part robot drilling
CN120913210A
Multi-organ medical image segmentation method and device based on weak supervision
CN121304709A
