A transformer-based unsupervised domain adaptation medical semantic segmentation method

By employing an unsupervised adaptive medical semantic segmentation method based on Transformer, and utilizing data augmentation, 3D reconstruction, and adaptive generative enhancement techniques, an unsupervised adaptive retinal image segmentation network is constructed. This method solves the segmentation accuracy problems of uneven gray levels and small blood vessel branches in retinal vessel segmentation, achieving high-precision automated segmentation.

CN118537559BActive Publication Date: 2026-11-27HUAIYIN INSTITUTE OF TECHNOLOGY
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410722066.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-05
Publication Date
2026-11-27
Estimated Expiration
2044-06-05

AI Technical Summary

Technical Problem

Existing retinal vessel segmentation algorithms struggle to achieve ideal segmentation accuracy when dealing with details such as uneven grayscale distribution and fine vessel branches, and also suffer from domain offset issues.

Method used

An unsupervised adaptive medical semantic segmentation method based on Transformer is adopted. An unsupervised adaptive retinal image segmentation network is constructed through data augmentation, ray projection 3D reconstruction, local attention mechanism and adaptive generative enhancement (AGA) method. Iterative training is carried out using self-training and dual-teacher network to reduce the domain gap.

Benefits of technology

It improves the accuracy and detail of retinal vessel segmentation, simplifies segmentation complexity, and achieves automated, high-precision retinal vessel segmentation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118537559B_ABST
    Figure CN118537559B_ABST
Patent Text Reader

Abstract

The application discloses a kind of based on Transformer's unsupervised domain self-adapting medical semantic segmentation method, pre-processing is carried out to retinal blood vessel segmentation image by data enhancement method, and three-dimensional reconstruction is carried out using light projection algorithm;Then the backbone network of retinal image semantic segmentation is constructed, an encoder-decoder structure is used, and the characteristics are handled in the encoder module by introducing local attention mechanism RWA;Then self-training is carried out using unsupervised domain self-adapting framework, an intermediate domain is introduced between source domain and target domain, and combined with adaptive generation enhancement AGA hybrid processing is used to reduce the gap between domains, and training weight is obtained by the alternating training mode of double teacher network;Finally, the training weight optimized is used to carry out blood vessel segmentation to retinal image.The application has good application in medical field, can improve blood vessel segmentation accuracy, and reduce labor cost.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of medical image semantic segmentation technology, specifically relating to an unsupervised adaptive medical semantic segmentation method based on Transformer. Background Technology

[0002] Fundus images are one of the diagnostic tools for various retinal diseases, such as diabetic retinopathy and hypertensive retinopathy. The segmentation of retinal vessels in fundus images can help doctors effectively diagnose the condition of potential patients. Information such as the number, branching, and width of retinal vessels can be used to diagnose diseases related to retinal vessels. Analysis of these vessels enables early diagnosis and prevention of some diseases, possessing extremely important clinical medical value.

[0003] With the continuous development of medical technology and deep learning technology, many deep learning-based retinal vessel segmentation methods have been proposed. In traditional medical image segmentation, ophthalmologists need to manually analyze the vascular structures in fundus images, which is a time-consuming and highly subjective task. Deep learning-based retinal vessel segmentation methods, however, do not require manual feature selection. Instead, they automatically learn and extract key features from images using large-scale data. Furthermore, through iterative optimization, the segmentation accuracy of the algorithm can be continuously improved. In comparison, these methods offer higher accuracy, faster image segmentation speed, and lower cost.

[0004] Due to the uneven grayscale distribution in fundus retinal images and insufficient ability to segment details such as fine blood vessel branches, coupled with the low contrast of blood vessels exacerbating domain shift, existing retinal vessel segmentation algorithms struggle to achieve ideal results in segmenting fine blood vessels. Summary of the Invention

[0005] Objective: To address the problems raised in the background technology, this invention provides an unsupervised domain adaptive medical semantic segmentation method based on Transformer. This invention primarily utilizes an unsupervised domain adaptive UDA model built based on Transformer, effectively reducing the domain gap and achieving segmentation of details such as fine blood vessel branches, thereby improving the accuracy of blood vessel segmentation.

[0006] Technical Solution: This invention proposes an unsupervised adaptive medical semantic segmentation method based on Transformer, comprising the following steps:

[0007] Step 1: Using the retinal vessel segmentation dataset, preprocess the dataset images using data augmentation methods;

[0008] Step 2: Based on Step 1, the retinal vessel image is reconstructed in three dimensions using the ray casting algorithm in volume rendering;

