Semi-supervised medical image segmentation method based on confidence mask guided contrast learning

By introducing a heterogeneous auxiliary correction network and confidence mask-guided contrastive learning into the Mean-Teacher framework, and combining cross-momentum mixing and Cutout techniques, the problems of poor segmentation accuracy and insufficient utilization of unlabeled data caused by the EMA update strategy in semi-supervised medical image segmentation models are solved, achieving higher segmentation accuracy and stability.

CN118967703AInactive Publication Date: 2024-11-15HENAN UNIVERSITY OF TECHNOLOGY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411059125.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-02
Publication Date
2024-11-15
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

Existing semi-supervised medical image segmentation models based on the Mean-Teacher framework suffer from poor segmentation accuracy during supervised learning due to the EMA update strategy. Furthermore, they neglect the value of unlabeled data, which can easily lead to overfitting and unreliable pseudo-labels, thus affecting segmentation accuracy.

Method used

Heterogeneous Auxiliary Correction Network (HAR) branch and confidence mask-guided contrastive learning strategy are introduced. Combined with cross-momentum mixing technology and cutout strong perturbation, the prediction of student branches is optimized. The unlabeled data is fully utilized, and positive and negative sample pairs are selected for contrastive learning through confidence mask and projector to improve segmentation performance.

Benefits of technology

It improves the accuracy and stability of medical image segmentation, solves the problem of poor segmentation accuracy caused by the EMA update strategy, and effectively utilizes unlabeled data, thereby improving the comprehensiveness and anti-overfitting ability of the segmentation model.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118967703A_ABST
    Figure CN118967703A_ABST
Patent Text Reader

Abstract

The invention relates to the field of medical image segmentation, in particular to a semi-supervised medical image segmentation method based on confidence mask guided contrast learning, which comprises the following steps: firstly, collecting medical image data, and then inputting a medical image into a built medical image segmentation model based on a convolutional neural network; and finally, obtaining a segmentation result of the medical image through the segmentation model. The method is a method for automatically segmenting medical image pathological tissues by using an image processing technology. The method is high in segmentation precision and reliability, and can effectively promote the upgrading and reconstruction process of a medical image automatic segmentation system. In addition, by means of the method, the marking cost of the medical image can be effectively reduced, and doctors are assisted in clinical diagnosis.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of medical image processing, and in particular to a semi-supervised medical image segmentation method based on confidence mask guided contrast learning. Background Art

[0002] Medical image segmentation is an important task in medical image processing. Its goal is to identify target areas in images, such as organs, lesions or cells, which can be applied to disease diagnosis, surgical planning, etc., to assist doctors in clinical treatment. In the early days, medical image segmentation mainly relied on the experience of experts and manual operation. Although this method is relatively accurate, it is inefficient and easily affected by subjective factors. Therefore, it is of great significance to develop an automated segmentation technology with high segmentation accuracy. With the development of deep learning technology, people have developed a series of medical image segmentation technologies based on deep learning, using convolutional neural networks (CNN) to extract feature information of images. The trained CNN-based neural network segmentation model has high accuracy. However, early deep learning-based medical image segmentation technologies were mainly based on fully supervised learning methods. These segmentation models often require a large amount of labeled data training to obtain good performance, which is not easy to achieve in medical image processing tasks because medical image data is private and scarce, and it takes experts a lot of energy and time to label it.

[0003] In order to solve the above problems, semi-supervised learning technology has attracted people's attention. Compared with the medical image segmentation method based on the fully supervised paradigm, semi-supervised learning technology can use limited labeled data and a large amount of unlabeled data to train the network, so that the segmentation model can obtain excellent segmentation performance, which is very suitable for medical image segmentation tasks. Most mainstream semi-supervised medical image segmentation technologies use the Mean-Teacher framework, which contains two branches: the student branch and the teacher branch. The two branches use the same network structure, in which the weight parameters of the teacher branch are composed of the exponential moving average weights of the student branch. This framework can make the network more stable. However, semi-supervised medical image segmentation based on the Mean-Teacher framework also has problems: (1) In the supervised learning process, the student branch is trained with a small amount of labeled data, which will cause the student branch to learn limited and unreliable feature information. This feature information is then updated to the teacher branch, causing the teacher branch to generate unreliable pseudo labels during the unsupervised learning process, affecting the segmentation accuracy of the entire network. (2) In the supervised learning process, the student branch only uses a limited amount of labeled data and ignores the value of unlabeled data. This will cause the feature information learned by the student branch to be incomplete and prone to overfitting problems. Summary of the invention

