Sudden death prediction method and device based on graph neural differential equation and uncertainty quantification

CN122677133BActive Publication Date: 2026-10-13ZHEJIANG SCI-TECH UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202611162602.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-08-03
Publication Date
2026-10-13
Estimated Expiration
2046-08-03

AI Technical Summary

Technical Problem

[0005]除此之外,猝死预测属于典型的安全关键场景,预测错误的代价具有高度不对称性:假阴性可能导致致命事件错失预防窗口,假阳性则可能引发不必要的有创干预

Benefits of technology

本申请实施例将时频能量矩阵沿频率维度连续划分为多个频带块,并以频带块为节点、基于节点间余弦相似度构建频带耦合图,显式建模了不同频带之间的耦合关系,而相似度阈值筛选可去除弱相关连接,降低图稀疏性带来的噪声,使模型能直接学习与心律失常易感性高度相关的病理性频带间交互模式;本申请实施例将频带耦合图映射为初始节点状态矩阵,并基于图邻接关系构建常微分动力学函数,通过自适应步长求解器求解得到终态节点状态矩阵,相比传统图神经网络固定层数的离散消息传递,能更精准地表征心电状态的渐进式非平稳过渡过程,减少过平滑风险;本申请实施例以最终猝死预测结果、预测熵值和对数方差三者共同作为模型输出,不仅给出分类结论,还从数据固有噪声和模型认知局限两个维度量化预测可靠性,为医生提供综合置信度评估,大幅提升猝死预测的临床实用性和可信度,降低假阳性和假阴性带来的不对称风险。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122677133B_ABST
    Figure CN122677133B_ABST
Patent Text Reader

Abstract

The application provides a sudden death prediction method based on a graph neural ordinary differential equation and uncertainty quantification, including: collecting an ECG signal segment of a user in real time, and performing wavelet transform on the ECG signal segment to obtain a two-dimensional time-frequency energy matrix; the time-frequency energy matrix is continuously divided into a plurality of frequency band blocks according to the frequency dimension, and a frequency band coupling graph is constructed based on the plurality of frequency band blocks; and the frequency band coupling graph is input into a pre-trained spatio-temporal graph neural ordinary differential equation prediction model to obtain a sudden death prediction result. In the scheme, the frequency band block is taken as a node, the frequency band coupling graph is constructed based on the cosine similarity between nodes, and the ordinary differential dynamics function is constructed based on the graph adjacency relationship in the frequency band coupling graph to update the features, which is highly consistent with the physical nature of cardiac electrical conduction, so that the gradual non-stationary transition process of the electrocardio state can be more accurately represented, and high-precision sudden death prediction can be performed.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of biomedical information processing, and in particular to a method and apparatus for predicting sudden death based on graph-Shen frequent differential equations and uncertainty quantification. Background Technology

[0002] Sudden cardiac death is a core component of cardiovascular disease deaths worldwide, accounting for approximately half of all cardiovascular deaths, with an overall survival rate of less than 10% for out-of-hospital cardiac arrest patients. Implantable cardioverter-defibrillators (ICDs) can significantly improve the long-term survival rate of high-risk patients; however, current clinical risk stratification systems primarily use left ventricular ejection fraction (LVEF) as the core assessment indicator, leaving a large number of occult high-risk individuals with normal left ventricular function uncovered by existing screening systems. Accurately identifying high-risk individuals before the onset of fatal arrhythmias and achieving actionable early warning remains a critical unresolved clinical need in the field of cardiovascular medicine.

[0003] Surface electrocardiography provides a feasible technical approach for non-invasive early warning of sudden cardiac death. Electrophysiological studies have confirmed that detectable abnormal precursors appear in electrocardiogram signals within tens of minutes before a fatal ventricular fibrillation attack, including changes in heart rate variability, slight fluctuations in the QT interval, and T-wave alternation. The core technical goal of automated sudden cardiac death prediction is to reliably extract these weak and slowly evolving abnormal features from electrocardiogram signals. Existing automated methods for predicting sudden cardiac death have undergone three generations of technological evolution: The first generation of methods, based on manually designed clinical features combined with shallow classifiers, extracts features such as heart rate variability statistics, T-wave alternation, and QT dispersion, and uses models such as support vector machines to achieve short-term prediction. This type of method has strong interpretability, but its feature expression ability is limited by predefined rules, and feature calculation is highly dependent on R-peak detection, resulting in insufficient reliability in abnormal cardiac scenarios where prognostic value is highest. The second generation of methods replaces manual feature engineering with end-to-end deep learning, using models such as one-dimensional convolutional neural networks, long short-term memory networks, and visual transformers to directly process ECG signals, eliminating the dependence on R-peak detection. However, it only treats ECG signals as time-domain sequences or simple time-frequency spectra, without explicitly modeling the correlation structure between signal spectral components. The third generation of methods introduces graph neural networks to model the spatial coupling relationship between ECG leads, further improving prediction performance, but still has fundamental technical shortcomings.

[0004] Existing ECG prediction methods based on graph neural networks generally employ discrete message passing mechanisms with a fixed number of layers, which cannot accurately characterize the continuous evolution of cardiac electrophysiological states. These models operate on raw time-domain signals or basic time-frequency spectra, making it difficult to depict the gradual, non-stationary transition of cardiac electrophysiological states in the prodromal period of sudden cardiac death, and they also fail to incorporate inter-band topological coupling relationships into their modeling scope. Furthermore, inter-band harmonic coupling and cross-frequency phase-amplitude coupling have been proven to be highly correlated with susceptibility to arrhythmias. Compared to the discrete layer stacking modeling approach, constructing frequency-level graph nodes segmented along the frequency axis and describing node state evolution with continuous-time differential equations better reflects the physical nature of cardiac electrical conduction and more faithfully captures the gradual changes in electrophysiological states.