[0009] Step 3: Construct a Transformer-based retinal image segmentation backbone network, adopting an encoder-decoder structure and introducing a Local Attention (RWA) mechanism to process features;

[0010] Step 4: Introduce an intermediate domain between the source domain and the target domain, use the adaptive generative enhancement AGA method to mix the data, and use self-training and dual-teacher networks to build an unsupervised domain adaptive retinal image segmentation network model based on Transformer.

[0011] Step 5: Iteratively train the Transformer-based unsupervised adaptive retinal image segmentation network model, obtain the optimal training weights through alternating training with a dual-teacher network, and then use the optimized model to segment blood vessels in retinal images.

[0012] Furthermore, step 1 includes scaling and cropping the masked images and original images of the retinal vessel segmentation dataset; then, color jittering and Gaussian blur are used to further enhance the data, and the enhanced dataset is used to generate training, validation and test sets.

[0013] Furthermore, the specific steps of the 3D reconstruction using the ray casting algorithm in step 2 are as follows:

[0014] Step 2.1: Use the threshold method to classify the foreground and background. Assign certain color values ​​and opacities to the separated foreground voxels according to the gray-scale-color transfer function and the gray-scale-opacity transfer function, while assigning an opacity value of 0 to the background voxels.

[0015] Step 2.2: Reflect light along a defined angle, obtaining K sampling points through the retina. Select the nearest voxel *a* and perform cubic linear interpolation to calculate color and opacity. Calculate the color and opacity of the sampling points using a lighting model;

[0016] Step 2.3: Calculate the color value and opacity value of each ray's sample point, and then synthesize them from back to front. The formula is expressed as follows:

[0017]

[0018] Among them, C O C represents the color value of light after passing through the i-th voxel; I This represents the color value when light enters the i-th voxel; C represents the opacity of the i-th voxel; i This represents the color value of the i-th voxel.

[0019] Furthermore, in step 3, the encoder part first uses a retinal blood vessel image of size H*W*3, and decomposes it into overlapping image blocks through a sliding window. Then, it uses the Local Attention (RWA) mechanism to analyze these image blocks and feeds them forward to the Transformer encoders at different stages.

[0020] Furthermore, the calculation formula for the Local Attention Mechanism (RWA) in step 3 is as follows:

[0021] Step 3.1: Spatial Information Extraction (SIE): Extract the distance information from pixels to the target domain boundary from the retinal image. The shortest distance from pixel P to boundary E is SIE(P), calculated using the following formula:

[0022] SIE(P) = min(|P,Q|), Q∈E

[0023] Where P is any point within the target area, Q is the pixel on the boundary that is closest to point P, E is the boundary of the target area, and |P,Q| is the distance between P and Q.

[0024] Step 3.2: Spatial Feature Adjustment (SFA): Adjust the feature representation of pixels based on the spatial information results; assuming P(i,j) is the pixel to be calculated, the calculation process of the local attention coefficient SFA(P) is as follows:

[0025]

[0026] Where SaveX(i) and SaveY(j) represent the maximum distance values ​​in the X-axis and Y-axis directions, respectively.

[0027] Furthermore, step 4 specifically involves the following steps:

[0028] Step 4.1: Using a self-training method, first obtain a set of annotated images K from the source domain. S , represented as in It is the i-th image in the source domain. yes The corresponding annotation or label, N s yes

[0029] Total number of images; secondly, the sample annotations in the target domain are... in It is the i-th image in the target domain. yes The corresponding annotation or label, N t It represents the total number of images; finally, a large amount of unlabeled data is obtained from the target domain, i.e. in It is the i-th unlabeled image in the target domain, N mThis represents the total number of unlabeled target domain images;

[0030] Step 4.2: First, perform student model g on the source domain. θ The model is trained using the cross-entropy loss function to measure the difference between the model's predictions and the ground truth labels, and its formula is expressed as follows:

[0031]

[0032] in, This represents the loss function over the source domain, where θ is the model parameter. Represents the true label of the i-th source image. With model prediction Cross-entropy between;

[0033] Step 4.3: Employ a dual-teacher network during the self-training process. and Alternating training is performed to generate pseudo-labels for the target domain data. The formula is as follows:

[0034]

[0035] in, This represents the pseudo-label probability of the j-th pixel corresponding to the i-th target domain image in category c. This probability is based on... Teacher network The j-th pixel of the image in all possible categories c ′ The prediction above determines the classification of a pixel by selecting the category c with the highest probability as the pseudo-label.

