Embryo Development Quality Assessment Method and System Based on Test Time Adaptive Strategy

Through the knowledge distillation and dynamic learning rate adjustment of the teacher-student model, combined with memory bank storage characteristics and Shannon entropy loss, the catastrophic forgetting problem in the test time adaptive technology is solved, real-time, efficient evaluation and accurate classification of embryonic image sequences are achieved.

CN119941745BActive Publication Date: 2025-07-08WUHAN MUTUAL UNITED TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202510448169.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-04-10
Publication Date
2025-07-08
Estimated Expiration
2045-04-10

AI Technical Summary

Technical Problem

Test time adaptive technology has catastrophic forgetting problems in the evaluation of embryonic image sequence quality, affecting the model's real-time processing capabilities and classification accuracy.

Method used

The embryonic development quality evaluation method based on the test time adaptive strategy is adopted, and the knowledge distillation and dynamic learning rate adjustment of the teacher-student model are optimized, and the parameters of the student model are optimized to achieve online processing of embryonic image sequences.

Benefits of technology

It improves the stability and generalization capabilities of the model, supports real-time evaluation of embryo image sequences, without waiting for all data to be received, protects patient privacy, and improves classification accuracy and model adaptability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119941745B_ABST
    Figure CN119941745B_ABST
Patent Text Reader

Abstract

The present invention discloses an embryo development quality assessment method and system based on a test time adaptive strategy. The method includes the following steps: training a model using a labeled embryo image training set to obtain a source model, and initializing the parameters of a teacher-student model using the source model; inputting a set of embryo image sequences to be evaluated into the teacher model and the student model respectively, calculating the KL divergence between the prediction results output by the teacher model and the student model, and the Shannon entropy loss of the student model, and optimizing the parameters of the student model by minimizing the sum of the KL divergence and the Shannon entropy loss; storing the features of the embryo image sequences and the Shannon entropy loss as key-value pairs in a memory bank, comparing the Shannon entropy loss of the student model at the current time point and the previous time point, and dynamically adjusting the learning rate of the student model according to the change of the Shannon entropy loss; repeating the above steps until the prediction of all embryo image sequences to be evaluated is completed.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of artificial intelligence, and particularly relates to a method and system for evaluating embryo development quality based on a test-time adaptive strategy. Background Art

[0002] In vitro fertilization (IVF) technology offers hope for many infertile couples to have children. After the fertilized eggs develop into the embryo stage, embryo transfer is required, and the quality of the embryo is directly related to its subsequent development and success rate. Therefore, embryo quality assessment plays a crucial role in the assisted reproductive process. With the progress of computer technology and image sequence processing technology, it has become particularly important to improve the accuracy of embryo image sequence classification, which directly affects the subsequent diagnosis and treatment by doctors.

[0003] Initially, the classification of embryo image sequences mainly relied on morphological observation, and the quality was judged by evaluating features such as the appearance of the embryo, the number of cells, and the cell uniformity. However, this method relying on subjective judgment has limitations. Inexperienced doctors may obtain incorrect evaluation results due to differences in observation angles and subjective judgment criteria. With the rapid development of machine learning technology, machine learning-based methods have been widely used to process a large number of embryo image sequences. By extracting features and constructing models to classify and evaluate embryo quality, they have been generally recognized by industry insiders. To address the problems of inconsistent data distribution and the involvement of patient privacy in training data, source-free domain adaptation technology has emerged. The goal of source-free domain adaptation technology is to enable the model to have good performance on the target domain by learning the commonalities and differences between different domains. In the field of embryo image sequence quality assessment, the application of source-free domain adaptation technology is mainly to adjust the model trained on one or more source domains through a certain method so that it can adapt to the data distribution of the target domain. In the case where source domain data cannot be obtained and only target domain data is available, this method uses the source model obtained by training source domain data to test the target domain, thus well protecting the privacy of patients in embryo image sequence quality assessment. Although source-free domain adaptation technology can solve the problems of inconsistent data distribution and privacy protection, it has some challenges in practical applications. The training of source-free domain adaptation for embryo sequences is offline and requires the completion of a set of sequence images to be received before it can be carried out, which limits the real-time processing ability of the model. To be able to process the embryo image sequences received by the model in real time, test-time adaptation (TTA) technology has emerged. TTA supports online testing and can process the image sequences when they are received without waiting for all the image sequences to be received.