[0005] In addition, sudden death prediction is a typical safety-critical scenario, and the cost of prediction errors is highly asymmetrical: false negatives may lead to missed preventative windows for fatal events, while false positives may trigger unnecessary invasive interventions. However, existing deep prediction models only output single-point classification results, which are prone to overconfident erroneous predictions on samples with strong signal noise or out-of-distribution data, and cannot distinguish between the inherent random noise of the input data and the cognitive limitations of the model itself. Summary of the Invention

[0006] This application provides a method and apparatus for predicting sudden death based on graph-based ordinary differential equations and uncertainty quantification. It constructs a frequency band coupling graph using frequency band blocks as nodes and cosine similarity between nodes, and then constructs an ordinary differential dynamic function based on the graph adjacency relationship in the frequency band coupling graph to update features. This method is highly consistent with the physical nature of cardiac electrical conduction, thereby more accurately representing the progressive non-stationary transition process of the electrocardiogram state for high-precision prediction of sudden death.

[0007] In a first aspect, embodiments of this application provide a sudden death prediction method based on graphical ordinary differential equations and uncertainty quantification, the method comprising:

[0008] The system acquires ECG signal segments from users in real time and performs wavelet transform on the ECG signal segments to obtain a two-dimensional time-frequency energy matrix. The time-frequency energy matrix is ​​continuously divided into multiple frequency bands along the frequency dimension, and a frequency band coupling graph is constructed based on the multiple frequency bands. The frequency band coupling graph uses the frequency bands as nodes and constructs edges based on the cosine similarity between different nodes. The frequency band coupling graph is input into a pre-trained spatiotemporal graph neural ordinary differential equation prediction model, which includes a spatiotemporal graph neural evolution network and a prediction network. In the spatiotemporal graph neural evolution network, the frequency band coupling graph is mapped to an initial node state matrix. Each row of the initial node state matrix corresponds to the feature of each node in the frequency band coupling graph. An ordinary differential dynamic function is constructed based on the adjacency relationship of the frequency band coupling graph and the initial node state matrix. The final state node state matrix is ​​obtained by solving the ordinary differential dynamic function. Each row of the final state node state matrix is ​​summed and pooled to obtain a graph-level embedding vector. The prediction network obtains the sudden death prediction result based on the graph-level embedding vector.

[0009] Secondly, embodiments of this application provide a sudden death prediction device based on graph-sense regular differential equations and uncertainty quantification, comprising: The data acquisition module is used to acquire ECG signal segments from users in real time and perform wavelet transform on the ECG signal segments to obtain a two-dimensional time-frequency energy matrix. The graph construction module is used to continuously divide the time-frequency energy matrix into multiple frequency bands according to the frequency dimension, and construct a frequency band coupling graph based on the multiple frequency bands. The frequency band coupling graph uses the frequency bands as nodes and constructs edges based on the cosine similarity between different nodes. The prediction module is used to input the frequency band coupling graph into a pre-trained spatiotemporal graph neural ordinary differential equation prediction model. The spatiotemporal graph neural ordinary differential equation prediction model includes a spatiotemporal graph neural evolution network and a prediction network. In the spatiotemporal graph neural evolution network, the frequency band coupling graph is mapped to an initial node state matrix. Each row of the initial node state matrix corresponds to the feature of each node in the frequency band coupling graph. An ordinary differential dynamic function is constructed based on the adjacency relationship of the frequency band coupling graph and the initial node state matrix. The final state node state matrix is ​​obtained by solving the ordinary differential dynamic function. Each row of the final state node state matrix is ​​summed and pooled to obtain a graph-level embedding vector. The prediction network obtains the sudden death prediction result based on the graph-level embedding vector.

[0010] Thirdly, embodiments of this application provide an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor is configured to run the computer program to execute a sudden death prediction method based on TuSinian frequent differential equations and uncertainty quantification.

[0011] Fourthly, embodiments of this application provide a readable storage medium storing a computer program, which, when executed by a processor, implements a sudden death prediction method based on graph-sense frequent differential equations and uncertainty quantification.

[0012] The main contributions and innovations of this invention are as follows: This application embodiment divides the time-frequency energy matrix continuously along the frequency dimension into multiple frequency bands, and constructs a frequency band coupling graph based on the cosine similarity between nodes, using the frequency bands as nodes. This explicitly models the coupling relationship between different frequency bands, while the similarity threshold filtering can remove weakly correlated connections, reduce noise caused by graph sparsity, and enable the model to directly learn pathological frequency band interaction patterns that are highly correlated with susceptibility to arrhythmias. This application embodiment maps the frequency band coupling graph to an initial node state matrix and constructs an ordinary differential dynamic function based on graph adjacency relationships, using an adaptive step-size solver. The final state matrix of the nodes is obtained by solving the problem. Compared with the discrete message passing of the fixed number of layers in the traditional graph neural network, it can more accurately represent the gradual non-stationary transition process of the electrocardiogram state and reduce the risk of oversmoothing. The embodiments of this application use the final sudden death prediction result, prediction entropy value and log variance as the model output. It not only provides a classification conclusion, but also quantifies the prediction reliability from two dimensions: inherent data noise and model cognitive limitations. It provides doctors with a comprehensive confidence assessment, which greatly improves the clinical applicability and credibility of sudden death prediction and reduces the asymmetric risk caused by false positives and false negatives.

[0013] Details of one or more embodiments of this application are set forth in the following drawings and description to make other features, objects and advantages of this application more readily apparent. Attached Figure Description