[0036] Step 4.4: Construct an unsupervised adaptive retinal image segmentation network model based on Transformer. First, extract source domain image features using high-resolution cropping and train the segmentation model, allowing the student network to obtain backpropagation gradient information. Second, perform mixed training between the source and intermediate domains using the Adaptive Generative Augmentation (AGA) method, allowing the student network to learn and perform gradient backpropagation. Next, perform a second mixed training between the source and target domains, allowing the student network to obtain backpropagated gradients, thereby deepening the student network's gradient learning. Finally, the student network g... θ Teacher Network and teacher network Training is performed alternately, and the exponential moving average (EMA) is updated to smooth the model's predictions.

[0037] Furthermore, during the training phase in step 4.3, the weights of the teacher model are continuously updated. The weight φ represents the exponential moving average (EMA) of the student model weights in different training steps. t+1The weight update process is shown in the following formula:

[0038] φ t+1 ←αφ t +(1-α)θ t

[0039] Where, φ t+1 These are the parameters of the teacher model at time t+1; α is the EMA decay coefficient, and α controls the parameter φ in the previous time period. t With the current student model parameters θ t Average weights; new teacher model parameters φ t+1 The teacher model parameter φ in the previous time period t and the current teacher model parameters θ t A weighted average is calculated between them.

[0040] Furthermore, in step 4.4, after introducing the intermediate domain during model training, the source and target domain data undergo two adaptive generation enhancement AGA hybrid processing steps to obtain the enhanced data; the loss function for the adaptive generation enhancement AGA process is shown in the following formula:

[0041]

[0042] Where L(θ) represents the loss function, θ is the model parameter, N is the number of samples, c is the number of classes, and y ij It is the actual label of the j-th class of the i-th sample in the original image. P is the actual label of the j-th class of the i-th sample in another image, β represents the area ratio of the original image in the synthesized image, and P is the actual label of the j-th class of the i-th sample in another image. ij This represents the probability that the model predicts for the j-th class in the i-th sample.

[0043] Furthermore, the total loss L is calculated using an unsupervised adaptive retinal image segmentation network model based on Transformer. all As shown in the formula:

[0044]

[0045] in, L represents the loss of the source domain. I L represents the loss of the intermediate domain. T This represents the loss in the target domain.

[0046] Beneficial effects: 1. The present invention provides an unsupervised adaptive medical semantic segmentation method based on Transformer, which uses the ray casting algorithm in volume rendering for three-dimensional reconstruction, which is beneficial to the preservation of image detail information and is suitable for the segmentation of blood vessels in retinal fundus images.

[0047] 2. The Transformer encoder-decoder architecture used in this invention offers advantages such as better handling of multivariate inputs and improved generalization ability. By introducing the Local Attention (RWA) mechanism into the encoder, the model can automatically learn important features of the target region, thereby reducing the loss of detailed information during retinal vessel segmentation.

[0048] 3. Introducing an intermediate domain between the source and target domains can effectively reduce the domain gap between the two domains, enhance feature representation, simplify the complexity of retinal and vascular medical image segmentation, and improve model performance.

[0049] 4. This invention constructs a novel unsupervised adaptive network model based on the Transformer, introduces an intermediate domain, and employs a hybrid processing approach of adaptive generation enhancement AGA and self-training to segment even fine vascular branch details. The method proposed in this invention can be used for computer-aided diagnosis in the medical field to achieve automated, high-precision retinal vessel segmentation. Attached Figure Description

[0050] Figure 1 The flowchart shows an unsupervised domain adaptive medical semantic segmentation method based on Transformer.

[0051] Figure 2 Image (a) is the original image of the retina, and image (b) is the three-dimensional reconstruction of the retina;

[0052] Figure 3 This is a general framework diagram of the Transformer encoder-decoder in this invention;

[0053] Figure 4 This is a diagram of the self-training framework after adding the intermediate domain in this invention. Detailed Implementation

[0054] The technical solution of the present invention will be further described below with reference to the accompanying drawings.

[0055] This invention proposes an unsupervised adaptive medical semantic segmentation method based on Transformer, such as... Figure 1 As shown, the specific steps include:

[0056] Step 1: Using the retinal vessel segmentation dataset, preprocess the dataset images using data augmentation methods. Specifically, the masked images and original images of the retinal vessel segmentation dataset are scaled and cropped; then, color dithering and Gaussian blur are used to further enhance the data, generating training, validation, and test sets from the augmented dataset.