[0004] The object of the present invention is to provide a semi-supervised medical image segmentation method based on confidence mask guided contrast learning, so as to improve the performance of automatic segmentation of medical images.

[0005] To solve the above technical problems, the technical solution of the present invention is: a semi-supervised medical image segmentation method based on confidence mask guided contrast learning, comprising the following steps:

[0006] S1: Collect medical image datasets and preprocess the images to construct training and test sets;

[0007] S2: Build a semi-supervised medical image segmentation network model, which includes: a basic Mean-teacher network model and a heterogeneous auxiliary correction network branch (HAR).

[0008] The basic Mean-teacher network model includes a student branch and a teacher branch. The student branch and the teacher branch use the same network structure, V-Net is used as the backbone network of the Mean-teacher network model, and the Exponential Moving Average (EMA) weight of the student branch is used to update the weight of the teacher branch.

[0009] The HAR branch uses the same Encoder as V-Net, while the Decoder uses the Decoder of the ResNet34 network.

[0010] After the second layer of the decoder of the three branches, a classifier is added respectively, and the classifier uses the same network structure. A projector is also added to the second layer of the decoder in the student branch and the teacher branch respectively, and the two projectors use the same network structure.

[0011] S3: In the supervised learning phase, the labeled data and unlabeled data are cross-momentum mixed and then input into the student network and HAR branch. The HAR branch is used to supervise the student network training, correct the prediction errors of the student branch, and provide complementary information for it.

[0012] S4: In the unsupervised learning stage, the unlabeled data is strongly perturbed using Cutout, and then input into three branches. The confidence mask obtained by the classifier and the projector are used to select positive / negative sample pairs for comparative learning.

[0013] S5: inputting the training set into the semi-supervised medical image segmentation network model for training to obtain a trained semi-supervised medical image segmentation network model;

[0014] S6: Input the test set into the trained semi-supervised medical image segmentation network model to obtain the medical image segmentation results.

[0015] The beneficial effects of the present invention are:

[0016] This scheme uses a semi-supervised medical image segmentation model based on confidence mask guided contrastive learning to automatically segment medical images. A three-branch semi-supervised medical image segmentation model is designed and introduced.

[0017] A HAR branch is introduced into the Mean-Teacher framework to solve the problem of poor segmentation accuracy caused by the EMA update strategy in the existing semi-supervised medical image segmentation model based on the Mean-Teache framework. In addition, the present invention also develops a new contrastive learning sampling strategy based on confidence mask guidance. In addition, a cross-momentum hybrid technology is designed to solve the problem of ignoring the use of unlabeled data in traditional semi-supervised medical image segmentation technology. Finally, the Cutout technology is introduced in the unsupervised learning stage to further fully explore the value of unlabeled data in the unsupervised learning stage.

[0018] Furthermore, the specific process of the preprocessing is: randomly cutting the collected medical image data into a uniform size, performing random rotation and random Gaussian noise data enhancement, and expanding the data set;

[0019] Furthermore, the loss function used by the semi-supervised medical image segmentation network model consists of a supervised loss function and an unsupervised loss function. The supervised loss function includes a Dice loss function, a cross entropy loss function, and a complementary correction loss function; the unsupervised loss function includes a consistency loss function and a contrast loss function;

[0020] Furthermore, the cross-momentum hybrid method is used to provide more comprehensive feature information using unlabeled data in the supervised learning stage. The specific process is: calculate the mean μ and variance σ of each unlabeled data in a Batch, and use the momentum update method to obtain the momentum mean μ of the Batch b and momentum variance σ b :

[0021]

[0022] In the formula, represents the momentum mean of i-1 unlabeled data in Batch, Represents the momentum variance of the i-1 unlabeled data in the Batch. b and momentum variance σ b After that, cross-momentum mixing is performed with the label data:

[0023]

[0024] In the formula, I l' represents the feature map after the current label data is updated, I l Represents the original feature map of the current label data, μ l , σ l Represent the mean and variance of the current label data respectively.