[0004] However, in the test-time adaptive TTA technology, as the model is continuously adjusted and updated during the test phase, the original structure of the model may change, resulting in catastrophic forgetting and a decline in the classification evaluation performance of the model. This indicates that although the passive domain adaptation technology has made progress in some aspects, further improvements are still needed to meet the requirements of real-time processing. Summary of the Invention

[0005] The present invention proposes an embryo development quality assessment method and system based on a test-time adaptive strategy, which solves the problem of possible catastrophic forgetting in the test-time adaptive technology during online testing.

[0006] To solve the above technical problems, the present invention provides an embryo development quality assessment method based on a test-time adaptive strategy, including the following steps:

[0007] Step S1: Train a model using a labeled embryo image training set to obtain a source model, and initialize the parameters of the teacher-student model using the source model;

[0008] Step S2: Input a set of embryo image sequences to be evaluated into the teacher model and the student model respectively, calculate the KL divergence between the prediction results output by the teacher model and the student model, and the Shannon entropy loss of the student model, and optimize the parameters of the student model by minimizing the sum of the KL divergence and the Shannon entropy loss;

[0009] Step S3: Store the features of the embryo image sequences and the Shannon entropy loss as key-value pairs in a memory bank, compare the Shannon entropy loss of the student model at the current time point and the previous time point, and dynamically adjust the learning rate of the student model according to the change of the Shannon entropy loss;

[0010] Step S4: Repeat Step S2 to Step S3 until the prediction of all embryo image sequences to be evaluated is completed.

[0011] Preferably, the expression for calculating the KL divergence in Step S2 is:

[0012] ;

[0013] In the formula, is the KL divergence between the teacher model and the student model; T ( x ) is the probability distribution of the embryo image sequences output by the teacher model belonging to each category; S ( x ) is the probability distribution of the embryo image sequences output by the student model belonging to each category.

[0014] Preferably, the expression for calculating the Shannon entropy loss in Step S2 is:

[0015] ;

[0016] wherein, is the Shannon entropy loss of the student model; is a random variable x taking the value probability; is a random variable x total number; is the base of the logarithm.

[0017] Preferably, the expression of the learning rate of the student model in step S3 is:

[0018] ;

[0019] wherein, is the learning rate of the student model; is the initial learning rate of the student model; is the base of the logarithmic function; is the decay rate; is the current iteration number; , are respectively the Shannon entropy losses of the student model at time points i and time point i -1.

[0020] Preferably, in step S4, after the student model has undergone a set number of self-training, the teacher model is updated according to the performance of the student model:

[0021] ;

[0022] wherein, , are respectively the parameters of the teacher model at time points i and time point i -1; is the decay factor; is the parameter of the student model at time point i .

[0023] Preferably, the method for obtaining the embryo image training set in step S1 includes the following steps:

[0024] Step S11: Collect multiple continuously captured embryo images, adjust each embryo image to the same size, and form an embryo image sequence;

[0025] Step S12: Analyze the embryo image sequence, evaluate the contrast between the embryo and the background in all embryo images, use the embryo images with a contrast less than the set threshold as low-contrast images, and enhance the contrast of the low-contrast images;

[0026] Step S13: Mark the developmental stages of the embryos in all embryo images to obtain an embryo image training set.

[0027] Preferably, in step S2, the teacher model and the student model output the probability distributions of the embryo image sequences belonging to each category, including the following steps:

[0028] Step S21: Uniformly divide each embryo image in the embryo image sequence into a plurality of image patches;

[0029] Step S22: Stretch the matrix corresponding to each image patch into a one-dimensional vector, and add positional encoding and temporal encoding to the one-dimensional vector;

[0030] Step S23: Extract the features of all image patches through a self-attention layer and a feed-forward network layer, and perform weighted summation on the features of all image patches to obtain the overall feature of the embryo image sequence;

[0031] Step S24: Input the overall feature into a multi-layer perceptron, and the multi-layer perceptron outputs the probabilities of the embryo image sequence belonging to each category.

[0032] Preferably, the memory bank follows the first-in-first-out rule.

[0033] Preferably, in step S4, when a new embryo image sequence arrives, the parameters of the teacher-student model are initialized using the source model.