[0057] Step 2: Based on Step 1, the ray casting algorithm in volume rendering is used to perform 3D reconstruction of the retinal vessel image. The results are shown in the attached figure. Figure 2 As shown. The specific steps of the ray casting algorithm for 3D reconstruction are as follows:

[0058] Step 2.1: Use the threshold method to classify the foreground and background. Assign certain color values ​​and opacities to the separated foreground voxels according to the gray-scale-color transfer function and the gray-scale-opacity transfer function, while assigning an opacity value of 0 to the background voxels.

[0059] Step 2.2: Reflect light along a defined angle, obtaining K sampling points through the retina. Select the 8 nearest voxels and perform cubic linear interpolation to calculate color and opacity. Calculate the color and opacity of the sampling points using a lighting model;

[0060] Step 2.3: Calculate the color value and opacity value of each ray's sample point, and then synthesize them from back to front. The formula is expressed as follows:

[0061]

[0062] Among them, C O C represents the color value of light after passing through the i-th voxel; I This represents the color value when light enters the i-th voxel; C represents the opacity of the i-th voxel; i This represents the color value of the i-th voxel.

[0063] Step 3: Construct a Transformer-based retinal image segmentation backbone network, adopting an encoder-decoder structure and introducing a Local Attention (RWA) mechanism to process features;

[0064] The specific process is as follows (see attached document). Figure 3 As shown, the encoder part uses a retinal blood vessel image of size H*W*3 and decomposes it into overlapping image blocks through a sliding window. Then, the Local Attention (RWA) mechanism is used to analyze these image blocks and feed them forward to the Transformer encoder at different stages.

[0065] Furthermore, the calculation formula for the Local Attention Mechanism (RWA) in step 3 is as follows:

[0066] Step 3.1: Spatial Information Extraction (SIE): Extract the distance information from pixels to the target domain boundary from the retinal image. The shortest distance from pixel P to boundary E is SIE(P), calculated using the following formula:

[0067] SIE(P) = min(|P,Q|), Q∈E

[0068] Where P is any point within the target area, Q is the pixel on the boundary that is closest to point P, E is the boundary of the target area, and |P,Q| is the distance between P and Q.

[0069] Step 3.2: Spatial Feature Adjustment (SFA): Adjust the feature representation of pixels based on the spatial information results; assuming P(i,j) is the pixel to be calculated, the calculation process of the local attention coefficient SFA(P) is as follows:

[0070]

[0071] Where SaveX(i) and SaveY(j) represent the maximum distance values ​​in the X-axis and Y-axis directions, respectively.

[0072] Step 4: An intermediate domain is introduced between the source and target domains. An adaptive generative augmented image processing (AGA) method is used to mix the data. A Transformer-based unsupervised adaptive retinal image segmentation network model is then constructed using self-training and a dual-teacher network. This includes the following steps:

[0073] Step 4.1: Using a self-training method, first obtain a set of annotated images K from the source domain. S , represented as in It is the i-th image in the source domain. yes The corresponding annotation or label, N s The total number of images; secondly, the sample annotations in the target domain are... in It is the i-th image in the target domain. yes The corresponding annotation or label, N t It represents the total number of images; finally, a large amount of unlabeled data is obtained from the target domain, i.e. in It is the i-th unlabeled image in the target domain, N m This represents the total number of unlabeled target domain images;

[0074] Step 4.2: First, perform student model g on the source domain. θ The model is trained using the cross-entropy loss function to measure the difference between the model's predictions and the ground truth labels, and its formula is expressed as follows:

[0075]

[0076] in, This represents the loss function over the source domain, where θ is the model parameter. Represents the true label of the i-th source image. With model prediction Cross-entropy between;

[0077] Step 4.3: Employ a dual-teacher network during the self-training process. and Alternating training is performed to generate pseudo-labels for the target domain data. The formula is as follows:

[0078]

[0079] in, This represents the pseudo-label probability of the j-th pixel corresponding to the i-th target domain image in category c. This probability is based on... Teacher network The j-th pixel of the image in all possible categories c ′ The prediction above determines the classification of a pixel by selecting the category c with the highest probability as the pseudo-label.