[0025] Furthermore, the HAR branch is used to supervise the student network training, correct the prediction errors of the student branch, and provide complementary information for it. The specific process is as follows:

[0026] The labeled data after cross-momentum mixing is input into the student branch and the HAR branch, and two predictions are obtained respectively: The potential area of ​​the student network's prediction results for the labeled data can be obtained through two prediction results:

[0027]

[0028] Among them, R pot is the potential region, which contains complementary information provided by the heterogeneous network and possible misprediction information. Calculate the complementary correction loss L mr To optimize the student network's prediction accuracy for the potential region:

[0029]

[0030] in, Where e represents element-by-element multiplication, Indicates the prediction result of the student network for the label data corresponding to R pot Probability map of the region, The prediction results of the heterogeneous auxiliary correction network for the label data correspond to R pot Probability map of the region, y pot Indicates that it corresponds to R pot The ground truth of the region.

[0031] The student network and the heterogeneous auxiliary correction network branch can generate different prediction results for the same data. For the different prediction parts, this part can be used as a potential area. There may be some wrong predictions in the potential area. At the same time, the heterogeneous auxiliary correction network branch can also provide supplementary information for the student network for the potential area.

[0032] Furthermore, in the unsupervised learning stage, the unlabeled data is strongly perturbed using Cutout, and then input into the three branches. The confidence mask obtained by the classifier and the projector are used to select positive / negative sample pairs for comparative learning. The specific process is as follows: In the unsupervised learning process, we first use Cutout to strongly perturb the unlabeled data, and then input into the student network, HAR branch and teacher network. We add a classifier to the third layer of the Decoder of the three branch networks, and add a projector after the second convolution layer of the Decoder of the student branch and the teacher branch. The input of the classifier is the feature map output by the previous convolution layer. The three classifiers output three masks, Pseudo-masks, respectively. The three Psudo-masks are logically ANDed to obtain a new mask, Confidence Positive mask (CPM). Then, the CPM is logically NOT operated to obtain Confidence Negative mask (CNM). The input of the projector is the feature map output by the previous convolution layer. The projectors of the student branch and the teacher branch output two feature maps respectively: F s , F t . CPM is divided into F s , F t Element-wise multiplication, in F s , F t The areas corresponding to CPM are obtained respectively, which are recorded as: We from The positive samples are taken from the corresponding position pixels as positive sample pairs. Then CNM and F t Element-wise multiplication, in F t Get the area corresponding to CNM, denoted as We are Select negative sample pairs from above, and all pixels between them are negative samples. After sampling the positive and negative sample pairs, we use voxel-level contrast loss to pull the positive samples together and expand the edges between negative samples, thereby improving the compactness between similar voxels and the separability between voxels of different categories. Given an anchor voxel j, calculate the contrast loss:

[0033]

[0034] Among them, k + Indicates from The positive samples extracted from Indicates from The selected negative samples, N is the number of sampled negative samples, and τ is a temperature parameter.

[0035] Furthermore, the test set is input into the trained semi-supervised medical image segmentation network model, and the average prediction results of the HAR branch and the teacher branch are calculated as the final medical image segmentation result. BRIEF DESCRIPTION OF THE DRAWINGS

[0036] Figure 1 It is a schematic diagram of the framework of the semi-supervised medical image segmentation method based on confidence mask guided contrast learning provided by the present invention;

[0037] Figure 2 It is a heterogeneous auxiliary network correction flow chart of the semi-supervised medical image segmentation method based on confidence mask guided contrast learning provided by the present invention;

[0038] Figure 3 is a flow chart of the confidence mask guided contrastive learning method; DETAILED DESCRIPTION

[0039] In order to elaborate on the purpose, technical solutions and advantages of the present invention, the present invention is further described in detail below in conjunction with specific implementation steps and drawings.

[0040] refer to Figure 1 This embodiment provides a semi-supervised medical image segmentation method based on confidence mask guided contrastive learning, designs a three-branch semi-supervised medical image segmentation model, and introduces a heterogeneous auxiliary correction network branch in the Mean-teacher framework to solve the problem of poor segmentation accuracy caused by the EMA update strategy in the existing semi-supervised medical image segmentation model based on the Mean-teacher framework. In addition, the present invention also develops a new contrastive learning sampling strategy based on confidence mask guidance. In addition, a cross-momentum hybrid technology is designed to solve the problem of ignoring the use of unlabeled data in traditional semi-supervised medical image segmentation technology. Finally, the Cutout technology is introduced in the unsupervised learning stage to further fully explore the value of unlabeled data in the unsupervised learning stage.

