Semi-supervised three-dimensional left atrial image segmentation method based on u-kan network and related device
By using an improved U-KAN network and teacher-student model framework, combined with uncertainty estimation and a dual cross-attention mechanism, the problem of insufficient accuracy and speed in left atrial image segmentation is solved, achieving high-precision and fast segmentation suitable for real-time clinical applications.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- 湖南工商大学
- Filing Date
- 2025-04-18
- Publication Date
- 2026-04-10
AI Technical Summary
Existing technologies are insufficient in terms of segmentation accuracy and speed in left atrial image segmentation, especially under semi-supervised learning conditions where it is difficult to effectively utilize unlabeled data for efficient training.
An improved U-KAN network is adopted, combined with a teacher-student model framework, and reliable unlabeled targets are selected through uncertainty estimation. A dual cross-attention mechanism and a novel unsupervised consistent loss function are added to optimize the student model.
It achieves high-precision and fast left atrial image segmentation with a Dice coefficient of 92.5% and a boundary IoU of 88.7%. Moreover, it only requires 10% of the labeled data to achieve the effect of a fully supervised method, meeting the needs of real-time clinical applications.
Smart Images

Figure CN120088488B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application relates to the technical field of medical image processing, in particular to a semi-supervised three-dimensional left atrial image segmentation method based on a U-KAN network and a related device. BACKGROUND
[0002] Atrial fibrillation is a common arrhythmia disease that increases the risk of stroke, heart failure and other cardiovascular complications. Although the risk of disease can be reduced through treatment, atrial fibrillation is usually occult and difficult to diagnose and intervene in a timely manner. The main diagnosis methods of atrial fibrillation are cardiac palpation, optical plethysmography, blood pressure monitoring vibration method, electrocardiogram and image-based method. The main type of atrial fibrillation is paroxysmal atrial fibrillation, and the first four diagnosis methods may not be able to capture the onset of atrial fibrillation, and the diagnosis cycle is long, the cost is high, the accuracy is low and it is easily influenced by doctors. The anatomical structure of the left atrium provides important information for the pathology and research progress of atrial fibrillation, and the analysis of atrial fibrillation based on medical images needs to accurately segment the left atrium, calculate the clinical indicators of atrial fibrillation such as ejection fraction, left atrial volume, left atrial strain and strain rate through the segmentation result, and then quantitatively evaluate the function of the left atrium.
[0003] The purpose of medical image segmentation is to delineate the anatomical structures of interest, such as organs and tumors, from the original image by labeling each pixel as a certain class, which is the basis and important step for many clinical methods such as computer-aided diagnosis, treatment planning and radiotherapy. Accurate segmentation can provide reliable volume and shape information to assist further clinical applications. According to the labeling of the data, medical image segmentation is usually divided into supervised, semi-supervised and unsupervised image segmentation. The advantage of supervised image segmentation is that the model can be trained based on carefully labeled data, but it is difficult to obtain a large amount of labeled data for medical images. In order to reduce the burden of manual annotation, people have invested a lot of efforts to study the labeling efficient method for medical image segmentation task, including expanding the training data by label generation, data augmentation, using external related labeled data sets and using unlabeled data of semi-supervised learning. Among these methods, semi-supervised segmentation is a more practical method, which encourages the segmentation model to use the unlabeled data which is easier to obtain, and combines with a limited number of labeled data for training, which has a great influence on the real-world clinical application. Therefore, in recent years, semi-supervised medical image segmentation has attracted more and more attention in the field of medical imaging and computer vision. Semi-supervised learning aims to use a large amount of unlabeled data combined with labeled data to train a higher performance segmentation model. Semi-supervised medical image segmentation methods are divided into the following three strategies: 1) semi-supervised learning with pseudo-label, that is, first predict the unlabeled image, and then use the segmentation model to pseudo-label, and then use it as a new sample for further training; 2) semi-supervised learning with unsupervised regularization, which uses unlabeled images and labeled data together to train a segmentation model with unsupervised regularization, mainly including consistency learning, co-training, adversarial learning and entropy minimization; 3) semi-supervised learning with knowledge prior, which uses unlabeled images to make the model have knowledge prior such as target shape and position, and improve the representation ability of medical image segmentation. For medical image segmentation, U-Net is one of the most important architectures, which is famous for its symmetric encoder-decoder style architecture and skip connection, in which various encoders and decoders extract feature information at different levels, and skip connection realizes efficient conversion of feature information. Most studies further explore U-Net through advanced network block technologies such as dense connection, residual block, attention mechanism, deep convolution and sub-convolution, thus producing various improved U-Net in CT, MR and ultrasound medical image segmentation. U-Net has become the cornerstone of various visual applications, although many innovative designs and improvements have been introduced by integrating transformers or MLPs, these networks are still limited to linear modeling patterns and lack interpretability.
[0004] Therefore, how to improve the segmentation accuracy and segmentation speed in the left atrial image segmentation process has become a technical problem to be solved. SUMMARY
[0005] In order to improve the segmentation accuracy and speed in the left atrial image segmentation process, the application provides a semi-supervised three-dimensional left atrial image segmentation method based on a U-KAN network and related devices.
[0006] In the first aspect, the semi-supervised three-dimensional left atrial image segmentation method based on the U-KAN network provided by the application adopts the following technical scheme:
[0007] A semi-supervised three-dimensional left atrial image segmentation method based on a U-KAN network includes the following steps:
[0008] S1: Preprocess the medical image, input the labeled image into the student model, obtain the segmentation prediction of the labeled image, and calculate the supervised loss;
[0009] S2: Input the unlabeled image into the teacher model to make the teacher model generate segmentation prediction and estimate the uncertainty of each image;
[0010] S3: According to the uncertainty estimation of the teacher model, screen out reliable unlabeled targets for the student model to learn;
[0011] S4: Input the unlabeled image into the student model for segmentation prediction, calculate the unsupervised consistency loss with the teacher model, and the total loss is the sum of the supervised loss and the unsupervised consistency loss;
[0012] S5: Optimize the student model by minimizing the total loss, and update the teacher model using the exponential moving average;
[0013] S6: Use the trained student model to perform three-dimensional left atrial image segmentation;
[0014] The backbone network of the student model and the teacher model is an improved U-KAN network, and the improved U-KAN network includes:
[0015] The encoder part is composed of three convolutional blocks and two labeled KAN blocks;
[0016] The decoder part is composed of two labeled KAN blocks and three convolutional blocks;
[0017] The jump connection part adds a double cross-attention mechanism to narrow the semantic gap between the encoder and the decoder features.
[0018] Optionally, the labeled KAN block is realized by the following steps:
[0019] The output features of the convolution stage are reshaped into a series of flattened patches and mapped to the latent embedding space through linear projection;
[0020] The embedded label is passed into the KAN layer to enable the KAN layer to realize feature extraction of multi-dimensional input through superposition of a series of one-dimensional continuous functions;
[0021] A deep convolution layer, a batch normalization layer and a RELU activation function are used after the KAN layer to refine the feature representation, and the original label is added as a residual through a residual connection.
[0022] Optionally, in the step S3, the uncertainty estimation is realized through Monte Carlo Dropout, comprising:
[0023] T random forward passes are performed on each unlabeled sample under random Dropout and input Gaussian noise to obtain a group of softmax probability vectors
[0024] The predicted entropy is calculated as the uncertainty measure u, and the formula is:
[0025]
[0026] wherein, is the probability of the occurrence of the c-th class in the t-th prediction.
[0027] Optionally, in the step S3, the calculation formula of the dynamic threshold is:
[0028] ρ t =C*γ -(t-1) ρ0
[0029] wherein, C and γ are constants greater than 1, ρ t represents the threshold value of the t-th iteration, and ρ0 represents the threshold value basic value at t = 1.
[0030] Optionally, the step of calculating the unsupervised consistency loss with the teacher model comprises:
[0031]
[0032] wherein, is an indicator function, Y is a threshold value for filtering uncertain predictions, and returns 1 if the uncertainty of the v-th voxel is lower than the threshold value Y, otherwise returns 0, to filter out reliable targets, γ is a scaling factor to adjust the influence degree of (f′ v -f v ) in the loss function, is the sum of the indicator functions, f′ v and f v are the prediction results of the teacher model and the student model at the v-th voxel position, respectively, (f′ v -f vThe result is the difference between the teacher model and the student model's predictions at the v-th voxel position, reflecting the degree of difference between the two models' predictions at that voxel position. v f′ is the uncertainty value on the vth vth voxel. v and They represent v respectively th The teacher model predicts the voxel and its surrounding voxels in the range [0, μ]. AVG(·) is an average function. For all voxels, the voxels in the edge region have a larger value than the average value of their surroundings and therefore have a higher α value and are considered important voxels. Conversely, voxels located in the foreground or background have values close to the average value of their surroundings and are considered simple voxels with α values close to 0. ε represents the minimum value.
[0033] Optionally, the step of calculating the supervised loss includes:
[0034]
[0035] Among them, L s This indicates a supervisory loss, q k,c p is the label of the k-th voxel in class c. k,c For the prediction of the k-th voxel in class c, H represents the height of the image, W represents the width of the image, and D represents the depth, which refers to the number of layers or voxel layers in the depth direction of the image.
[0036] Secondly, this application provides a semi-supervised three-dimensional left atrial image segmentation system based on a U-KAN network, which performs the method described above, including:
[0037] The preprocessing module is used to preprocess medical images. It inputs labeled images into the student model to obtain segmentation predictions of labeled images and calculates supervised loss.
[0038] The uncertainty assessment module is used to input unlabeled images into the teacher model so that the teacher model can generate segmentation predictions and estimate the uncertainty of each image;
[0039] The learning module is used to select reliable unlabeled targets for student models to learn from, based on the uncertainty estimate of the teacher's model.
[0040] The segmentation prediction module is used to input unlabeled images into the student model for segmentation prediction, calculate the unsupervised consistency loss with the teacher model, and the total loss is the sum of the supervised loss and the unsupervised consistency loss.
[0041] The update module optimizes the student model by minimizing the total loss and updates the teacher model using an exponential moving average.
[0042] The segmentation module is configured to perform three-dimensional left atrial image segmentation using the trained student model.
[0043] In a third aspect, the present application provides a computer device, comprising a memory and a processor, wherein the processor executes the method described above when running computer instructions stored in the memory.
[0044] In a fourth aspect, the present application provides a computer readable storage medium comprising instructions which, when executed on a computer, cause the computer to perform the method described above.
[0045] In summary, the present application has the following beneficial technical effects:
[0046] The present application pre-processes the medical image, inputs the labeled image into the student model to obtain the segmentation prediction of the labeled image and calculate the supervised loss, inputs the unlabeled image into the teacher model to make the teacher model generate the segmentation prediction and estimate the uncertainty of each image, screens out reliable unlabeled targets for the student model to learn according to the uncertainty estimation of the teacher model, inputs the unlabeled image into the student model to perform the segmentation prediction, calculates the unsupervised consistent loss with the teacher model, and the total loss is the sum of the supervised loss and the unsupervised consistent loss, optimizes the student model by minimizing the total loss, and updates the teacher model by using the exponential moving average, and uses the trained student model to perform three-dimensional left atrial image segmentation. In the scene of left atrial image segmentation, the technical effects of high segmentation accuracy and fast segmentation speed are realized. BRIEF DESCRIPTION OF DRAWINGS
[0047] Figure 1 is a computer device structure schematic diagram of a hardware running environment related to an embodiment scheme of the present application;
[0048] Figure 2 is a flowchart of a first embodiment of the semi-supervised three-dimensional left atrial image segmentation method based on the U-KAN network of the present application;
[0049] Figure 3 is a structure diagram of the improved U-KAN of the first embodiment of the semi-supervised three-dimensional left atrial image segmentation method based on the U-KAN network of the present application;
[0050] Figure 4 is an internal flowchart of Tok-KAN of the first embodiment of the semi-supervised three-dimensional left atrial image segmentation method based on the U-KAN network of the present application;
[0051] Figure 5 is a double cross-attention module of the first embodiment of the semi-supervised three-dimensional left atrial image segmentation method based on the U-KAN network of the present application;
[0052] Figure 6is a structural block diagram of a first embodiment of a semi-supervised three-dimensional left atrial image segmentation system based on a U-KAN network. DETAILED DESCRIPTION
[0053] In order to make the purposes, technical solutions and advantages of the present application clearer, the present application is further described in detail below with reference to the drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and do not limit the present application.
[0054] Reference Signs List Figure 1 , Figure 1 is a structural schematic diagram of a computer device of a hardware running environment related to the embodiment of the present application.
[0055] As shown in Figure 1 , the computer device can include a processor 1001, such as a central processing unit (CPU), a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. The communication bus 1002 is used to realize the connection and communication between these components. The user interface 1003 can include a display screen, an input unit such as a keyboard, and can also include a standard wired interface, a wireless interface. The network interface 1004 can optionally include a standard wired interface, a wireless interface (such as a wireless fidelity (Wi-Fi) interface). The memory 1005 can be a high-speed random access memory (RAM), and can also be a stable non-volatile memory (NVM), such as a disk memory. The memory 1005 can also be a storage device independent of the aforementioned processor 1001.
[0056] Those skilled in the art can understand that the structure shown in Figure 1 does not constitute a limitation on the computer device, and can include more or fewer components than the diagram, or combine certain components, or different component arrangements.
[0057] As shown in Figure 1 , the memory 1005 as a storage medium can include an operating system, a network communication module, a user interface module, and a semi-supervised three-dimensional left atrial image segmentation program based on a U-KAN network.
[0058] In Figure 1The network interface 1004 is mainly used for data communication with a network server, and the user interface 1003 is mainly used for data interaction with a user. The processor 1001 and the memory 1005 in the present application can be arranged in a computer device, and the computer device calls the U-KAN network-based semi-supervised three-dimensional left atrium image segmentation program stored in the memory 1005 through the processor 1001, and executes the U-KAN network-based semi-supervised three-dimensional left atrium image segmentation method provided in the embodiments of the present application.
[0059] The embodiments of the present application provide a U-KAN network-based semi-supervised three-dimensional left atrium image segmentation method, which refers to Figure 2 , Figure 2 FIG. 1 is a flowchart of a U-KAN network-based semi-supervised three-dimensional left atrium image segmentation method according to a first embodiment of the present application.
[0060] In the present embodiment, the U-KAN network-based semi-supervised three-dimensional left atrium image segmentation method comprises the following steps:
[0061] S1: Preprocessing the medical image, inputting the labeled image into the student model to obtain the segmentation prediction of the labeled image, and calculating the supervised loss.
[0062] It should be noted that the backbone network of the student model and the teacher model is an improved U-KAN network, and the improved U-KAN network comprises: an encoder part composed of three convolution blocks and two labeled KAN blocks; a decoder part composed of two labeled KAN blocks and three convolution blocks; and a jump connection part adding a double cross-attention mechanism, used to narrow the semantic gap between the encoder and the decoder features.
[0063] It can be understood that the structure of the improved U-KAN is as shown in Figure 3 The U-KAN adopts an encoder-decoder symmetric structure, in which the first three blocks use convolution operations, followed by two labeled KAN blocks. The decoder is composed of two labeled KAN blocks and three convolution blocks; including two stages, the convolution stage is consistent with the traditional U-Net, passing through a convolution layer, a batch normalization layer and an activation layer for feature extraction, wherein the internal process of Tok-KAN is as shown in Figure 4shown; tokenization KAN stage, first tokenization by reshaping the output features XL of the convolution stage into a series of flattened patches, then using a trainable linear projection to map the vectorized patches into a latent embedding space; given the obtained tokens, pass them into a series of KAN layers. Kolmogorov-Arnold Network (KAN) is derived from the Kolmogorov-Arnold representation theorem in mathematics, which states that under certain conditions, any multivariate continuous function can be represented as a superposition of a series of one-dimensional continuous functions:
[0064]
[0065] and are continuous one-dimensional functions. KAN of K layers can be described as a series of KAN layers nested:
[0066]
[0067] where represents the i-th layer of the entire KAN network layer; the input dimension of each layer is n in , and the output dimension is n out , composed of n in × n out activatable functions. The KAN network decomposes the multi-dimensional input into a series of one-dimensional function mappings, each one-dimensional function as a unit of the neural network, used to learn the data features of a specific dimension; after completing the one-dimensional function mapping, the KAN network superimposes all the output functions to obtain the final high-dimensional representation result.
[0068] After each KAN layer, these features are passed through an efficient deep convolutional layer and batch normalization layer and a RELU activation function for refining feature representation. Here a residual connection is used and the original token is added as a residual. Then apply layer normalization (LN) and pass the output features to the next module. The output of the k-th tokenization KAN module can be represented as:
[0069] Z k = LN(Z k-1 + DwConv(KAN(Z k-1 )))
[0070] where, is the output feature map of the k-th layer; with J module configurations in the tokenization KAN stage, the final output is Z K .
[0071] To narrow the semantic gap between encoder and decoder features, the present embodiment adds a dual cross-attention module in the skip connection of U-KAN, as shown in Figure 5 .
[0072] In a specific implementation, the dual cross-attention module includes the following steps:
[0073] Step 1: Multi-scale Patch Embedding: First, the input feature map is processed by multi-scale Patch Embedding, which converts feature information of different scales into embedding vectors. Here, the average pooling (Avg Pool) operation is used to reduce the spatial dimension of the feature map while retaining useful information.
[0074] Step 2: Projection+Reshape: The embedding vectors are projected and reshaped to obtain a series of tokens (i.e., T1, T2, …, T n ).
[0075] Step 3: Channel Cross-Attention: These tokens are processed by the channel cross-attention module and the spatial cross-attention module in turn. The purpose of the channel cross-attention module is to enhance the interaction between different channels. The specific steps are as follows:
[0076] Layer Norm+Query / Key / Value Projection: First, the input features are normalized by Layer Norm, and then the query (Q i ), key (K), and value (V) vectors are generated by projection.
[0077] Channel Attention Weight Calculation: When calculating the attention weight, the query vector is multiplied by the key vector, and then normalized by the softmax function to obtain the weight of each channel.
[0078] Apply Weight: The weight matrix is multiplied by the value vector to generate a new feature map to capture channel dependencies, as follows:
[0079]
[0080] where is a scaling factor, and the output of cross-attention is the weighted sum of values, where the weight is determined by the similarity between the query and the key.
[0081] Step 4: Spatial Cross-Attention: The spatial cross-attention module is mainly used to focus on the dependency relationship between different spatial positions in the feature map.
[0082] It should be noted that in the running process of the specific spatial cross-attention module, the following steps are mainly included:
[0083] 1. Layer Norm + Query / Key / Value projection: Similarly, first normalize the input features, and then generate query (Q), key (K) and value (V) vectors. i ) vectors.
[0084] 2. Spatial attention weight calculation: When calculating the spatial attention weight, the query vector is multiplied with the key vector, and then normalized by the softmax function to obtain the weight of each spatial position.
[0085] 3. Apply weight: Multiply the spatial attention weight with the value vector to generate a new feature map to capture the spatial dependency. The formula is as follows:
[0086]
[0087] It can be understood that the tokenized KAN block is implemented by the following steps: the output features of the convolution stage are reshaped into a series of flattened patches and mapped to the latent embedding space through linear projection; the embedded tokens are passed into the KAN layer to enable the KAN layer to realize feature extraction of multi-dimensional input through the superposition of a series of one-dimensional continuous functions; a deep convolution layer, a batch normalization layer and a RELU activation function are used after the KAN layer to refine the feature representation, and the original token is added as a residual through a residual connection.
[0088] S2: input the unlabeled image into the teacher model to make the teacher model generate segmentation prediction and estimate the uncertainty of each image.
[0089] S3: according to the uncertainty estimation of the teacher model, screen out reliable unlabeled targets for the student model to learn.
[0090] It can be understood that the teacher model not only outputs segmentation prediction, but also needs to estimate the uncertainty of the unlabeled sample; this embodiment uses Monte Carlo Dropout to estimate the uncertainty, and performs T random forward passes on the teacher model under random dropout and input Gaussian noise for each unlabeled input sample.
[0091] It should be noted that in the step S3, the uncertainty estimation is realized by Monte Carlo Dropout, which includes: performing T random forward passes on each unlabeled sample under random Dropout and input Gaussian noise to obtain a set of softmax probability vectors
[0092] (2) The prediction entropy is calculated as the uncertainty measure u, and the formula is:
[0093]
[0094] wherein, is the probability of the c-th class appearing in the t-th prediction.
[0095] It can be understood that in the step S3, the formula for calculating the dynamic threshold is:
[0096] p t =C*gamma -(t-1) p0
[0097] wherein, C and gamma are constants greater than 1, p t represents the threshold value of the t-th iteration, p0 represents the threshold value of the t = 1 moment, which is 0.7 in this embodiment.
[0098] In specific implementation, the dynamic threshold value is selected to measure the uncertainty of the unlabeled sample in this embodiment, and the threshold value is used as a measurement standard to filter out the relatively unreliable (high uncertainty) prediction of the teacher model at the voxel level, and only the specific (low uncertainty) prediction is selected as the target of the student model learning. For the dynamic threshold value, first, the initial threshold value p0 selected for the unlabeled data is obtained by running on the labeled data, and then the threshold value is gradually reduced in the optimization iteration process.
[0099] S4: inputting the unlabeled image into the student model to perform segmentation prediction, calculating the unsupervised consistency loss with the teacher model, and the total loss being the sum of the supervised loss and the unsupervised consistency loss.
[0100] It should be noted that medical images are very different from natural images, especially in their blurred boundaries, which indicates that a specific loss function needs to be designed to enhance the boundary attention. Therefore, a new unsupervised consistency loss is designed in this embodiment, which takes into account the boundary, and different weights are given to different regions, and higher weights are given to the boundary region, so as to improve the attention and perception ability of the boundary, and then optimize the student model.
[0101] In specific implementation, the step of calculating the unsupervised consistency loss with the teacher model includes:
[0102]
[0103] wherein, is an indicator function, Y is a threshold value for filtering uncertain predictions, and returns 1 if the uncertainty of the v-th voxel is lower than the threshold value Y, otherwise returns 0, which is used to select reliable targets, and gamma is a scaling factor used to adjust the(f′ v -fv The extent of this term's influence in the loss function. To sum the indicator functions, f′ v and f v These are the prediction results from the teacher model and the student model at the v-th voxel position, respectively. (f′) v -f v The result is the difference between the predictions of the teacher model and the student model at the v-th voxel position, reflecting the degree of difference in the prediction results of the two models at that voxel position. v f′ is the uncertainty value on the vth vth voxel. v and They represent v respectively th The teacher model predicts the voxel and its surrounding voxels in the range [0, μ]. AVG(·) is an average function. For all voxels, the voxels in the edge region have a larger value than the average value of their surroundings and therefore have a higher α value and are considered important voxels. Conversely, voxels located in the foreground or background have values close to the average value of their surroundings and are considered simple voxels with α values close to 0. ε represents the minimum value.
[0104] It's important to note that medical images differ significantly from natural images, particularly in their blurred boundaries. This necessitates designing a specific loss function to enhance boundary awareness. Therefore, we design a novel unsupervised consistency loss that prioritizes boundaries, assigning different weights to different regions and higher weights to boundary regions to improve boundary awareness and perception, thereby optimizing the student model.
[0105] For all voxels, those in the edge regions have values that differ significantly from the surrounding average, thus possessing higher α values and are considered "important voxels" requiring focused attention from the model. Conversely, voxels located in the foreground or background have values close to the surrounding average, indicating less variation; these are considered "simple voxels" with α values close to 0 and therefore require less attention.
[0106] It should be noted that the steps for calculating supervised loss include:
[0107]
[0108] Where, q k,c p is the label of the k-th voxel in class c. k,c Let H be the prediction of the k-th voxel in class c. H: Image height, W: Image width, D: Depth, representing the number of layers or voxel layers in the depth direction. The loss of the entire segmentation model is the sum of the supervised loss and the unsupervised consistency loss. The goal of the semi-supervised segmentation framework in this embodiment is to minimize the total loss and then back-train the student model.
[0109] The loss of the entire segmentation model is the sum of the supervised loss and the unsupervised consistency loss. The goal of the semi-supervised segmentation framework of the embodiment is to minimize the total loss, thereby training the student model in reverse.
[0110] S5: Optimize the student model by minimizing the total loss, and update the teacher model using the exponential moving average.
[0111] S6: Perform three-dimensional left atrial image segmentation using the trained student model.
[0112] In the teacher-student model basic framework, the backbone network V-Net is modified, and the new network KAN is applied to semi-supervised left atrial segmentation (U-KAN). At the same time, a double cross-attention mechanism is added to the skip connection of U-KAN, which gradually captures the channel and spatial dependencies in multi-scale encoder features to narrow the semantic gap between encoder and decoder features. Under the driving of uncertainty perception, a dynamic threshold is introduced to solve the problem of excluding too many pseudo-label correct unlabeled targets and selecting too many pseudo-label unreliable unlabeled targets caused by fixed threshold, thereby reducing the overall performance. At the same time, a new unsupervised consistency loss function is designed, which considers the boundary geometric constraint, so that the model pays more attention to the complex structure of the boundary area, thereby improving the segmentation accuracy.
[0113] In specific implementation, the semi-supervised three-dimensional left atrial image segmentation method based on U-KAN network proposed in the embodiment has the following advantages:
[0114] High-precision segmentation: Through the improved U-KAN network structure, combined with the double cross-attention mechanism and the labeled KAN block, multi-scale features can be effectively captured and the semantic gap between the encoder and the decoder can be narrowed, significantly improving the segmentation accuracy. Experiments show that in the three-dimensional left atrial image segmentation task, the Dice coefficient of the method reaches 92.5%, which is better than the traditional U-Net and V-Net networks.
[0115] Semi-supervised learning, reducing labeling cost: The teacher-student model framework is used to make full use of a large amount of unlabeled data and reduce the dependence on labeled data. Through the dynamic threshold to select reliable unlabeled targets, the pseudo-label error caused by the fixed threshold is avoided, and the generalization ability of the model is further improved. Experiments show that only 10% of the labeled data can achieve segmentation effect comparable to the full-supervised method.
[0116] Uncertainty perception, improving model robustness: The Monte Carlo Dropout is introduced for uncertainty estimation, which can effectively identify unreliable predictions and avoid the negative impact of false pseudo-labels on model training. The dynamic threshold mechanism further optimizes the selection of unlabeled data, ensuring that the model only learns reliable targets, and improving the robustness and stability of the model.
[0117] A boundary-aware loss function enhances the segmentation capability of complex regions: A novel unsupervised consistent loss function is designed, which, by weighting boundary regions, makes the model pay more attention to structurally complex boundary regions, significantly improving the accuracy of boundary segmentation. Experiments show that this method achieves an IoU (Intersection over Union) of 88.7% in the left atrial boundary region, outperforming traditional loss functions.
[0118] Highly computationally efficient and suitable for real-time clinical applications: The U-KAN network reduces computational complexity while maintaining high-precision feature extraction capabilities through labeled KAN blocks and one-dimensional function mapping. Experiments show that the average processing time for a single segmentation task is 0.8 seconds, meeting the needs of real-time clinical applications.
[0119] Wide applicability: This method is not only applicable to left atrial segmentation, but can also be extended to other medical image segmentation tasks, such as the segmentation of organs like the liver and lungs, and has broad application prospects.
[0120] This embodiment preprocesses medical images, inputting labeled images into a student model to obtain segmentation predictions for the labeled images and calculating supervised loss. Unlabeled images are then input into a teacher model to generate segmentation predictions and estimate the uncertainty of each image. Based on the uncertainty estimates of the teacher model, reliable unlabeled targets are selected for the student model to learn from. Unlabeled images are then input into the student model for segmentation prediction, calculating unsupervised consistency loss with the teacher model; the total loss is the sum of supervised and unsupervised consistency losses. The student model is optimized by minimizing the total loss, and the teacher model is updated using an exponential moving average. The trained student model is then used for 3D left atrial image segmentation. This achieves high segmentation accuracy and fast segmentation speed in the left atrial image segmentation scenario.
[0121] Furthermore, embodiments of this application also propose a computer-readable storage medium storing a program for semi-supervised three-dimensional left atrial image segmentation based on a U-KAN network. When the program for semi-supervised three-dimensional left atrial image segmentation based on a U-KAN network is executed by a processor, it implements the steps of the method for semi-supervised three-dimensional left atrial image segmentation based on a U-KAN network as described above.
[0122] Reference Figure 6 , Figure 6 This is a structural block diagram of the first embodiment of the semi-supervised three-dimensional left atrial image segmentation system based on the U-KAN network of this application.
[0123] like Figure 6 As shown, the semi-supervised three-dimensional left atrial image segmentation system based on the U-KAN network proposed in this application includes:
[0124] The preprocessing module 10 is configured to preprocess the medical images, input the labeled images into the student model, obtain segmentation prediction of the labeled images, and calculate supervised loss.
[0125] The uncertainty evaluation module 20 is configured to input the unlabeled images into the teacher model, so that the teacher model generates segmentation prediction and estimates uncertainty of each image.
[0126] The learning module 30 is configured to screen reliable unlabeled targets for the student model to learn according to the uncertainty estimation of the teacher model.
[0127] The segmentation prediction module 40 is configured to input the unlabeled images into the student model for segmentation prediction, calculate unsupervised consistency loss with the teacher model, and calculate total loss as a sum of the supervised loss and the unsupervised consistency loss.
[0128] The updating module 50 is configured to optimize the student model by minimizing the total loss, and update the teacher model by using exponential moving average.
[0129] The segmentation module 60 is configured to perform three-dimensional left atrium image segmentation using the trained student model.
[0130] It should be understood that the above is only illustrative, and does not constitute any limitation on the technical solutions of the present application. In specific applications, those skilled in the art can set up according to the needs, and the present application does not limit this.
[0131] The embodiment preprocesses the medical images, inputs the labeled images into the student model, obtains segmentation prediction of the labeled images, and calculates supervised loss. The unlabeled images are input into the teacher model, so that the teacher model generates segmentation prediction and estimates uncertainty of each image. According to the uncertainty estimation of the teacher model, reliable unlabeled targets are screened for the student model to learn. The unlabeled images are input into the student model for segmentation prediction, the unsupervised consistency loss with the teacher model is calculated, and the total loss is calculated as a sum of the supervised loss and the unsupervised consistency loss. The student model is optimized by minimizing the total loss, and the teacher model is updated by using exponential moving average. The trained student model is used for three-dimensional left atrium image segmentation. In the scenario of left atrium image segmentation, the technical effects of high segmentation accuracy and fast segmentation speed are achieved.
[0132] It should be noted that the above-described workflow is only illustrative and does not constitute a limitation on the scope of protection of the present application. In actual applications, those skilled in the art can select part or all of them according to actual needs to achieve the purpose of the embodiment, which is not limited here.
[0133] In addition, technical details not described in detail in the present embodiment can be found in the method for semi-supervised three-dimensional left atrial image segmentation based on a U-KAN network provided by any embodiment of the present application, which will not be described here.
[0134] Furthermore, it is to be understood that the terms "including", "comprising", "consisting of", or variations thereof herein are intended to be broad and encompass the terms "consisting essentially of" and "consisting of". It is not intended that any of the processes described herein be limited to the exact sequence set forth herein, unless such stage is specifically indicated in the claims. Thus, even though a description of a process or method includes, for example, certain acts, that process or method is not limited by those acts to the exclusion of other not specified. Further, the acts need not be performed in the order in which they are described, nor need they be performed in the same order by all or by any of the processes or methods.
[0135] The above-mentioned sequence numbers of the embodiments of the present application are only for description, and do not represent the advantages or disadvantages of the embodiments.
[0136] Those skilled in the art can clearly understand the above-mentioned embodiment method from the description of the above embodiments, which can be realized by software and necessary general hardware platform, of course, also can be realized by hardware, but in many cases, the former is a better embodiment. Based on such understanding, the technical solutions of the present application can be embodied in the form of a software product in essence or in the form of a software product that contributes to the prior art. The computer software product is stored in a storage medium (such as a read-only memory (ReadOnly Memory, ROM) / RAM, a magnetic disk, an optical disk), and includes a plurality of instructions for causing a terminal device (which can be a mobile phone, a computer, a server, or a network device) to execute the method of each embodiment of the present application. The above is only the preferred embodiment of the present application, and does not limit the patent scope of the present application. Any equivalent structure or equivalent process transformation, or direct or indirect application in other related technical fields, is also included in the patent protection scope of the present application.
Claims
1. A semi-supervised three-dimensional left atrial image segmentation method based on a U-KAN network, characterized in that, Includes the following steps: S1: Preprocess the medical images, input the labeled images into the student model, obtain the segmentation prediction of the labeled images, and calculate the supervised loss; S2: Input the unlabeled images into the teacher model so that the teacher model can generate segmentation predictions and estimate the uncertainty of each image; S3: Based on the uncertainty estimate of the teacher model, select reliable unlabeled targets for the student model to learn; Step S3 further includes: selecting a dynamic threshold that iterates over time, using this threshold as a metric to determine the level of uncertainty of unlabeled samples, filtering out relatively unreliable predictions from the teacher model at the voxel level, and selecting only specific predictions as the learning target of the student model. S4: Input the unlabeled image into the student model for segmentation prediction, calculate the unsupervised consistency loss with the teacher model, and the total loss is the sum of the supervised loss and the unsupervised consistency loss; S5: Optimize the student model by minimizing the total loss and update the teacher model using an exponential moving average; S6: Perform 3D left atrial image segmentation using a trained student model; The backbone networks of the student and teacher models are improved U-KAN networks, which include: The encoder part consists of three convolutional blocks and two tokenized KAN blocks; The decoder consists of two tokenized KAN blocks and three convolutional blocks; In the skip connection part, a dual cross-attention mechanism is added to reduce the semantic gap between encoder and decoder features; The step of calculating the unsupervised consistency loss with the teacher model includes: where, is an indicator function, Y is a threshold value for filtering uncertain predictions, returns 1 if the uncertainty of the v-th voxel is lower than the threshold value Y, otherwise returns 0, to filter out reliable targets, is a scaling factor to adjust the influence of this term in the loss function, is the sum of indicator functions, and are the prediction results of the teacher model and the student model at the v-th voxel position, respectively, is the difference between the prediction results of the teacher model and the student model at the v-th voxel position, reflecting the difference between the prediction results of the two models at the voxel position, is the uncertainty value of the v-th voxel, and respectively represent the prediction of the teacher model for the voxel and its surrounding [0, μ] range voxels, AVG(·) is an average function, for all voxels, the value of the edge region voxel is far away from the average value of its surrounding, so it has a higher value, which is considered as an important voxel, on the contrary, the voxel located in the foreground or background, its value is close to the average value of the surrounding, which belongs to a simple voxel, value close to 0, indicates a minimum value.
2. The method according to claim 1, characterized in that, The tokenized KAN block is implemented through the following steps: The output features of the convolution stage are reshaped into a series of flattened patches and mapped to the latent embedding space via linear projection. The embedded labels are passed to the KAN layer so that the KAN layer can extract features from the multidimensional input through the superposition of a series of one-dimensional continuous functions; After the KAN layer, deep convolutional layers, batch normalization layers, and ReLU activation functions are used to refine the feature representation, and the original labels are added as residuals through residual connections.
3. The method according to claim 1, characterized in that, In step S3, uncertainty estimation is achieved through Monte Carlo Dropout, including: For each unlabeled sample, perform T random forward passes under random Dropout and input Gaussian noise to obtain a set of softmax probability vectors. ; Calculate prediction entropy as a measure of uncertainty The formula is: in, , It is the first In the second prediction The probability of a class occurring.
4. The method according to claim 1, characterized in that, In step S3, the formula for calculating the dynamic threshold is: in, and A constant greater than 1 Indicates the first The threshold of the next iteration This represents the baseline threshold value at time t=1.
5. The method according to claim 1, characterized in that, The step of calculating the supervised loss includes: in, This indicates a loss of oversight. For the first The first in the class Individual labeling, For the first The first in the class Prediction of individual factors Indicates the height of the image. Indicates the width of the image. Depth refers to the number of layers or voxel layers in the image along the depth direction.
6. A semi-supervised three-dimensional left atrial image segmentation system based on U-KAN network, characterized in that, Performing the method as described in claim 1 includes: The preprocessing module is used to preprocess medical images. It inputs labeled images into the student model to obtain segmentation predictions of labeled images and calculates supervised loss. The uncertainty assessment module is used to input unlabeled images into the teacher model so that the teacher model can generate segmentation predictions and estimate the uncertainty of each image; The learning module is used to select reliable unlabeled targets for student models to learn from, based on the uncertainty estimate of the teacher's model. The segmentation prediction module is used to input unlabeled images into the student model for segmentation prediction, calculate the unsupervised consistency loss with the teacher model, and the total loss is the sum of the supervised loss and the unsupervised consistency loss. The update module optimizes the student model by minimizing the total loss and updates the teacher model using an exponential moving average. The segmentation module is used to segment 3D left atrial images using a trained student model.
7. A computer device, characterized in that, The device includes a memory and a processor, wherein the processor, when executing computer instructions stored in the memory, performs the method as described in any one of claims 1 to 5.
8. A computer-readable storage medium, characterized in that, Includes instructions that, when executed on a computer, cause the computer to perform the method as described in any one of claims 1 to 5.
Citation Information
Patent Citations
Semi-supervised medical image segmentation method, system, equipment and medium
CN117095014A
Semi-supervised embryo image cell debris segmentation method based on average teacher
CN118196418A