[0014] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings: Figure 1 This is a flowchart of a sudden death prediction method based on graphical ordinary differential equations and uncertainty quantification according to an embodiment of this application; Figure 2 This is a schematic diagram of a process for constructing a training dataset and generating a frequency band coupling map according to an embodiment of this application; Figure 3 This is a schematic diagram illustrating the acquisition of graph-level embedding vectors through a spatiotemporal graph neural evolution network according to an embodiment of this application; Figure 4 This is a schematic diagram illustrating the acquisition of sudden death prediction results through a prediction network according to an embodiment of this application; Figure 5 This is a structural block diagram of a sudden death prediction device based on graphical ordinary differential equations and uncertainty quantification according to an embodiment of this application; Figure 6 This is a schematic diagram of the hardware structure of an electronic device according to an embodiment of this application. Detailed Implementation

[0015] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numerals in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with one or more embodiments of this specification. Rather, they are merely examples of apparatuses and methods consistent with some aspects of one or more embodiments of this specification as detailed in the appended claims.

[0016] It should be noted that the steps of the corresponding methods are not necessarily performed in the order shown and described in this specification in other embodiments. In some other embodiments, the methods may include more or fewer steps than described in this specification. Furthermore, a single step described in this specification may be broken down into multiple steps in other embodiments; and multiple steps described in this specification may be combined into a single step in other embodiments.

[0017] Example 1 This application provides a sudden death prediction method based on graph-based ordinary differential equations and uncertainty quantification. This method uses frequency band blocks as nodes, constructs a frequency band coupling graph based on the cosine similarity between nodes, and builds an ordinary differential dynamic function based on the graph adjacency relationship in the frequency band coupling graph for feature updating. This highly aligns with the physical essence of cardiac electrical conduction, thereby more accurately representing the progressive non-stationary transition process of the electrocardiogram state for high-precision sudden death prediction. Specifically, refer to... Figure 1 The method includes: The system acquires ECG signal segments from users in real time and constructs a two-dimensional time-frequency energy matrix based on the denoised ECG signal segments. The time-frequency energy matrix is ​​continuously divided into multiple frequency bands along the frequency dimension, and a frequency band coupling graph is constructed based on the multiple frequency bands. The frequency band coupling graph uses the frequency bands as nodes and sets edges based on the cosine similarity between different nodes. The frequency band coupling graph is input into a pre-trained spatiotemporal graph neural ordinary differential equation prediction model, which includes a spatiotemporal graph neural evolution network and a prediction network. In the spatiotemporal graph neural evolution network, the frequency band coupling graph is mapped to an initial node state matrix. Each row of the initial node state matrix corresponds to the feature of each node in the frequency band coupling graph. An ordinary differential dynamic function is constructed based on the adjacency relationship of the frequency band coupling graph and the initial node state matrix. The final state node state matrix is ​​obtained by solving the ordinary differential dynamic function. Each row of the final state node state matrix is ​​summed and pooled to obtain a graph-level embedding vector. The prediction network obtains the sudden death prediction result based on the graph-level embedding vector.

[0018] In the current embodiment, this solution uses a smart wearable device to collect ECG signal segments from the user in real time, thereby enabling real-time prediction of the probability of sudden death.

[0019] In the current embodiment, the ECG signal segment is sampled to the target sampling frequency, the ECG signal segment at the target sampling frequency is denoised to obtain a denoised signal, and the denoised signal is subjected to continuous wavelet transform using Morlet wavelet as the mother wavelet to obtain a two-dimensional time-frequency energy matrix.

[0020] Specifically, since different devices have different native sampling frequencies when acquiring ECG signals, in order to eliminate the influence of different native sampling frequencies and avoid frequency band division deviation caused by sampling rate mismatch, this solution sets a target sampling frequency and uniformly samples the ECG signal to the target sampling frequency. For example, the target sampling frequency is 360Hz.

[0021] Specifically, in the denoising step of the ECG signal segment at the target sampling frequency, the ECG signal segment is decomposed into multiple feasible layers, and soft thresholding is applied to the detail coefficients of each feasible layer. Based on the detail coefficients of each layer after soft thresholding, the ECG signal segment is reconstructed by inverse discrete wavelet transform to obtain the denoised signal.

[0022] For example, the ECG signal segment is decomposed to the maximum feasible number of layers using Daubechies-4 as the mother wavelet. ,and ,in, This represents the total number of sampling points for the ECG signal segment. For the floor function, then for the th The detail factor of the layer is subject to soft thresholding, as expressed by the formula:

[0023] in, The first one after soft thresholding The detail factor of the layer, , For symbolic functions, These are the detail coefficients before soft thresholding. For the first Adaptive threshold of the layer To ensure that the detail coefficients after soft thresholding are non-negative, the adaptive threshold for each layer is set based on the noise standard deviation estimate of that layer.

[0024] Specifically, the ECG signal segments are reconstructed by inverse discrete wavelet transform based on the detail coefficients of each layer after soft thresholding to obtain a denoised signal, thereby preserving diagnostic morphological features while suppressing baseline drift and high-frequency electromyography interference.

[0025] Furthermore, the formula for performing continuous wavelet transform on the denoised signal using the Morlet wavelet as the mother wavelet is expressed as follows:

[0026] in, Represents continuous wavelet transform. This is a scale parameter used to control the frequency scale. These are translation parameters used to control the time step. For the mother wavelet function, This represents the complex conjugate operation. For time variables, To denoise the signal in time The signal amplitude at that location.

[0027] In other words, The frequency axis of the two-dimensional time-frequency energy matrix is... The time axis of the two-dimensional time-frequency energy matrix is ​​used to map the continuous signal amplitude to two dimensions through continuous wavelet transform. and The two-dimensional time-frequency energy matrix is ​​obtained from the matrix. For example, for a certain element in the two-dimensional time-frequency energy matrix... , indicating the first The frequency scale and the first Instantaneous energy density at each time step.