[0041] In the present invention, the student branch and the teacher branch use the same network architecture and use V-Net as the backbone network. The HAR network branch uses the same Encoder as V-Net, and the Decoder uses the Decoder in ResNet34 as the Decoder of the HAR network branch. A binary classifier is added after the second layer of the Decoder of the three branches. In addition, a projector is added after the second layer of the Decoder of the student branch and the teacher branch for mapping features. The projector consists of a convolutional layer, a ReLu layer, and a convolutional layer.

[0042] Specifically, the steps of the semantic segmentation method of this example are as follows:

[0043] S1: Collect medical image datasets and preprocess the images to construct training and test sets;

[0044] Among them, the preprocessing includes randomly cropping the collected medical image data into a uniform size, performing random rotation, random Gaussian noise data enhancement, and expanding the data set;

[0045] S2: Build a semi-supervised medical image segmentation network model, which includes: a basic Mean-teacher network model and a heterogeneous auxiliary correction network branch (HAR).

[0046] The basic Mean-teacher network model includes a student branch and a teacher branch. The student branch and the teacher branch use the same network structure, V-Net is used as the backbone network of the Mean-teacher network model, and the Exponential Moving Average (EMA) weight of the student branch is used to update the weight of the teacher branch.

[0047] The HAR branch uses the same Encoder as V-Net, while the Decoder uses the Decoder of the ResNet34 network.

[0048] After the second layer of the decoder of the three branches, a classifier is added respectively, and the classifier uses the same network structure. A projector is also added to the second layer of the decoder in the student branch and the teacher branch respectively, and the two projectors use the same network structure.

[0049] S3: In the supervised learning stage, the labeled data and the unlabeled data are cross-momentum mixed and then input into the student network and the HAR branch. The HAR branch is used to supervise the student network training, correct the prediction errors of the student branch, and provide complementary information for it.

[0050] The cross-momentum hybrid method of this embodiment is used to use unlabeled data to provide more comprehensive feature information in the supervised learning stage. The specific process is: calculate the mean μ and variance σ of each unlabeled data in a Batch, and use the momentum update method to obtain the momentum mean μ of the Batch. b and momentum variance σ b :

[0051]

[0052] In the formula, represents the momentum mean of i-1 unlabeled data in Batch, Represents the momentum variance of the i-1 unlabeled data in the Batch. b and momentum variance σ bAfter that, cross-momentum mixing is performed with the label data:

[0053]

[0054] In the formula, I l ' represents the feature map after the current label data is updated, I l Represents the original feature map of the current label data, μ l , σ l Represent the mean and variance of the current label data respectively.

[0055] It should be noted that the labeled data after cross-momentum mixing is input into the student branch and the HAR branch, and two predictions are obtained respectively: The potential area of ​​the student network's prediction results for the labeled data can be obtained through two prediction results:

[0056]

[0057] Among them, R pot is the potential region, which contains complementary information provided by the heterogeneous network and possible misprediction information. Calculate the complementary correction loss L mr To optimize the student network's prediction accuracy for the potential region:

[0058]

[0059] in, Where e represents element-by-element multiplication, Indicates the prediction result of the student network for the label data corresponding to R pot Probability map of the region, The prediction results of the heterogeneous auxiliary correction network for the label data correspond to R pot Probability map of the region, y pot Indicates that it corresponds to R pot The ground truth of the region.

[0060] The student network and the heterogeneous auxiliary correction network branch can generate different prediction results for the same data. For the different prediction parts, this part can be used as a potential area. There may be some wrong predictions in the potential area. At the same time, the heterogeneous auxiliary correction network branch can also provide supplementary information for the student network for the potential area.

[0061] S4: In the unsupervised learning stage, the unlabeled data is strongly perturbed using Cutout, and then input into the three branches. The confidence mask obtained by the classifier and the projector are used to select positive / negative sample pairs for comparative learning.