[0034] The present invention also provides an embryo development quality evaluation system based on a test-time adaptation strategy, which is implemented based on the above-mentioned embryo development quality evaluation method based on a test-time adaptation strategy, and includes: a source model training module, an online prediction module, a loss value memory module, and a model update module;

[0035] The source model training module: Train an initial model using a labeled embryo image training set to obtain a source model, and the parameters of the source model are used to initialize the parameters of the teacher-student model;

[0036] The online prediction module: Receive the embryo image sequence to be evaluated as the input of the teacher-student model, and perform prediction using the current model parameters;

[0037] The loss value memory module: Store and manage the Shannon entropy loss value of the student model during the model prediction process, and save the feature of each embryo image sequence and the corresponding Shannon entropy loss as a key-value pair in the memory bank;

[0038] The model update module: adjusts the parameters of the student model according to the prediction results and Shannon entropy loss values output by the online prediction module, and updates the parameters of the teacher model through the exponential moving average, enabling mutual learning between the teacher and student models.

[0039] The advantages of the present invention at least include:

[0040] 1. Storing the features of the embryo image sequence and the Shannon entropy loss in the memory bank effectively preserves historical information, helps the model refer to previous experiences in subsequent training, and enhances the stability and generalization ability of the model;

[0041] 2. Through knowledge distillation, the student model can learn richer embryo image feature representations from the teacher model, thereby significantly improving the classification accuracy of the student model for embryo image sequences;

[0042] 3. Through the adaptive strategy of dynamically adjusting the learning rate, the student model reduces the learning rate when the classification performance of the embryo image sequence deteriorates, effectively avoiding overfitting. At the same time, it maintains the learning rate when the model performance improves, promoting the model to converge faster to more accurately identify and classify embryo image sequences;

[0043] 4. Supports online processing of embryo image sequences to be evaluated, and can immediately evaluate when receiving embryo image sequences without waiting for the reception of all data. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] Figure 1 is a schematic flowchart of the method according to an embodiment of the present invention;

[0045] Figure 2 is a flowchart of the teacher model and the student model for processing embryo image sequences according to an embodiment of the present invention;

[0046] Figure 3 is a flowchart of the test time adaption according to an embodiment of the present invention;

[0047] Figure 4 is a schematic structural diagram of the memory bank according to an embodiment of the present invention;

[0048] Figure 5 is a schematic diagram of the adaptation process of the online test according to an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0049] The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Apparently, the described embodiments are only a part of the embodiments of the present invention, rather than all of the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.

[0050] As Figure 1 shown, an embodiment of the present invention provides an embryo development quality assessment method based on a test time adaptive strategy, including the following steps:

[0051] Step S1: Train a model using a labeled embryo image training set to obtain a source model, and initialize the parameters of the teacher-student model using the source model.

[0052] Specifically, the embryo image training set used in the embodiment of the present invention comes from multiple reproductive medical centers. Reproductive medical centers usually use time-lapse incubators to capture embryo images. This method can continuously record the development of embryos without disturbing their normal development. The captured images comprehensively cover all stages of embryo development, and each group of images contains a sequence of multiple continuously captured embryo images.

[0053] Adjust each embryo image to the same size, evaluate the contrast between the embryo and the background in all embryo images, regard the embryo images with a contrast less than the set threshold as low-contrast images, and enhance the contrast of the low-contrast images. Then mark the developmental stages of the embryos in all embryo images to obtain the embryo image training set. These preprocessing operations can effectively improve the robustness of the model, enabling the model to perform effective inference and classification under various test conditions.

[0054] The source model in the embodiment of the present invention is the video vision Transformer model ViViT. ViViT is a neural network model based on the self-attention mechanism, which performs well in the task of classifying embryo image sequences and has many characteristics such as good scalability and generalization ability. The teacher model in the teacher-student model is a large model, and the student model is a small model, and they adopt similar network structures.

[0055] Step S2: Input a group of embryo image sequences to be evaluated into the teacher model and the student model respectively, calculate the KL divergence between the prediction results output by the teacher model and the student model, and the Shannon entropy loss of the student model, and optimize the parameters of the student model by minimizing the sum of the KL divergence and the Shannon entropy loss.