[0028] For example, if the length of the ECG information segment obtained in this scheme is 5 seconds, then the time range is 5 seconds, based on the translation parameter. Divide the time range into Number of time scales; frequency range from 0.5 Hz to 40 Hz, based on scale parameters. The frequency range is divided into F frequency scales, spanning the very low / low frequency HRV band (0.5–4Hz), the mid-frequency P / T wave band (4–15Hz), and the high-frequency QRS band (15–40Hz). This comprehensively covers the characteristic range of different rhythmic components of cardiac electrical activity, avoiding the omission of key frequency information related to arrhythmias.

[0029] In the current embodiment, this scheme uniformly divides the frequency matrix into N continuous frequency bands, each frequency band... Represented as ( Each frequency band block corresponds to a node represented as follows: N represents the number of frequency band blocks, which is 8 in this scheme.

[0030] Specifically, each frequency band block is flattened along the time dimension to obtain the initial feature vector of the corresponding node, i.e. ,in, For nodes The initial feature vector, The feature dimension of the initial feature vector means that each frequency band block retains the complete time trajectory of the corresponding frequency band within a 5-second window, so that subsequent inference is performed at the level of inter-band relationships rather than at the level of the original sampling points.

[0031] In the current embodiment, in the step of constructing the frequency band coupling graph, a cosine similarity threshold is set, the cosine similarity between different nodes is calculated, and an edge is constructed between two different nodes whose cosine similarity is greater than the cosine similarity threshold.

[0032] Specifically, for any two nodes and The formula for calculating cosine similarity is as follows:

[0033] in, For nodes and cosine similarity, For nodes The characteristics of a node Features Indicates transpose. It is the Euclidean norm.

[0034] by As a cosine similarity threshold, the formula for constructing edges in the frequency band coupling graph is expressed as:

[0035] in, Represents a node and Does an edge exist between them? This is an indicator function; it takes the value 1 if the condition within the parentheses is true, and 0 otherwise. For nodes and cosine similarity, The cosine similarity threshold is... The Kronecker delta function is used to constrain when... The value is 1 if the condition is met, and 0 otherwise, and is used to remove self-loops.

[0036] Specifically, the frequency band coupling map reflects the rhythm regularity through harmonic coupling, cross-frequency phase-amplitude coupling marks autonomic nervous regulation, and abnormal coupling patterns are related to susceptibility to arrhythmias, thus facilitating the model to directly learn pathological inter-frequency band interactions.

[0037] In the current embodiment, multiple positive samples and negative samples are obtained. The positive samples are ECG signal segments before ventricular fibrillation in sudden cardiac arrest patients, and the negative samples are ECG signal segments with normal sinus rhythm. A corresponding frequency band coupling map is generated based on each positive sample and each negative sample to form a training dataset. The spatiotemporal graph neural ordinary differential equation prediction model is trained based on the training dataset. The positive and negative samples have the same length.

[0038] For example, a flowchart illustrating the process of constructing a training dataset and generating a frequency band coupling map is shown below. Figure 2 As shown, this scheme collects positive sample window ECG data from a 5-minute window 30 to 35 minutes before the onset of ventricular fibrillation in sudden cardiac arrest patients. The positive sample window ECG data is divided into 5 positive sample sub-windows according to a 1-minute segment. Within each positive sample sub-window, a non-overlapping and continuous 5-second ECG signal segment is randomly extracted as a positive sample. That is, each positive sample window ECG data generates 5 positive samples.

[0039] For example, ECG data is collected from users with normal sinus rhythm. Any 5-minute window after 60 minutes of the start of the collection is recorded as the negative sample window ECG data. Similarly, the negative sample window ECG data is divided into 5 negative sample sub-windows in segments of 1 minute each. Within each negative sample sub-window, a non-overlapping and continuous 5-second ECG signal segment is randomly extracted as a negative sample.

[0040] Specifically, the technical means for generating corresponding frequency band coupling diagrams from positive and negative samples have been explained in detail above and will not be repeated here.

[0041] In the current embodiment, the node features of each node in the frequency band coupling graph are mapped to a preset low-dimensional potential space to obtain the low-dimensional node features of each node, and the low-dimensional node features are integrated to obtain the initial node state matrix.

[0042] Specifically, since the original features of each node in the frequency band coupling graph have high dimensionality, the spatiotemporal graph neural evolution network maps the features of each node to a pre-defined low-dimensional latent space through learnable linear projection, as expressed by the formula:

[0043] in, For the first The low-dimensional node features after mapping each node to a low-dimensional latent space For activation function, Let be the projection weight matrix. , This is the projection bias vector. , Let be the dimension of the low-dimensional latent space, and .

[0044] In addition, a Dropout layer is added after the mapping is completed, and some feature dimensions are zeroed out at random proportions to prevent overfitting.

[0045] In the current embodiment, this scheme treats the evolution of the initial node state matrix into the final node state matrix as an initial value problem of graph parameterization, which can be expressed as:

[0046] in, This is the node state matrix at virtual integration time t. The initial node state matrix, For ordinary differential dynamic functions, The starting virtual integration time, This is the adjacency matrix of the frequency band coupling graph, used to represent the adjacency relationships between different nodes.

[0047] In the current embodiment, the edge connection relationship between different nodes in the frequency band coupling graph is taken as the adjacency relationship, and the formula of the ordinary differential dynamic function is expressed as:

[0048] in, For ordinary differential dynamic functions, Virtual Integral Time The node state matrix at that location, This is the adjacency matrix of the frequency band coupling graph, used to represent the adjacency relationships between different nodes. For element-wise linear rectified activation function, To add a self-loop adjacency matrix, Is with The corresponding degree matrix, This is a learnable weight matrix.

[0049] Specifically, in this plan , Let N be the identity matrix of order N, where N is the total number of nodes in the frequency band coupling graph. Add self-loops to the adjacency matrix so that each node can retain its own information during message passing.

[0050] Specifically, diagonal elements The off-diagonal elements are 0. The degree difference of the nodes is normalized by constructing the degree matrix of the adjacency matrix to avoid the gradient instability during model training due to the large degree difference.

[0051] Specifically, by constructing ordinary differential dynamics functions to simulate the continuous evolution of node states in the virtual time dimension, compared with the discrete message passing method of stacking multiple layers in traditional graph neural networks, the continuous evolution modeling method can capture the interactive changes of node features more smoothly and reduce the risk of oversmoothing caused by discrete stacking.

[0052] In the current embodiment, the DOPRI5 solver with an adaptive step size is used to solve the ordinary differential dynamic function, as expressed in the formula:

[0053] in, The final state matrix of the nodes. The initial node state matrix, Indicates from virtual integral time arrive definite integral, For differential elements, A fifth-order adaptive step size solver, It is an ordinary differential dynamic function.

[0054] Specifically, These are the start and end times of the virtual prediction integration, respectively. The time corresponds to the initial node state matrix, The state matrix corresponding to the final state node.

[0055] In other words, by using an adaptive step size to solve the ordinary differential dynamics function, the continuous evolution of the node state in the virtual time dimension can be simulated. This can accurately capture the final state matrix of the node state with inter-band interaction characteristics. Compared with the fixed step size solution method, the adaptive step size can reduce unnecessary computational overhead while ensuring solution accuracy, and improve the efficiency of model training and inference.

[0056] In the current embodiment, the formula for summing and pooling the state matrix of the final node is expressed as follows:

[0057] in, For graph-level embedding vectors, The total number of nodes. For node indexing, This is the vector representation of the nth node in the final state matrix.

[0058] Specifically, a schematic diagram of obtaining graph-level embedding vectors through a spatiotemporal graph neural evolution network is shown below. Figure 3 As shown, summation pooling can better preserve graph scale information for graph structures, making the final prediction results more fully reflect the overall rhythm coupling mode.

[0059] In the current embodiment, the prediction network includes a shared feature extractor and a random uncertainty unit. The shared feature extractor extracts features from the graph-level embedding vector to obtain shared features. The random uncertainty unit includes a mean output head and a log-variance head. The mean output head outputs a classification logic value based on the shared features. Based on the classification logic value, the prediction probability distribution of the sudden death risk prediction result on all prediction categories is obtained, and the category corresponding to the maximum value in the prediction probability distribution is taken as the prediction category for a single forward propagation. The log-variance head outputs the log-variance based on the shared features.

[0060] Specifically, the classification logic values ​​are unnormalized real number vectors, with each component corresponding to a predicted class. The classification logic values ​​are mapped to a predicted probability distribution using a normalized exponential function (Softmax), expressed as follows:

[0061] in, For the first The predicted probabilities of each category, For the first logical value in the classification One portion, The total number of categories is represented by the normalization exponential function, which makes all components positive and sums to 1. This transforms the relative magnitudes of the classification logistic values ​​into directly comparable probability values, and the category with the highest probability is used as the predicted category for this forward propagation.

[0062] It should be noted that in the implementation that only sets the random uncertainty unit, the category corresponding to the maximum value in the above-mentioned prediction probability distribution is directly used as the sudden death prediction result; in the implementation that further sets the cognitive uncertainty unit, the above-mentioned prediction probability distribution is obtained from a single forward propagation, and the final sudden death prediction result is determined by the average prediction distribution of multiple forward propagations.

[0063] Specifically, the formula for obtaining shared features through a shared feature extractor is expressed as follows:

[0064] in, For shared features, For activation function, This is the weight matrix. For graph-level embedding vectors, This is the bias vector.

[0065] Specifically, the formula for the mean output head is expressed as follows:

[0066] in, For classification logical values, This is the weight matrix. For bias vectors, For shared features.

[0067] The formula for outputting the logarithmic variance head is expressed as follows:

[0068] in, For logarithmic variance, For variance, The weight matrix is ​​the log-variance head. To bias the logarithmic variance head, this scheme uses logarithmic variance parameterization instead of directly outputting the variance, in order to ensure the positive definiteness and numerical stability of the variance.

[0069] Specifically, the logarithmic variance represents the random uncertainty of the prediction result of sudden death risk. The higher the logarithmic variance, the stronger the inherent noise of the data included in this prediction, and the lower the confidence of the model itself in the given prediction result; conversely, the lower the logarithmic variance, the higher the certainty of the model in the prediction result.

[0070] Furthermore, during training, the heteroscedasticity negative log-likelihood loss is constructed by simultaneously calculating the classification logistic value and log-variance. This is combined with reparameterized sampling, and training is performed with the optimization objective of minimizing the heteroscedasticity negative log-likelihood loss. The formula for the heteroscedasticity negative log-likelihood loss is expressed as:

[0071] in, For heteroscedasticity negative log-likelihood loss, To reparameterize the number of samples, To obtain from a C-dimensional standard normal distribution (mean zero vector 0, covariance of C-order identity matrix) The first sampled in ) A noise vector, CE represents element-wise product, and cross-entropy loss. For the corresponding real tags, Let be the variance component corresponding to the c-th category, where C is the total number of categories.