[0062] Among them, in the unsupervised learning stage of this embodiment, the unlabeled data is strongly perturbed by Cutout, and then input into the three branches. The confidence mask obtained by the classifier and the projector are used to select positive / negative sample pairs for comparative learning. The specific process is as follows: In the unsupervised learning process, we first use Cutout strong perturbation on the unlabeled data, and then input it into the student network, HAR branch and teacher network. We add a classifier to the third layer of the Decoder of the three branch networks, and add a projector after the second convolution layer of the Decoder of the student branch and the teacher branch. The input of the classifier is the feature map output by the previous convolution layer. The three classifiers output three masks—Pseudo-masks respectively. The three Psudo-masks are logically ANDed to obtain a new mask—Confidence Positive mask (CPM). Then, the CPM is logically NOT operated to obtain the Confidence Negative mask (CNM). The input of the projector is the feature map output by the previous convolution layer. The projectors of the student branch and the teacher branch output two feature maps respectively: F s , F t . CPM is divided into F s , F t Element-wise multiplication, in F s , F t The areas corresponding to CPM are obtained respectively, which are recorded as: We from The positive samples are taken from the corresponding position pixels as positive sample pairs. Then CNM and F t Element-wise multiplication, in F t Get the area corresponding to CNM, denoted as We are Select negative sample pairs from above, and all pixels between them are negative samples. After sampling the positive and negative sample pairs, we use voxel-level contrast loss to pull the positive samples together and expand the edges between negative samples, thereby improving the compactness between similar voxels and the separability between voxels of different categories. Given an anchor voxel j, calculate the contrast loss:

[0063]

[0064] Among them, k + Indicates from The positive samples extracted from Indicates from The selected negative samples, N is the number of sampled negative samples, and τ is a temperature parameter.

[0065] S5: inputting the training set into the semi-supervised medical image segmentation network model for training to obtain a trained semi-supervised medical image segmentation network model;

[0066] It should be noted that the loss function used by the semi-supervised medical image segmentation network model of this embodiment consists of a supervised loss function and an unsupervised loss function. The supervised loss function includes a Dice loss function, a cross entropy loss function, and a complementary correction loss function; the unsupervised loss function includes a consistency loss function and a contrast loss function.

[0067] S6: Input the test set into the trained semi-supervised medical image segmentation network model to obtain the medical image segmentation results.

[0068] It should be noted that, in this embodiment, the test set is input into the trained semi-supervised medical image segmentation network model, and the average prediction results of the HAR branch and the teacher branch are calculated as the final medical image segmentation result.

[0069] In order to verify the superiority of the method of the present invention, a comparative experiment was conducted between the present invention and the current optimal semi-supervised medical image segmentation method; and the semantic segmentation field evaluation standards: Dice, Jaccard, 95HD, ASD were used.

[0070] The data of the method of the present invention respectively uses two data sets: the first data set is a left atrium data set, and the second data set is a pancreas data set.

[0071] 1. Test the left atrium data:

[0072] (1) Crop the images into a uniform size: 112*112*80, use 80 images as the training set and 20 images as the test set.

[0073] (2) Enhance the training set images by using random rotation, random Gaussian noise and other operations.

[0074] Table 1 shows the comparison results of the semi-supervised medical image segmentation method based on confidence mask guided contrastive learning proposed by the present invention on the left atrium dataset and some of the current optimal methods. As can be seen from Table 1, the present invention shows a more excellent effect, reaching 89.95%, 81.97%, 6.07, and 2.26 in the four evaluation indicators, respectively, exceeding the segmentation performance of the current optimal model.

[0075] Table 1: Test results based on the left atrium dataset

[0076]

[0077] 2. Test the pancreas data:

[0078] (1) The images were cropped into a uniform size of 96*96*96, 60 images were used as the training set, and 20 images were used as the test set.

[0079] (2) Enhance the training set images by using random rotation, random Gaussian noise and other operations.

[0080] Table 2: Test results based on the pancreas dataset

[0081]

[0082] Table 2 shows the comparison results of the semi-supervised medical image segmentation method based on confidence mask guided contrastive learning proposed by the present invention on the pancreas dataset and some of the current best methods. As can be seen from Table 2, the present invention shows a better effect, reaching 74.87%, 61.11%, 10.47, and 3.05 in the four evaluation indicators, respectively, exceeding the segmentation performance of the current best model.