[0080] Step 4.4: Construct an unsupervised adaptive retinal image segmentation network model based on Transformer. First, extract source domain image features using high-resolution cropping and train the segmentation model, allowing the student network to obtain backpropagation gradient information. Second, perform mixed training between the source and intermediate domains using the Adaptive Generative Augmentation (AGA) method, allowing the student network to learn and perform gradient backpropagation. Next, perform a second mixed training between the source and target domains, allowing the student network to obtain backpropagated gradients, thereby deepening the student network's gradient learning. Finally, the student network g... θ Teacher Network and teacher network Training is performed alternately, and the exponential moving average (EMA) is updated to smooth the model's predictions.

[0081] In this step, after introducing the intermediate domain, the source and target domain data undergo two adaptive generation and enhancement AGA hybrid processing steps to obtain the enhanced data; the loss function of the adaptive generation and enhancement AGA process is shown in the following formula:

[0082]

[0083] Where L(θ) represents the loss function, θ is the model parameter, N is the number of samples, c is the number of classes, and y ij It is the actual label of the j-th class of the i-th sample in the original image. P is the actual label of the j-th class of the i-th sample in another image, β represents the area ratio of the original image in the synthesized image, and P is the actual label of the j-th class of the i-th sample in another image. ij This represents the probability that the model predicts for the j-th class in the i-th sample.

[0084] Step 5: Iteratively train the Transformer-based unsupervised adaptive retinal image segmentation network model. Optimal training weights are obtained through alternating training with a dual-teacher network. The optimized model is then used for vessel segmentation in retinal images. Finally, the total loss L is calculated using the Transformer-based unsupervised adaptive retinal image segmentation network model. all As shown in the formula:

[0085]

[0086] in, L represents the loss of the source domain. I L represents the loss of the intermediate domain. T This represents the loss in the target domain.

Claims

1. An unsupervised adaptive medical semantic segmentation method based on Transformer, characterized in that, Includes the following steps: Step 1: Using the retinal vessel segmentation dataset, preprocess the dataset images using data augmentation methods; Step 2: Use the ray casting algorithm in volume rendering to reconstruct the retinal blood vessel image in three dimensions; Step 3: Construct a Transformer-based retinal image segmentation backbone network, adopting an encoder-decoder structure and introducing a Local Attention (RWA) mechanism to process features; Step 4: An intermediate domain is introduced between the source domain and the target domain. The adaptive generative enhancement AGA method is used to mix the data. A Transformer-based unsupervised adaptive retinal image segmentation network model is constructed using self-training and a dual-teacher network. Step 5: Iteratively train the Transformer-based unsupervised adaptive retinal image segmentation network model, obtain the optimal training weights through alternating training with a dual-teacher network, and then use the optimized model to segment blood vessels in retinal images. The specific operation of step 4 is as follows: Step 4.1: Using a self-training approach, first obtain a set of annotated images from the source domain. , represented as ,in It is the i-th image in the source domain. yes The corresponding annotations or tags, The total number of images; secondly, the sample annotations in the target domain are... ,in It is the i-th image in the target domain. yes The corresponding annotations or tags, It represents the total number of images; finally, a large amount of unlabeled data is obtained from the target domain, i.e. ,in It is the i-th unlabeled image in the target domain. This represents the total number of unlabeled target domain images; Step 4.2: First, perform student modeling on the source domain. The model is trained using the cross-entropy loss function to measure the difference between the model's predictions and the ground truth labels, and its formula is expressed as follows: in, Represents the loss function over the source domain. These are model parameters. Represents the true label of the i-th source image. With model prediction Cross-entropy between; Step 4.3: Employ a dual-teacher network during the self-training process. and Alternating training is performed to generate pseudo-labels for the target domain data. The formula is as follows: in, This represents the pseudo-label probability of the j-th pixel corresponding to the i-th target domain image in category c. This probability is based on... Teacher network The j-th pixel of the image in all possible categories The prediction above determines the classification of a pixel by selecting the category c with the highest probability as the pseudo-label. Step 4.4: Construct an unsupervised adaptive retinal image segmentation network model based on Transformer. First, extract source domain image features using high-resolution cropping and train the segmentation model, allowing the student network to obtain backpropagation gradient information. Second, perform mixed training between the source and intermediate domains using the Adaptive Generative Augmentation (AGA) method, allowing the student network to learn and perform gradient backpropagation. Next, perform a second mixed training between the source and target domains, allowing the student network to obtain backpropagated gradients, thereby deepening the student network's gradient learning. Finally, the student network... Teacher Network and teacher network Training is performed alternately, and the exponential moving average (EMA) is updated to smooth the model's predictions.