[0072] It is worth noting that the prediction categories in this scheme only include two categories: positive and negative. A positive result indicates that there is a risk of sudden death, while a negative result indicates that there is no risk of sudden death, so C=2.

[0073] Specifically, the reparameterization technique decouples the sampling process from the computation graph, allowing gradients to flow simultaneously through the graph. and This allows the model to increase the variance value on inherently fuzzy inputs, ensuring that the variance estimate is meaningful and does not collapse to zero.

[0074] Furthermore, the prediction network includes a cognitive uncertainty unit. The cognitive uncertainty unit takes shared features as input, performs multiple forward propagations through a Dropout layer to obtain the prediction probability distribution for each forward propagation, and averages all prediction probability distributions to obtain the average prediction distribution. The category corresponding to the largest component in the average probability distribution is taken as the final sudden death prediction result. The prediction entropy value is calculated based on the dispersion of the average prediction distribution. The final sudden death prediction result, the prediction entropy value, and the logarithmic variance are taken as the output of the sudden death prediction result.

[0075] Specifically, the prediction entropy value characterizes the inaccuracy of the final sudden death prediction result. In other words, the higher the prediction entropy value, the more inconsistent the model results are in multiple predictions, and the higher the uncertainty of the prediction result. When the prediction entropy value exceeds the preset threshold, the user can be prompted to re-collect the ECG signal for secondary detection to reduce the probability of misdiagnosis or missed diagnosis caused by error in a single signal acquisition.