[0083] Although the content of the present invention has been described in detail through the above preferred embodiments, it should be appreciated that the above description should not be considered as a limitation of the present invention. After reading the above content, it will be apparent to those skilled in the art that various modifications and substitutions of the present invention will occur. Therefore, the protection scope of the present invention should be limited by the appended claims.

Claims

1. A semi-supervised medical image segmentation method based on confidence mask guided contrastive learning, characterized in that: The following steps are involved: S1: Collect medical image datasets and preprocess the images to construct training and test sets; S2: Build a semi-supervised medical image segmentation network model, which includes: a basic semi-supervised network model and a heterogeneous auxiliary correction network branch (HAR). S3: In the supervised learning stage, the labeled data and the unlabeled data are cross-momentum mixed and then input into the student branch and the HAR branch. The HAR branch is used to supervise the student network training, correct the prediction errors of the student branch, and provide complementary information for it. S4: In the unsupervised learning stage, strong perturbations are applied to the unlabeled data, which are then input into the three branches. The confidence masks obtained by the classifier and the projector are used to select positive / negative sample pairs for comparative learning. S5: inputting the training set into the semi-supervised medical image segmentation network model for training to obtain a trained semi-supervised medical image segmentation network model; S6: Input the test set into the trained semi-supervised medical image segmentation network model to obtain the medical image segmentation results.

2. The semi-supervised medical image segmentation method based on confidence mask guided contrastive learning according to step S1 of claim 1, characterized in that: The specific process of the preprocessing is: randomly cutting the collected medical image data into a uniform size, performing random rotation and random Gaussian noise data enhancement, and expanding the data set.

3. The semi-supervised medical image segmentation method based on confidence mask guided contrastive learning according to claim 1, characterized in that: The loss function adopted by the semi-supervised medical image segmentation network model consists of a supervised loss function and an unsupervised loss function.

4. The semi-supervised medical image segmentation method based on confidence mask guided contrastive learning according to step S3 of claim 1, characterized in that: The cross-momentum hybrid method is used to use unlabeled data to provide more comprehensive feature information in the supervised learning stage. The specific process is: calculate the mean μ and variance σ of each unlabeled data in a Batch, and use the momentum update method to obtain the momentum mean μ of the Batch. b and momentum variance σ b . In obtaining the momentum mean μ b and momentum variance σ b Afterwards, cross-momentum blending is performed with the labeled data.

5. The semi-supervised medical image segmentation method based on confidence mask guided contrastive learning according to step S3 of claim 1, characterized in that: The HAR branch is used to supervise the student branch training, correct the prediction errors of the student branch, and provide complementary information for it. The specific process is: input the labeled data after cross-momentum mixing into the student branch and the HAR branch, and obtain two predictions respectively: Through the two prediction results, we can get the potential area of ​​the student branch’s prediction results for the label data and calculate the complementary correction loss L mr To optimize the prediction accuracy of the student branch for the potential area.

6. The semi-supervised medical image segmentation method based on confidence mask guided contrastive learning according to step S4 of claim 1, characterized in that: The confidence mask obtained by the classifier and the projector are used to select positive / negative sample pairs for comparative learning. The specific process is as follows: classifiers are added to the third layer of the decoders of the three branches, and projectors are added after the second convolutional layer of the decoders of the student and teacher branches. The input of the classifier is the feature map output by the previous convolutional layer. The three classifiers output three masks respectively. The masks are logically ANDed to obtain the Confidence Positive mask (CPM). Then, the CPM is logically NOT operated to obtain the Confidence Negative mask (CNM). The projectors of the student and teacher branches output two feature maps respectively: F s , F t . CPM is divided into F s , F t Multiply, in F s , F t The area corresponding to CPM is obtained as: We from Take positive samples on the corresponding position as positive sample pairs. t Multiply, in F t Get the area corresponding to CNM, denoted as We are After sampling the positive and negative sample pairs, the voxel-level contrast loss is used to improve the compactness between similar voxels and the separability between voxels of different categories.

7. The semi-supervised medical image segmentation method based on confidence mask guided contrastive learning according to step S6 of claim 1, characterized in that: The test set is input into the trained semi-supervised medical image segmentation network model, and the average prediction results of the HAR branch and the teacher branch are calculated as the final medical image segmentation result.