[0056] Specifically, Figure 2 is a schematic flow chart of the probability distributions of the embryo image sequences output by the teacher model and the student model belonging to each category. In the figure, CLS represents the classification identifier, including the following steps:

[0057] Step S21: Uniformly divide each embryo image in the embryo image sequence into image blocks of pixels.

[0058] Step S22: Stretch the matrix corresponding to each image patch into a one-dimensional vector, thereby converting the two-dimensional image data into one-dimensional sequence data, and adding positional encoding and temporal encoding to the one-dimensional vector.

[0059] Specifically, add positional encoding based on sine and cosine functions to each image patch to make up for the problem that the Transformer network is not sensitive to positional information, enabling the model to learn the relative positional relationship between image patches, which helps the model understand the spatial structure of the embryo image sequence. After linearly embedding and adding positional encoding to the image patches, send them into the SpatialTransformer encoder, and add temporal encoding to each image.

[0060] Step S23: Extract the features of all image patches through the self-attention layer and the feed-forward network layer, and perform weighted summation on the features of all image patches to obtain the overall features of the embryo image sequence.

[0061] Specifically, send the sequence of image patches with positional encoding and temporal encoding into the Temporal Transformer encoder, which includes multiple self-attention layers and feed-forward networks, and can capture the dependencies between image patches and extract the key features of image patches. Multiple heads of the multi-head self-attention mechanism process the sequence of image patches in parallel as independent attention modules, calculate attention scores, and dynamically adjust the contribution of each image patch to the final feature representation.

[0062] The feed-forward neural network further performs non-linear transformation on the features output by the self-attention layer, refines the information in the image patch features, integrates features such as cell morphology and density, and generates more representative features.

[0063] After being processed by multiple Transformer layers, the features of the image patches are fully extracted and transformed. The features of all image patches are fused by means of weighted average or concatenation, and the local image patch features are integrated into the overall features of the embryo image sequence.

[0064] Step S24: Input the overall features into a multi-layer perceptron, and the multi-layer perceptron outputs the probabilities of the embryo image sequence belonging to each category.

[0065] Specifically, input the overall features into the multi-layer perceptron MLP Head, which contains multiple fully connected layers. The first fully connected layer performs linear transformation and non-linear activation on the input features, and the second fully connected layer continues to perform similar operations on the output of the first fully connected layer and maps it to the final output dimension. Finally, determine the category to which the embryo image sequence belongs through the probability corresponding to each category, and complete the classification task of the embryo image sequence.

[0066] Such as Figure 3As shown, for a set of embryonic image sequences, they are input into the teacher model for testing. The teacher model outputs the probability distribution of each embryonic image sequence belonging to each category, and these probability distributions contain the teacher model's understanding of the high-level features of the embryonic image sequences and classification knowledge. The student model also receives this set of embryonic image sequences as input and then outputs its own predicted probability distribution. The feature extraction and classification capabilities learned by the teacher model are imparted to the student model through knowledge distillation. Specifically, the KL divergence is used to measure the difference between the prediction results of the student model and the teacher model, and then knowledge distillation is achieved by minimizing the KL divergence. The calculation formula of the KL divergence is as follows:

[0067] ;

[0068] In the formula, is the KL divergence between the teacher model and the student model; T ( x ) is the probability distribution of the embryonic image sequence output by the teacher model belonging to each category; S ( x ) is the probability distribution of the embryonic image sequence output by the student model belonging to each category.

[0069] In the embodiment of the present invention, the Shannon entropy is used as the loss function of the student model. The Shannon entropy can be used as a measure of the complexity of a system. If the system is more complex and the number of different situations is more, then the information entropy of the system is greater. The calculation formula of the Shannon entropy is as follows:

[0070] ;

[0071] In the formula, is the Shannon entropy loss of the student model; is the random variable x takes the value probability; is the random variable x total number; is the base of the logarithm.