[0076] Specifically, this scheme performs 20 forward propagations on the shared features and obtains the Softmax probability vector of each forward propagation as the predicted probability distribution. The formula for averaging all predicted probability distributions is expressed as:

[0077] in, For the average prediction distribution, The total number of forward propagations. For the number of forward propagations, Let be the predicted probability distribution for the t-th forward propagation.

[0078] The formula for obtaining the final sudden death prediction result based on the average prediction distribution is expressed as:

[0079] in, For the final prediction of sudden death, For the average prediction distribution, This indicates that the category index of the largest component in the average prediction distribution is returned.

[0080] Specifically, the formula for calculating the predicted entropy value is expressed as follows:

[0081] in, For the average prediction distribution The predicted entropy value, The total number of categories, For category indexing, The th in the average prediction distribution The probability components of each category.

[0082] Specifically, a diagram illustrating the acquisition of sudden death prediction results through a prediction network is shown below. Figure 4 As shown, this scheme outputs the final sudden death prediction result, prediction entropy value, and logarithmic variance as the sudden death prediction result. It can not only directly output the classification result of whether there is a risk of sudden death, but also quantify the uncertainty of this prediction through two dimensions: prediction entropy value reflects the uncertainty of the model's own cognitive level, which comes from the uncertainty of the model weights; logarithmic variance reflects the inherent random uncertainty of the input data itself, which comes from unavoidable interference such as environmental noise and electrode contact noise during the ECG signal acquisition process. Together, they provide clinicians with additional decision-making reference information to help them judge the reliability of this prediction result, thereby further improving the clinical applicability and reliability of sudden death risk prediction and reducing the probability of misdiagnosis and missed diagnosis.

[0083] Example 2 Based on the same concept, referencing Figure 5 This application also proposes a sudden death prediction device based on graph god ordinary differential equations and uncertainty quantification, comprising: The data acquisition module is used to acquire ECG signal segments from users in real time and perform wavelet transform on the ECG signal segments to obtain a two-dimensional time-frequency energy matrix. The graph construction module is used to continuously divide the time-frequency energy matrix into multiple frequency bands according to the frequency dimension, and construct a frequency band coupling graph based on the multiple frequency bands. The frequency band coupling graph uses the frequency bands as nodes and constructs edges based on the cosine similarity between different nodes. The prediction module is used to input the frequency band coupling graph into a pre-trained spatiotemporal graph neural ordinary differential equation prediction model. The spatiotemporal graph neural ordinary differential equation prediction model includes a spatiotemporal graph neural evolution network and a prediction network. In the spatiotemporal graph neural evolution network, the frequency band coupling graph is mapped to an initial node state matrix. Each row of the initial node state matrix corresponds to the feature of each node in the frequency band coupling graph. An ordinary differential dynamic function is constructed based on the adjacency relationship of the frequency band coupling graph and the initial node state matrix. The final state node state matrix is ​​obtained by solving the ordinary differential dynamic function. Each row of the final state node state matrix is ​​summed and pooled to obtain a graph-level embedding vector. The prediction network obtains the sudden death prediction result based on the graph-level embedding vector.

[0084] Example 3 This embodiment also provides an electronic device, see reference. Figure 6 It includes a memory 402 and a processor 401, the memory 402 storing a computer program and the processor 401 being configured to run the computer program to perform the steps in any of the above method embodiments.

[0085] Specifically, the processor 401 may include a central processing unit (CPU), an application specific integrated circuit (ASIC), or one or more integrated circuits that can be configured to implement the embodiments of this application.

[0086] The memory 402 may include a mass storage device for data or instructions. For example, and not limitingly, the memory 402 may include a hard disk drive (HDD), a floppy disk drive, a solid-state drive (SSD), flash memory, an optical disk drive, a magneto-optical disk drive, magnetic tape, or a Universal Serial Bus (USB) drive, or a combination of two or more of these. Where appropriate, the memory 402 may include removable or non-removable (or fixed) media. Where appropriate, the memory 402 may be internal or external to a data processing device. In a particular embodiment, the memory 402 is non-volatile memory. In a particular embodiment, the memory 402 includes read-only memory (ROM) and random access memory (RAM). Where appropriate, the ROM may be a mask-programmed ROM, a programmable read-only memory (PROM), an erasable read-only memory (EPROM), an electrically erasable read-only memory (EEPROM), an electrically alterable read-only memory (EAROM), or flash memory, or a combination of two or more of these. Where appropriate, the RAM can be Static Random-Access Memory (SRAM) or Dynamic Random-Access Memory (DRAM). DRAM can be Fast Page Mode Dynamic Random Access Memory (FPMDRAM), Extended Data Out Dynamic Random Access Memory (EDODRAM), Synchronous Dynamic Random-Access Memory (SDRAM), etc.