2. The Transformer-based unsupervised adaptive medical semantic segmentation method according to claim 1, characterized in that, Step 1 includes scaling and cropping the masked images and original images of the retinal vessel segmentation dataset; then, color jittering and Gaussian blur are used to further enhance the data, and the enhanced dataset is used to generate training, validation and test sets.

3. The Transformer-based unsupervised adaptive medical semantic segmentation method according to claim 1, characterized in that, The specific steps of the 3D reconstruction using the ray casting algorithm in step 2 are as follows: Step 2.1: Use the threshold method to classify the foreground and background. Assign color values ​​and opacities to the separated foreground voxels according to the gray-scale-color transfer function and the gray-scale-opacity transfer function, while assigning an opacity value of 0 to the background voxels. Step 2.2: Reflect light along the defined angle to obtain K sampling points through the retina. Select the nearest voxel a and perform cubic linear interpolation to calculate the color and opacity. Use the lighting model to calculate the color and opacity of the sampling points. Step 2.3: Calculate the color value and opacity value of each ray's upsampling point, and then synthesize them from back to front. The formula is expressed as follows: = (1- ) + in, This represents the color value of the light after passing through the i-th voxel; This represents the color value when light enters the i-th voxel; Indicates the opacity of the i-th voxel; This represents the color value of the i-th voxel.

4. The Transformer-based unsupervised adaptive medical semantic segmentation method according to claim 1, characterized in that, In step 3, the encoder part uses a retinal blood vessel image of size H*W*3 and decomposes it into overlapping image blocks through a sliding window. Then, the Local Attention (RWA) mechanism is used to analyze these image blocks and feed them forward to the Transformer encoders at different stages.

5. The Transformer-based unsupervised adaptive medical semantic segmentation method according to claim 4, characterized in that, The formula for calculating the Local Attention Mechanism (RWA) in step 3 is as follows: Step 3.1: Spatial Information Extraction (SIE): Extract the distance information from pixels to the target domain boundary from the retinal image. The shortest distance from pixel P to boundary E is SIE(P), calculated using the following formula: SIE(P) = min(|P, Q|), Q ∈ E Where P is any point within the target area, Q is the pixel closest to point P on the boundary, E is the boundary of the target area, and |P, Q| is the distance between P and Q. Step 3.2: Spatial Feature Adjustment (SFA): Adjust the feature representation of pixels based on the spatial information results; assuming P(i,j) is the pixel to be calculated, the calculation process of the local attention coefficient SFA(P) is as follows: SFA(P) = 1 − Where SaveX(i) and SaveY(j) represent the maximum distance values ​​in the X-axis and Y-axis directions, respectively.

6. The Transformer-based unsupervised adaptive medical semantic segmentation method according to claim 1, characterized in that, During the training phase in step 4.3, the weights of the teacher model are continuously updated. Representing student model weights in different training steps Exponential Moving Average (EMA), Teacher Model The weight update process is shown in the following formula: in, These are the parameters of the teacher model at time t+1; It is the EMA attenuation coefficient. Control parameters of the previous time period With current student model parameters Average weights; new teacher model parameters The teacher model parameters in the previous time period and current student model parameters A weighted average is calculated between them.

7. The Transformer-based unsupervised adaptive medical semantic segmentation method according to claim 1, characterized in that, In step 4.4, during model training, after introducing the intermediate domain, the source domain and target domain data are subjected to two adaptive generation enhancement AGA hybrid processing steps to obtain the enhanced data. The loss function for the adaptive generation and enhancement of AGA is shown in the following formula: in, Represents the loss function. These are the model parameters, where N is the number of samples. It is the actual label of the j-th class of the i-th sample in the original image. It is the actual label of the j-th class of the i-th sample in another image. This indicates the area ratio of the original image to the composite image. This represents the probability that the model predicts for the j-th class in the i-th sample.

8. The Transformer-based unsupervised adaptive medical semantic segmentation method according to claim 1, characterized in that, The total loss is calculated using an unsupervised adaptive retinal image segmentation network model based on Transformer. As shown in the formula: = + + in, Indicates the loss of the source domain. Indicates the loss of the intermediate domain. This represents the loss in the target domain.

9. An electronic device, characterized in that, It includes a processor and a memory; the memory is used to store a computer program that is run by the processor to perform the Transformer-based unsupervised domain adaptive medical semantic segmentation method according to any one of claims 1-8.

Citation Information

Patent Citations

  • Brain magnetic resonance image segmentation method based on mixed space model

    CN106504254A

  • Transform-based efficient defogging semantic segmentation method and application thereof

    CN117058024A