[0072] The greater the uncertainty of the model prediction result, that is, the more uniform the probability distribution, the greater the value of Shannon entropy. Conversely, when the predicted probability of a certain category by the model approaches 1 and the probabilities of other categories approach 0, Shannon entropy approaches 0. For example, in the case where embryos are divided into two categories: high-quality and low-quality, if the model predicts that the probability of an embryo being high-quality is 0.9 and the probability of being low-quality is 0.1, the Shannon entropy is relatively low at this time; if the model predicts that the probabilities of high-quality and low-quality are both 0.5, the Shannon entropy is higher, indicating that the uncertainty of the model prediction is greater. Therefore, choosing Shannon entropy as the loss function can directly measure the difference between the model prediction result and the ideal deterministic classification. By minimizing Shannon entropy, the uncertainty of the model prediction can be reduced, thereby improving the accuracy of the model classification.

[0073] Step S3: Store the features of the embryo image sequence and the Shannon entropy loss as key-value pairs in the memory bank, compare the Shannon entropy losses of the student model at the current time point and the previous time point, and dynamically adjust the learning rate of the student model according to the change of the Shannon entropy loss.

[0074] Specifically, in order to avoid catastrophic forgetting during the update of the student model, the memory bank is combined with the adaptive learning rate of the student model.

[0075] The memory bank is usually a repository that stores a large amount of data features or intermediate results of the model. In the context of embryo classification, it can store the feature representations of previously processed embryo image sequences, the prediction results of the model for these image sequences, or other relevant information. What is stored in the memory bank in the embodiments of the present invention are the features of the samples and their corresponding Shannon entropy loss values, and the memory bank is updated by continuously storing new sample features and Shannon entropy loss values. The memory bank follows the first-in, first-out rule. First, the memory bank is filled, and then at each time node, one sample feature goes out and one sample feature comes in, and the adaptive in the test stage is not started until the memory bank is filled.

[0076] First, input the embryo image sequence into the student model, and obtain the feature representation of the image sequence through the feature extraction layer of the student model. Store these feature representations in the memory bank. At the same time, the model obtains the predicted category probability distribution through the classification head, and then calculates the Shannon entropy loss value of the current prediction result. As Figure 4 shown, in the embodiments of the present invention, the features of the image sequence are used as the key, and the Shannon entropy loss value is used as the value. The image sequence features and the corresponding Shannon entropy loss values are stored in the memory bank in the form of key-value pairs for convenient subsequent retrieval and use.

[0077] Compare the Shannon entropy loss value of the student model at the current time point with that at the previous time point. If the Shannon entropy loss value increases, it indicates a decline in the performance of the student model, and then update the learning rate of the student model; if the Shannon entropy loss value decreases, it means the current student model has better performance, and continue to use the current learning rate. The expression for updating the learning rate is:

[0078] ;

[0079] In the formula, is the learning rate of the student model; is the initial learning rate of the student model; is the base of the logarithmic function; is the decay rate; is the current iteration number; , are respectively the Shannon entropy losses of the student model at time points i and time point i -1.

[0080] After minimizing the sum of the KL divergence and the Shannon entropy loss, update the parameters of the student model through backpropagation. During the backpropagation process, adjust the weight matrix, bias, etc. in the Transformer layer of the student model according to the gradient information of the loss and the current learning rate. In this way, while considering the current sample information, the model combines the classification situations of similar samples in the memory bank and the dynamically changing learning rate, and gradually optimizes its own parameters, improving the classification ability of the model for the embryo image sequence.

[0081] After the student model undergoes self-training for a certain stage, update the teacher model using the exponential moving average:

[0082] ;

[0083] In the formula, , are respectively the parameters of the teacher model at time points i and time point i -1; is the decay factor, used to balance the weights of the teacher model and the student model. In the embodiment of the present invention, is taken as 0.99, which can not only enable the model to be stably trained but also maintain the smoothness of the teacher model; is the parameter of the student model at time point i .

[0084] Through the process of mutual learning between the teacher model and the student model, the prior knowledge of the teacher model and the learning potential of the student model can be fully utilized to improve the overall performance and generalization ability of the model in the embryo classification problem, reduce the dependence on a large amount of labeled data, and gradually optimize the model's understanding of the characteristics of embryo image sequences and classification decision-making ability.

[0085] Step S4: Repeat Step S2 to Step S3 until the prediction is completed for all embryo image sequences to be evaluated.