[0087] The memory 402 can be used to store or cache various data files that need to be processed and / or communicated, as well as possible computer program instructions executed by the processor 401.

[0088] The processor 401 reads and executes the computer program instructions stored in the memory 402 to implement the sudden death prediction method based on graph-sense regular differential equations and uncertainty quantification in the above embodiment.

[0089] Optionally, the electronic device may further include a transmission device 403 and an input / output device 404, wherein the transmission device 403 is connected to the processor 401 and the input / output device 404 is connected to the processor 401.

[0090] The transmission device 403 can be used to receive or send data via a network. Specific examples of the network described above may include wired or wireless networks provided by the communication provider of the electronic device. In one example, the transmission device includes a Network Interface Controller (NIC), which can connect to other network devices via a base station to communicate with the Internet. In another example, the transmission device 403 may be a Radio Frequency (RF) module used for wireless communication with the Internet.

[0091] Input / output device 404 is used to input or output information. In this embodiment, the input information may be an ECG signal segment, etc., and the output information may be a sudden death prediction result, etc.

[0092] Optionally, in this embodiment, the processor 401 can be configured to perform the following steps via a computer program: The system acquires ECG signal segments from users in real time and performs wavelet transform on the ECG signal segments to obtain a two-dimensional time-frequency energy matrix. The time-frequency energy matrix is ​​continuously divided into multiple frequency bands along the frequency dimension, and a frequency band coupling graph is constructed based on the multiple frequency bands. The frequency band coupling graph uses the frequency bands as nodes and constructs edges based on the cosine similarity between different nodes. The frequency band coupling graph is input into a pre-trained spatiotemporal graph neural ordinary differential equation prediction model, which includes a spatiotemporal graph neural evolution network and a prediction network. In the spatiotemporal graph neural evolution network, the frequency band coupling graph is mapped to an initial node state matrix. Each row of the initial node state matrix corresponds to the feature of each node in the frequency band coupling graph. An ordinary differential dynamic function is constructed based on the adjacency relationship of the frequency band coupling graph and the initial node state matrix. The final state node state matrix is ​​obtained by solving the ordinary differential dynamic function. Each row of the final state node state matrix is ​​summed and pooled to obtain a graph-level embedding vector. The prediction network obtains the sudden death prediction result based on the graph-level embedding vector.

[0093] It should be noted that the specific examples in this embodiment can refer to the examples described in the above embodiments and optional implementations, and will not be repeated here.

[0094] Generally, various embodiments can be implemented in hardware or dedicated circuitry, software, logic, or any combination thereof. Some aspects of the invention can be implemented in hardware, while others can be implemented by firmware or software executed by a controller, microprocessor, or other computing device, but the invention is not limited thereto. Although various aspects of the invention may be shown and described as block diagrams, flowcharts, or using some other graphical representation, it should be understood that, by way of non-limiting example, these blocks, apparatuses, systems, techniques, or methods described herein can be implemented in hardware, software, firmware, dedicated circuitry or logic, general-purpose hardware or controllers or other computing devices, or some combination thereof.

[0095] Embodiments of the present invention can be implemented by computer software, which may be executable by a data processor of a mobile device, such as a processor entity, or by hardware, or by a combination of software and hardware. Computer software or programs (also referred to as program products) including software routines, applets, and / or macros can be stored in any device-readable data storage medium, and they include program instructions for performing specific tasks. The computer program product may include one or more computer-executable components configured to perform the embodiments when the program is run. The one or more computer-executable components may be at least one piece of software code or a portion thereof. Additionally, it should be noted in this respect that, as Figure 6 Any box in the logical flow can represent a program step, or interconnected logic circuits, boxes and functions, or a combination of program steps and logic circuits, boxes and functions. Software can be stored on physical media such as memory chips or blocks of storage implemented within a processor, magnetic media such as hard disks or floppy disks, and optical media such as DVDs and their data variants, CDs, etc. The physical medium is a non-transient medium.

[0096] Those skilled in the art should understand that the technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments have been described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0097] The above embodiments are merely illustrative of several implementation methods of this application, and their descriptions are relatively specific and detailed, but they should not be construed as limiting the scope of this application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.

Claims

1. A sudden death prediction method based on graphical ordinary differential equations and uncertainty quantification, characterized in that, Includes the following steps: The system acquires ECG signal segments from users in real time and performs wavelet transform on the ECG signal segments to obtain a two-dimensional time-frequency energy matrix. The time-frequency energy matrix is ​​continuously divided into multiple frequency bands along the frequency dimension, and a frequency band coupling graph is constructed based on the multiple frequency bands. The frequency band coupling graph uses the frequency bands as nodes and constructs edges based on the cosine similarity between different nodes. The frequency band coupling graph is input into a pre-trained spatiotemporal graph neural network (SPLM) prediction model, which includes a spatiotemporal graph neural evolution network (SPLM) and a prediction network. In the SPLM, the frequency band coupling graph is mapped to an initial node state matrix. Each row of the initial node state matrix corresponds to a feature of each node in the frequency band coupling graph. An ordinary differential dynamic function (ODM) is constructed based on the adjacency relationship of the frequency band coupling graph and the initial node state matrix. The final node state matrix is ​​obtained by solving the ODM. Each row of the final node state matrix is ​​summed and pooled to obtain a graph-level embedding vector. The prediction network obtains a sudden death prediction result based on the graph-level embedding vector. The prediction network includes a shared feature extractor and a random uncertainty unit. The shared feature extractor extracts features from the graph-level embedding vector to obtain shared features. The random uncertainty unit includes a mean output head and a logarithmic output head. The network consists of several components: a mean output head that outputs a classification logic value based on shared features, a dropout layer that performs multiple forward propagations to obtain the prediction probability distribution of the sudden death risk prediction result across all prediction categories, and a log-variance output head that outputs a log-variance based on shared features, which represents the random uncertainty of the sudden death risk prediction result. The prediction network includes a cognitive uncertainty unit that takes shared features as input, performs multiple forward propagations through a Dropout layer to obtain the prediction probability distribution for each forward propagation, and averages all prediction probability distributions to obtain the average prediction distribution. The class corresponding to the largest component in the average probability distribution is taken as the final sudden death prediction result. The prediction entropy value is calculated based on the dispersion of the average prediction distribution. The final sudden death prediction result, the prediction entropy value, and the log-variance are output as the sudden death prediction result.