[0086] As Figure 5 shown is the adaptive process of realizing online testing in the embodiment of the present invention. Denote the student model after initializing the source model as f 0, select the embryo image sequence 1 to be evaluated as f the input of 0, use the embryo image sequence 1 to be evaluated to train the source model, update the parameters of the student model after completing one training cycle epoch, and obtain the updated model f s,1 . Subsequently, use f s,1 to predict the embryo image sequence 1 to be evaluated and output the corresponding prediction result. Then, introduce the next embryo image sequence 2 to be evaluated, and input it into the model f s,1 obtained in the previous step. The model adjusts and updates the parameters again according to the new input, so as to obtain a further updated model f s,2 . Repeat the above operation process, that is, input the current embryo image sequence to be evaluated into the model f s,i-1 obtained in the previous update. After one epoch of training, the model is updated to f s,i , and predict the embryo image sequence to be evaluated. Repeat this process until the prediction is completed for all embryo image sequences to be evaluated.

[0087] When a new batch of embryo image sequences arrives, initialize the parameters of the student model to f the parameter settings of 0 to adapt to the characteristics of the new data distribution. During the entire online testing process, the model is iteratively updated and adapted by continuously using the newly input test samples to realize real-time classification of the continuously input embryo image sequences. Moreover, in this process, the classification results of each time can be collected, sorted out and analyzed, so as to realize the effective management and utilization of the classification results. The memory bank effectively ensures the stability and reliability of the model during long-term continuous operation and in the process of facing different batches of data input, enabling it to always maintain relatively good classification performance and adaptability in a changing data environment.

[0088] The method of the present invention adopts a teacher-student mutual learning strategy. During the backpropagation of the student model, the memory bank is combined with the learning rate of the model to dynamically adjust the learning rate, avoiding catastrophic forgetting of the model and improving the stability and generalization of the model. By using a pre-trained model for testing, the number of accesses to the source domain data is greatly reduced, protecting the privacy of patients.

[0089] The embodiment of the present invention also provides an embryo development quality assessment system based on a test-time adaptation strategy, which is implemented based on the above-mentioned embryo development quality assessment method based on a test-time adaptation strategy, and includes: a source model training module, an online prediction module, a loss value memory module, and a model update module.

[0090] The source model training module trains an initial model using a training set of embryo images with labels to obtain a source model, and the parameters of the source model are used to initialize the parameters of the teacher-student model.

[0091] The online prediction module is used to receive a sequence of embryo images to be evaluated as the input of the teacher-student model and make predictions using the current model parameters.

[0092] The loss value memory module is used to store and manage the Shannon entropy loss value of the student model during the model prediction process, and save the features of each embryo image sequence and the corresponding Shannon entropy loss as key-value pairs in the memory bank.

[0093] The model update module adjusts the parameters of the student model according to the prediction results and Shannon entropy loss values output by the online prediction module, and updates the parameters of the teacher model through an exponential moving average, enabling mutual learning between the teacher and student models.

[0094] The technical features of the above embodiments can be combined arbitrarily. For the sake of brevity of description, not all possible combinations of the technical features in the above embodiments are described. Only the preferred embodiments of the present invention are expressed. The description is relatively specific and detailed, but it should not be construed as a limitation to the scope of the present invention. As long as the combination of these technical features does not conflict, it should be considered as the scope recorded in this specification.

[0095] It should be noted that for those of ordinary skill in the art, without departing from the concept of the present invention, several deformations and improvements can still be made, and these all belong to the protection scope of the present invention. Therefore, the protection scope of the present invention should be subject to the appended claims.

Claims

1. An embryo development quality assessment method based on a test time adaptive strategy, characterized in that It includes the following steps: Step S1: Train a model using a labeled embryo image training set to obtain a source model, and initialize the parameters of the teacher-student model with the source model; Step S2: Input a set of embryo image sequences to be evaluated into the teacher model and the student model respectively, calculate the KL divergence between the prediction results output by the teacher model and the student model, and the Shannon entropy loss of the student model, and optimize the parameters of the student model by minimizing the sum of the KL divergence and the Shannon entropy loss; The expression for calculating the Shannon entropy loss is: where \(H(x)\) is the Shannon entropy loss of the student model; \(p(x i )\) is the probability that the random variable \(x\) takes the value \(x i \); \(n\) is the total number of the random variable \(x\); \(b\) is the base of the logarithm; Step S3: Store the features of the embryo image sequence and the Shannon entropy loss as key-value pairs in the memory bank, compare the Shannon entropy loss of the student model at the current time point and the previous time point, and dynamically adjust the learning rate of the student model according to the change of the Shannon entropy loss; The expression for the learning rate of the student model is: Where r is the learning rate of the student model; a is the initial learning rate of the student model; e is the base of the natural logarithm function; k is the decay rate; t is the current number of iterations; H i and H i-1 are the Shannon entropy losses of the student model at time point i and time point i - 1, respectively; Step S4: Repeat Step S2 to Step S3 until the prediction of all embryo image sequences to be evaluated is completed.