2. The sudden death prediction method based on graphical ordinary differential equations and uncertainty quantification as described in claim 1, characterized in that, The ECG signal segment is sampled to the target sampling frequency, and the ECG signal segment at the target sampling frequency is denoised to obtain a denoised signal. The denoised signal is then subjected to continuous wavelet transform using Morlet wavelet as the mother wavelet to obtain a two-dimensional time-frequency energy matrix.

3. The sudden death prediction method based on graphical constant differential equations and uncertainty quantification as described in claim 1, characterized in that, In the step of constructing the frequency band coupling graph, a cosine similarity threshold is set, the cosine similarity between different nodes is calculated, and an edge is constructed between two different nodes whose cosine similarity is greater than the cosine similarity threshold.

4. The sudden death prediction method based on graphical constant differential equations and uncertainty quantification according to claim 1, characterized in that, Multiple positive and negative samples are obtained. The positive samples are ECG signal segments before ventricular fibrillation in sudden cardiac arrest patients, and the negative samples are ECG signal segments with normal sinus rhythm. A training dataset is formed by generating corresponding frequency band coupling maps based on each positive and negative sample. The spatiotemporal graph neural ordinary differential equation prediction model is trained based on the training dataset. The positive and negative samples have the same length.

5. The sudden death prediction method based on graphical constant differential equations and uncertainty quantification according to claim 1, characterized in that, Taking the edge connections between different nodes in the frequency band coupling graph as adjacency relationships, the formula for the ordinary differential dynamic function is expressed as: in, Virtual Integral Time The node state matrix at that location, This is the adjacency matrix of the frequency band coupling graph, used to represent the adjacency relationships between different nodes. For element-wise linear rectified activation function, To add a self-loop adjacency matrix, Is with The corresponding degree matrix, This is a learnable weight matrix.

6. A sudden death prediction device based on graphical ordinary differential equations and uncertainty quantification, characterized in that, include: The data acquisition module is used to acquire ECG signal segments from users in real time and perform wavelet transform on the ECG signal segments to obtain a two-dimensional time-frequency energy matrix. The graph construction module is used to continuously divide the time-frequency energy matrix into multiple frequency bands according to the frequency dimension, and construct a frequency band coupling graph based on the multiple frequency bands. The frequency band coupling graph uses the frequency bands as nodes and constructs edges based on the cosine similarity between different nodes. The prediction module is used to input the frequency band coupling graph into a pre-trained spatiotemporal graph neural ordinary differential equation prediction model. The spatiotemporal graph neural ordinary differential equation prediction model includes a spatiotemporal graph neural evolution network and a prediction network. In the spatiotemporal graph neural evolution network, the frequency band coupling graph is mapped to an initial node state matrix. Each row of the initial node state matrix corresponds to the feature of each node in the frequency band coupling graph. An ordinary differential dynamic function is constructed based on the adjacency relationship of the frequency band coupling graph and the initial node state matrix. The final state node state matrix is ​​obtained by solving the ordinary differential dynamic function. Each row of the final state node state matrix is ​​summed and pooled to obtain a graph-level embedding vector. The prediction network obtains the sudden death prediction result based on the graph-level embedding vector. The prediction network includes a shared feature extractor and a random uncertainty unit. The shared feature extractor extracts features from the graph-level embedding vector to obtain shared features. The random uncertainty unit includes a mean output head and... The system includes a log-variance head, a mean output head that outputs classification logic values ​​based on shared features, and a prediction probability distribution of the sudden death risk prediction result across all prediction categories based on the classification logic values. The category corresponding to the maximum value in the prediction probability distribution is used as the prediction category for a single forward propagation. The log-variance head outputs log-variance based on shared features, and the log-variance represents the random uncertainty of the sudden death risk prediction result. The prediction network includes a cognitive uncertainty unit that takes shared features as input, performs multiple forward propagations through a Dropout layer, obtains the prediction probability distribution for each forward propagation, and averages all prediction probability distributions to obtain an average prediction distribution. The category corresponding to the maximum component in the average probability distribution is used as the final sudden death prediction result. The prediction entropy value is calculated based on the dispersion of the average prediction distribution. The final sudden death prediction result, the prediction entropy value, and the log-variance are used as the output of the sudden death prediction result.

7. An electronic device comprising a memory and a processor, characterized in that, The memory stores a computer program, and the processor is configured to run the computer program to execute the sudden death prediction method based on TuShen frequent differential equations and uncertainty quantification as described in any one of claims 1-5.

8. A readable storage medium, characterized in that, The readable storage medium stores a computer program, which, when executed by a processor, implements a sudden death prediction method based on graphical ordinary differential equations and uncertainty quantization as described in any one of claims 1-5.

Citation Information

Patent Citations

  • Method for realizing sudden death risk prediction on mini dynamic electrocardiogram monitoring equipment

    CN106073765A

  • Irregular time sequence prediction method and system based on causal diagram mental differential equation

    CN120822180A