2. The method for evaluating the quality of embryo development based on a test time adaptive strategy according to claim 1, wherein: The expression for calculating the KL divergence in Step S2 is: where D KL is the KL divergence between the teacher model and the student model; T(x) is the probability distribution of the embryo image sequence output by the teacher model belonging to each category; S(x) is the probability distribution of the embryo image sequence output by the student model belonging to each category.

3. The method for evaluating the quality of embryo development based on a test time adaptive strategy according to claim 1, wherein: In Step S4, after the student model has undergone a set number of self-training, update the teacher model according to the performance of the student model: In the formula, are the parameters of the teacher model at time point i and time point i - 1 respectively; λ is the decay factor; is the parameter of the student model at time point i.

4. The embryo development quality assessment method based on a test time adaptive strategy according to claim 1, wherein: The method for obtaining the embryo image training set in Step S1 includes the following steps: Step S11: Collect multiple continuously captured embryo images, adjust each embryo image to the same size to form an embryo image sequence; Step S12: Analyze the embryo image sequence, evaluate the contrast between the embryo and the background in all embryo images, regard the embryo images with a contrast less than the set threshold as low-contrast images, and enhance the contrast of the low-contrast images; Step S13: Mark the developmental stages of the embryos in all embryo images to obtain an embryo image training set.

5. The method for evaluating the quality of embryonic development based on a test time adaptive strategy according to claim 1, characterized in that: In Step S2, the teacher model and the student model output the probability distributions of the embryo image sequences belonging to each category, including the following steps: Step S21: Uniformly divide each embryo image in the embryo image sequence into several image patches; Step S22: Stretch the matrix corresponding to each image patch into a one-dimensional vector, and add position encoding and time encoding to the one-dimensional vector; Step S23: Extract the features of all image patches through the self-attention layer and the feed-forward network layer, and perform weighted summation on the features of all image patches to obtain the overall features of the embryo image sequence; Step S24: Input the overall features into a multi-layer perceptron, and the multi-layer perceptron outputs the probabilities of the embryo image sequence belonging to each category.

6. The method for evaluating the quality of embryonic development based on a test time adaptive strategy according to claim 1, characterized in that: The memory bank follows the first-in-first-out rule.

7. The method for evaluating the quality of embryo development based on a test time adaptive strategy according to claim 1, wherein: In Step S4, when a new embryo image sequence arrives, initialize the parameters of the teacher-student model with the source model.

8. An embryo development quality assessment system based on a test time adaptive strategy, which is implemented based on an embryo development quality assessment method based on a test time adaptive strategy according to any one of claims 1 to 7, and is characterized in that It includes: A source model training module, an online prediction module, a loss value memory module, and a model update module; The source model training module: Train an initial model using a labeled embryo image training set to obtain a source model, and the parameters of the source model are used to initialize the parameters of the teacher-student model; The online prediction module: Receive the embryo image sequence to be evaluated as the input of the teacher-student model, and perform prediction using the current model parameters; The loss value memory module: stores and manages the Shannon entropy loss value of the student model during the model prediction process, and saves the features of each embryo image sequence and the corresponding Shannon entropy loss as key-value pairs in the memory bank; The model update module: adjusts the parameters of the student model according to the prediction results and Shannon entropy loss values output by the online prediction module, and updates the parameters of the teacher model through the exponential moving average to enable mutual learning between the teacher-student models.

Citation Information

Patent Citations

  • Tire pattern classification method, system, medium and equipment based on grouping decoder

    CN116091849A

  • Pathological sensor large model construction method

    CN118173244A

  • Separation and identification method for multi-source hybrid ultra-high frequency partial discharge diagram

    WO2023213332A1