Method and system for constructing early death risk prediction model of patient in intensive care unit based on electrocardiogram
Through the ECG-based prediction model of early death risk in intensive care unit patients, the lead grouping timing network framework is used to extract and fuse ECG characteristics, and the problem of traditional models' dependence on clinical data is solved, efficient and accurate mortality risk assessment is achieved, simplifying the process and improving the stability and efficiency of the assessment.
Patent Information
- Application Number
- CN202510513503.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-23
- Publication Date
- 2025-08-08
AI Technical Summary
The existing intensive care unit patient death risk assessment model is highly dependent on clinical data and laboratory test results, with insufficient robustness and limited generalization capabilities, and the timeliness and accuracy of the evaluation results need to be improved.
The early death risk prediction model of patients in intensive care unit based on electrocardiograms is obtained by acquiring multiple 12-lead electrocardiograms and their time difference data, and using a clinically meaning-based lead grouping patient timing network framework, training the model to learn the relationship between different outcomes and electrocardiograms of patients, including input layer, convolutional layer, multi-scale attention aggregation module, time confidence module and output layer, to achieve end-to-end death risk prediction.
Improve prediction accuracy and stability, simplify the process, enable rapid and accurate assessment of patient status, assist doctors in optimizing treatment plans, and reduce hospital stays and resource waste.
Smart Images

Figure CN120452769A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of medical data processing, and in particular to a method and system for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients. Background Art
[0002] Clinical decision-making and mortality risk assessment are crucial in the intensive care unit (ICU) setting. Traditional mortality risk assessment relies primarily on scoring models, such as the Acute Physiology and Chronic Health Evaluation (APACHE), the Simplified Acute Physiology Score (SAPS), and the rapid Sepsis-Related Organ Failure Assessment (qSOFA), which comprehensively consider multiple clinical indicators to predict patient outcomes. However, these score-based mortality risk assessment methods have several limitations.
[0003] First, these scoring models rely on comprehensive and detailed clinical data, including laboratory test results, which makes them extremely demanding in terms of data integrity. Any missing variables may result in inaccurate predictions. Furthermore, some laboratory tests require time to produce results, which may delay clinical decision-making. Second, the coefficients of the scoring models are set based on the characteristics of a specific population, so their generalization ability is limited, making it difficult to adapt to the specific circumstances of different regions or institutions. Furthermore, the privacy protection of clinical data complicates the deployment and application of such models.
[0004] In recent years, with the development of machine learning and deep learning technologies, a growing number of studies have begun exploring the use of these advanced algorithms to improve mortality risk assessment in ICU patients. For example, machine learning methods such as support vector machines and random forests have been applied to analyze electronic health records to improve predictive accuracy. However, these models remain highly dependent on clinical records and laboratory test results and have not completely broken away from the limitations of traditional scoring models.
[0005] Therefore, a new early mortality risk prediction model for ICU patients is urgently needed to reduce the model's dependence on clinical data and laboratory test results, and to assist in achieving a more efficient, accurate, and low-cost assessment of ICU patient mortality risk. Summary of the Invention
[0006] The present invention provides a method and system for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients, which is used to address the defects of existing mortality risk assessment models, such as their high reliance on clinical data and laboratory test results, insufficient model robustness, limited generalization ability, and the need to improve the timeliness and accuracy of assessment results.
[0007] The present invention provides a method for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients, comprising:
[0008] Obtain multiple 12-lead electrocardiograms (ECGs) of a patient population in an intensive care unit (ICU) within a preset time range, as well as time difference data between each 12-lead ECG and the latest 12-lead ECG among the multiple 12-lead ECGs, wherein the 12-lead ECGs and time difference data corresponding to each ICU patient in the ICU patient population are both annotated with a patient prognosis label, and the patient prognosis label includes an outcome label indicating whether the patient died and the time between the time of death and the latest 12-lead ECG;
[0009] Based on multiple 12-lead electrocardiograms of intensive care unit patients within a preset time range and the time difference data between each 12-lead electrocardiogram and the most recent 12-lead electrocardiogram among the multiple 12-lead electrocardiograms, a model was trained to learn the relationship between different outcomes of intensive care unit patients and their 12-lead electrocardiograms at different time points through a patient temporal network framework with clinical significance. This resulted in an electrocardiogram-based prediction model for the risk of early death in intensive care unit patients.
[0010] According to a method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients provided by the present invention, the definition of early death risk can be the risk of death within 7 days or 28 days after the patient enters the intensive care unit. Multiple 12-lead electrocardiograms of a group of patients in the intensive care unit within a preset time range, and time difference data between each of the multiple 12-lead electrocardiograms and the most recent 12-lead electrocardiogram therein, can be multiple 12-lead electrocardiograms of the patient within 7 days or 28 days after the patient enters the intensive care unit, and time difference data between each of the multiple 12-lead electrocardiograms and the most recent 12-lead electrocardiogram therein.
[0011] According to a method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients provided by the present invention, a patient timing network framework for lead grouping based on clinical significance includes an input layer, a convolutional layer, a multi-scale attention aggregation module, a temporal confidence module, and an output layer.
[0012] According to the present invention, a method for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients is provided. The method includes: based on multiple 12-lead electrocardiograms of a group of intensive care unit patients within a preset time range and time difference data between each 12-lead electrocardiogram and the most recent 12-lead electrocardiogram among the multiple 12-lead electrocardiograms; a patient temporal network framework based on clinically significant lead grouping is used to train a model to learn the relationship between different outcomes of intensive care unit patients and their 12-lead electrocardiograms at different time points; and a method for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients is provided. The method includes:
[0013] Input multiple 12-lead electrocardiograms of a patient group in an intensive care unit within a preset time range and the time difference data of each 12-lead electrocardiogram from the latest 12-lead electrocardiogram among the multiple 12-lead electrocardiograms into the input layer of a patient timing network framework for lead grouping based on clinical significance;
[0014] For each 12-lead ECG, the 12-lead ECG is divided into 6 groups of ECG data according to the preset clinical significance. The ECG features of the 6 groups of ECG data are extracted through the convolutional layer of the patient temporal network framework based on the clinical significance of the lead grouping.
[0015] For each 12-lead ECG, the ECG features of the six groups of ECG data are fused through the multi-scale attention aggregation module of the clinically significant lead grouping patient temporal network framework to obtain the fused ECG features;
[0016] For each 12-lead ECG, the time difference data from the latest 12-lead ECG among multiple 12-lead ECGs is used to extract the time difference feature through the time confidence module of the patient timing network framework based on clinical lead grouping. The time difference feature is then fused with the corresponding fused ECG feature to obtain the ECG confidence.
[0017] According to the ECG confidence of multiple 12-lead ECGs of each ICU patient within a preset time range, the early mortality risk prediction results of each ICU patient were obtained through the output layer of the patient timing network framework with clinically significant lead grouping.
[0018] According to a method for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients provided by the present invention, the six groups include any one of the following or any combination thereof: high lateral wall group, inferior wall group, septal group, anterior wall group, lateral wall group, and auxiliary group, and the preset clinical significance includes any one of the following or any combination thereof:
[0019] High lateral wall group: leads I and avL, mainly reflecting the information of the high lateral wall of the left ventricle;
[0020] Inferior wall group: leads II, III, and avF, which mainly reflect the information of the inferior wall of the heart;
[0021] Interval group: V1 and V2 leads, which mainly reflect the information of the interval between the left ventricle and the right ventricle;
[0022] Anterior wall group: leads V3 and V4, which mainly reflect the information of the left ventricular anterior wall;
[0023] Lateral wall group: leads V5 and V6, which mainly reflect the information of the left ventricular lateral wall;
[0024] Auxiliary group: avR lead, as additional auxiliary information.
[0025] According to a method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients provided by the present invention, the convolutional layer of the patient timing network framework based on clinically significant lead grouping includes multiple encoders for extracting electrocardiogram features of electrocardiogram data of six groups respectively.
[0026] According to a method for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients provided by the present invention, a multi-scale attention aggregation module based on a clinically significant lead grouping patient temporal network framework includes multiple one-dimensional convolution kernels of different sizes and a self-attention mechanism module. For each 12-lead electrocardiogram, the electrocardiogram features of the six groups of electrocardiogram data are fused through the multi-scale attention aggregation module of the clinically significant lead grouping patient temporal network framework to obtain a fused electrocardiogram feature, including:
[0027] For each 12-lead ECG, the multi-scale attention aggregation module uses multiple one-dimensional convolution kernels of different sizes to extract features at different time scales from the ECG features of the six groups of ECG data, obtaining multi-scale features at multiple time points.
[0028] According to the multi-scale features of multiple time points, the importance weight of the multi-scale features at each time point is obtained through the self-attention mechanism module of the multi-scale attention aggregation module. Then, according to the multi-scale features of each time point and their importance weight, the multi-scale features of multiple time points are fused to obtain the fused ECG features of each 12-lead ECG.
[0029] According to a method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients provided by the present invention, a time confidence module based on a clinically significant lead grouping patient timing network framework includes a linear layer, a convolutional layer, and a gated fusion submodule. For each 12-lead electrocardiogram, according to the time difference data from the time difference between the 12-lead electrocardiogram and the latest 12-lead electrocardiogram among multiple 12-lead electrocardiograms, the time difference feature is extracted through the time confidence module based on the clinically significant lead grouping patient timing network framework, and the time difference feature is fused with the corresponding fused electrocardiogram feature to obtain the electrocardiogram confidence, including:
[0030] For each 12-lead ECG, the time difference data from the latest 12-lead ECG among multiple 12-lead ECGs is used to extract the time difference feature through the linear layer and convolution layer of the time confidence module. The shape of the extracted time difference feature is then deformed to the same shape as the ECG feature.
[0031] Through the gated fusion submodule of the time confidence module, the deformed time difference features are fused with the corresponding fused ECG features to obtain the ECG confidence.
[0032] According to a method for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients provided by the present invention, the output layer of a clinically significant lead grouping patient time series network framework includes a pooling layer and a fully connected layer. The method obtains an early mortality risk prediction result for each intensive care unit patient based on the electrocardiogram confidence of multiple 12-lead electrocardiograms of each intensive care unit patient within a preset time range through the output layer of the clinically significant lead grouping patient time series network framework, including:
[0033] The fused ECG features and time confidence are averaged and pooled through the pooling layer of the output layer;
[0034] The pooled fused ECG features and temporal confidence are mapped to the output space through the fully connected layer to obtain the early death risk prediction results of each ICU patient.
[0035] According to the present invention, a method for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients is provided. The method includes: based on multiple 12-lead electrocardiograms of a group of intensive care unit patients within a preset time range and time difference data between each 12-lead electrocardiogram and the most recent 12-lead electrocardiogram among the multiple 12-lead electrocardiograms; a patient temporal network framework based on clinically significant lead grouping is used to train a model to learn the relationship between different outcomes of intensive care unit patients and their 12-lead electrocardiograms at different time points; and a method for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients is provided. The method includes:
[0036] When training the model, stochastic gradient descent is used to minimize the loss function value.
[0037] The present invention also provides an auxiliary assessment system for the early death risk of patients in an intensive care unit, comprising:
[0038] The data receiving module is used to: receive from at least one terminal a plurality of 12-lead electrocardiograms of a patient in an intensive care unit to be tested within a preset time range and time difference data between each of the plurality of 12-lead electrocardiograms and the latest 12-lead electrocardiogram;
[0039] A prediction module, configured to obtain an ICU patient early death risk prediction result for the ICU patient to be tested based on a plurality of 12-lead electrocardiograms of the ICU patient to be tested within a preset time range and time difference data between each 12-lead electrocardiogram and the most recent 12-lead electrocardiogram among the plurality of 12-lead electrocardiograms, and an ICU patient early death risk prediction model based on an electrocardiogram obtained by any of the above-mentioned methods for constructing an ICU patient early death risk prediction model based on an electrocardiogram;
[0040] The data output module is used to output the early death risk prediction results of the intensive care unit patients to be tested to at least one terminal.
[0041] It should be noted that a terminal refers to an input and output device connected to a computer system. Depending on their functions, terminals can be divided into various types: smart terminals or intelligent terminals, dumb terminals, interactive terminals or online terminals. Terminals can specifically be various mobile communication devices, such as mobile phones, tablet computers, etc. The purpose of this article is to provide users with the function of inputting and outputting data.
[0042] The present invention also provides an electronic device comprising a processor and a memory storing a computer program, wherein when the processor executes the computer program, it implements any of the above-mentioned methods for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients.
[0043] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, it implements any of the above-mentioned methods for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients.
[0044] The present invention also provides a computer program product, which includes a computer program. The computer program can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer can execute any of the above-mentioned methods for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients.
[0045] The present invention provides a method and system for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients. The model first divides the ECG data in the 12-lead electrocardiogram into six different groups according to the clinical significance represented by each lead, and extracts ECG features through independent encoders. Then, a multi-scale attention aggregation module uses channel attention and spatial attention mechanisms to enhance feature expression and integrate information, generating a fused ECG feature representation that integrates multi-scale, multi-channel, and spatial information. This process can effectively improve the model's ability to understand complex patterns and its robustness to noise or irrelevant features. Considering ECG data at multiple time points of the same patient, a temporal confidence module is used to perform a weighted summation of the temporal confidence features and the fused ECG features. The gating submodule then adjusts the weights to ensure that the final output features contain both ECG spatiotemporal characteristics and reflect the influence of time differences, which can assist in achieving efficient and accurate early mortality risk assessment for intensive care unit patients. In addition, a lightweight fully connected network is used as a weight generator to extract effective information and assign a reasonable weight value to each sample to measure the validity and representativeness of each ECG record.
[0046] The present invention provides a method and system for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients, which can also bring the following beneficial effects:
[0047] (1) Improve prediction accuracy: By optimizing the feature extraction and fusion of multi-lead ECG signals, the model's ability to understand the spatial and temporal characteristics of the ECG is enhanced, thereby improving the prediction accuracy of the early death risk prediction model for patients in the intensive care unit.
[0048] (2) Enhanced robustness and stability: Adaptively and comprehensively evaluate the patient's ECG data at multiple time points to overcome the influence of single ECG measurement errors and improve the stability and reliability of the early death risk assessment of intensive care unit patients using the early death risk prediction model.
[0049] (3) Simplified process: End-to-end learning from raw ECG data to early mortality risk prediction for intensive care unit patients is achieved, eliminating traditional preprocessing or manual feature extraction steps and effectively simplifying the workflow.
[0050] (4) Improve efficiency: The early death risk prediction model for patients in the intensive care unit can quickly and accurately assess the patient's condition, assist doctors in optimizing treatment plans, reduce hospitalization time and waste of resources, and has important clinical application value and socioeconomic benefits. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] In order to more clearly illustrate the technical solutions in the present invention or the prior art, a brief introduction will be given below to the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0052] Figure 1 A schematic flow chart of a method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients provided by the present invention.
[0053] Figure 2 Shown is the model architecture of the electrocardiogram-based early mortality risk prediction model for intensive care unit patients.
[0054] Figure 3 Data from an electrocardiogram-based early mortality risk prediction model for intensive care unit patients were included in the screening and training process.
[0055] Figure 4 The ROC curve and PR curve of the electrocardiogram-based early death risk prediction model for intensive care unit patients on the test set are shown.
[0056] Figure 5 A schematic structural diagram of a system for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients provided by the present invention.
[0057] Figure 6 This is a schematic structural diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION
[0058] In order to make the purpose, technical solutions and advantages of the present invention clearer, the technical solutions of the present invention will be clearly and completely described below in conjunction with the drawings in the present invention. Obviously, the embodiments described are part of the embodiments of the present invention, not all of the embodiments, and they should not be understood as limitations on the present invention. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention. In the description of the present invention, it should be understood that the terms used are only for descriptive purposes and cannot be understood as indicating or implying relative importance.
[0059] Figure 1This is a flow chart of a method for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients provided by the present invention. The method for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients provided by the present invention can be executed by any applicable terminal-side device or network-side device, such as a device for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients.
[0060] See also Figure 1 The present invention provides a method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients, which may include:
[0061] S110. Obtain multiple 12-lead electrocardiograms of an intensive care unit patient group within a preset time range, and time difference data between each 12-lead electrocardiogram and the latest 12-lead electrocardiogram among the multiple 12-lead electrocardiograms, wherein the 12-lead electrocardiogram and the time difference data corresponding to each intensive care unit patient in the intensive care unit patient group are both marked with a patient prognosis label, and the patient prognosis label includes an outcome label of whether or not the patient died and the time between the time of death and the latest 12-lead electrocardiogram.
[0062] In one embodiment, the definition of early mortality risk may be the risk of mortality within 7 days or 28 days after a patient is admitted to an intensive care unit. The multiple 12-lead electrocardiograms of a patient population in the intensive care unit within a preset time range, and the time difference data between each of the multiple 12-lead electrocardiograms and the most recent 12-lead electrocardiogram therein, may be the multiple 12-lead electrocardiograms of a patient population in the intensive care unit within 7 days or 28 days after the patient is admitted to the intensive care unit, and the time difference data between each of the multiple 12-lead electrocardiograms and the most recent 12-lead electrocardiogram therein.
[0063] In one embodiment, the 12-lead electrocardiograms of the intensive care unit patient group can be derived from the MIMIC-IV database, which provides electrocardiogram records with a sampling rate of 500 Hz and a length of 6 seconds. Based on the recording time of the 12-lead electrocardiograms of the intensive care unit patient group, the time difference data between each 12-lead electrocardiogram in multiple 12-lead electrocardiograms and the most recent 12-lead electrocardiogram can be calculated.
[0064] In order to increase the generalization ability of the model, the original data of the model (including 12-lead ECG and time difference data) can be randomly cropped during the training process to perform data augmentation processing, with 3000 points cropped each time.
[0065] S120. Based on multiple 12-lead electrocardiograms of a group of intensive care unit patients within a preset time range and the time difference data between each 12-lead electrocardiogram and the latest 12-lead electrocardiogram among the multiple 12-lead electrocardiograms, a model is trained to learn the relationship between different outcomes of intensive care unit patients and their 12-lead electrocardiograms at different time points through a patient timing network framework based on clinical significance, and an electrocardiogram-based early death risk prediction model for intensive care unit patients is obtained.
[0066] See also Figure 2 In one embodiment, the clinically significant lead grouping patient temporal network framework includes an input layer, a convolutional layer, a multi-scale attention aggregation module, a temporal confidence module, and an output layer.
[0067] S120 may include:
[0068] S1201. Input multiple 12-lead electrocardiograms of a patient group in an intensive care unit within a preset time range and the time difference data between each 12-lead electrocardiogram and the latest 12-lead electrocardiogram among the multiple 12-lead electrocardiograms into the input layer of a lead grouping patient timing network framework based on clinical significance.
[0069] S1202. For each 12-lead ECG, the 12-lead ECG is divided into 6 groups of ECG data according to the preset clinical significance, and the ECG features of the 6 groups of ECG data are respectively extracted through the convolutional layer of the lead grouping patient timing network framework based on clinical significance.
[0070] In one embodiment, the convolutional layer of the patient timing network framework for lead grouping based on clinical significance includes multiple (e.g., 6) encoders to capture local and global features, which are used to extract ECG features of 6 groups of ECG data according to preset clinical significance.
[0071] In one embodiment, the six groups include any one of the following or any combination thereof: high lateral wall group, inferior wall group, septal group, anterior wall group, lateral wall group, and auxiliary group, and the preset clinical significance includes any one of the following or any combination thereof:
[0072] High lateral wall group: leads I and avL, mainly reflecting the information of the high lateral wall of the left ventricle;
[0073] Inferior wall group: leads II, III, and avF, which mainly reflect the information of the inferior wall of the heart;
[0074] Interval group: V1 and V2 leads, which mainly reflect the information of the interval between the left ventricle and the right ventricle;
[0075] Anterior wall group: leads V3 and V4, which mainly reflect the information of the left ventricular anterior wall;
[0076] Lateral wall group: leads V5 and V6, which mainly reflect the information of the left ventricular lateral wall;
[0077] Auxiliary group: avR lead, as additional auxiliary information.
[0078] S1203. For each 12-lead ECG, the ECG features of the ECG data of the six groups are fused through the multi-scale attention aggregation module of the clinically significant lead grouping patient temporal network framework to obtain fused ECG features.
[0079] In one embodiment, a multi-scale attention aggregation module based on a clinically significant lead grouping patient temporal network framework includes multiple one-dimensional convolution kernels of different sizes and a self-attention mechanism module. S1203 can extract features at different time scales from the ECG features of 6 groups of ECG data for each 12-lead ECG through multiple one-dimensional convolution kernels of different sizes of the multi-scale attention aggregation module to obtain multi-scale features of multiple time points; then, based on the multi-scale features of the multiple time points, the self-attention mechanism module of the multi-scale attention aggregation module is used to obtain the importance weight of the multi-scale features of each time point; and based on the multi-scale features of each time point and their importance weights, the multi-scale features of the multiple time points are fused to obtain the fused ECG features of each 12-lead ECG.
[0080] In order to solve the problem of information loss that may be caused by single-scale feature extraction, this embodiment introduces a multi-scale attention aggregation module. This module captures features at different time scales through multi-scale convolution kernels and highlights important feature points through the self-attention mechanism. The multi-scale attention aggregation module not only enhances the model's ability to understand complex patterns, but also effectively improves the model's prediction accuracy. Specifically, the multi-scale attention aggregation module first processes the input electrocardiogram data through multiple one-dimensional convolution kernels of different sizes to obtain a multi-scale feature representation; then, the importance weight of each feature point is calculated through the self-attention mechanism, and finally these weighted features are aggregated to form a comprehensive feature representation.
[0081] S1204. For each 12-lead ECG, according to the time difference data from the latest 12-lead ECG among multiple 12-lead ECGs, the time difference feature is extracted through the time confidence module of the patient timing network framework based on the clinical significance of lead grouping, and the time difference feature is fused with the corresponding fused ECG feature to obtain the ECG confidence.
[0082] In one embodiment, a time confidence module of a patient timing network framework based on clinically significant lead grouping includes a linear layer, a convolutional layer, and a gated fusion submodule. S1204 can extract the time difference feature of each 12-lead electrocardiogram based on the time difference data of the 12-lead electrocardiogram with the latest time among multiple 12-lead electrocardiograms through the linear layer and convolutional layer of the time confidence module, and deform the shape of the extracted time difference feature into the same shape as the electrocardiogram feature; through the gated fusion submodule of the time confidence module, the deformed time difference feature is fused with the corresponding fused electrocardiogram feature to obtain the electrocardiogram confidence.
[0083] Considering that ECG data at different time points may contribute differently to the prediction results, this embodiment introduces a time confidence module. This module calculates the relative importance of each ECG record based on the time difference information and generates a time confidence value. These values are then applied to subsequent feature weighting and fusion processes to enhance the model's understanding of time series data. Specifically, the time confidence module normalizes the timestamp of each ECG record, calculates its time difference relative to the most recent record, and then converts it into a time confidence value based on pre-defined rules or functions.
[0084] S1205. Based on the electrocardiogram confidence of multiple 12-lead electrocardiograms of each intensive care unit patient within a preset time range, the early death risk prediction result of each intensive care unit patient is obtained through the output layer of the patient timing network framework based on clinical significance lead grouping.
[0085] In one embodiment, the output layer of the patient timing network framework based on clinically significant lead grouping includes a pooling layer and a fully connected layer. S1205 can average pool the fused ECG features and time confidence through the pooling layer of the output layer to reduce the feature dimension while retaining important information; and map the pooled fused ECG features and time confidence to the output space through the fully connected layer to obtain the early death risk prediction results of each intensive care unit patient.
[0086] like Figure 3As shown, this embodiment uses multiple 12-lead ECGs of a patient population in the intensive care unit within a preset time range and the time difference data between each 12-lead ECG and the latest 12-lead ECG among the multiple 12-lead ECGs to perform model training. During the training process, random gradient descent is used to minimize the loss function value. In order to ensure the effectiveness of the model, a cross-validation strategy is adopted to divide the training set, validation set and test set, which are used for training, tuning hyperparameters and evaluating model performance respectively. An independent validation set is used to evaluate the performance of the model, and indicators such as accuracy, sensitivity, and specificity are calculated. In addition, the AUC-ROC curve is used to measure the model's ability to distinguish between samples of different categories to ensure that the model has good generalization ability and stability. After the model structure and parameters are finally determined, the reserved test set is used to further verify the actual application effect of the model, mainly testing the model's ability to predict death within 7 days and 28 days. This step is crucial to confirm the performance of the model on unseen data. As Figure 4 As shown, the ECG-based early mortality risk prediction model for ICU patients constructed in this example performs well in predicting ICU mortality risk, with a 7-day mortality prediction area under the curve (AUC) of 0.88, significantly improving early warning capabilities. The model can provide reliable prediction results in a short period of time, helping to support clinical decision-making.
[0087] The present invention provides a method and system for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients. The model first divides the ECG data in the 12-lead electrocardiogram into six different groups based on the clinical significance represented by each lead, and extracts ECG features through independent encoders. Then, a multi-scale attention aggregation module uses channel attention and spatial attention mechanisms to enhance feature expression and integrate information, generating a fused ECG feature representation that integrates multi-scale, multi-channel, and spatial information. This process can effectively improve the model's ability to understand complex patterns and its robustness to noise or irrelevant features. Considering ECG data from multiple time points of the same patient, a temporal confidence module is used to perform a weighted summation of the temporal confidence features and the fused ECG features. The gating submodule then adjusts the weights to ensure that the final output features both contain ECG spatiotemporal characteristics and reflect the influence of time differences. In addition, a lightweight fully connected network is used as a weight generator to extract effective information and assign a reasonable weight value to each sample to measure the validity and representativeness of each ECG record.
[0088] The present invention provides a method and system for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients, which can also bring the following beneficial effects:
[0089] (1) Improve prediction accuracy: By optimizing the feature extraction and fusion of multi-lead ECG signals, the model's ability to understand the spatial and temporal characteristics of the ECG is enhanced, thereby improving the prediction accuracy of the early death risk prediction model for patients in the intensive care unit.
[0090] (2) Enhanced robustness and stability: Adaptively and comprehensively evaluate the patient's ECG data at multiple time points to overcome the influence of single ECG measurement errors and improve the stability and reliability of the early death risk assessment of intensive care unit patients using the early death risk prediction model.
[0091] (3) Simplified process: End-to-end learning from raw ECG data to early mortality risk prediction for intensive care unit patients is achieved, eliminating traditional preprocessing or manual feature extraction steps and effectively simplifying the workflow.
[0092] (4) Improve efficiency: The early death risk prediction model for patients in the intensive care unit can quickly and accurately assess the patient's condition, assist doctors in optimizing treatment plans, reduce hospitalization time and waste of resources, and has important clinical application value and socioeconomic benefits.
[0093] The following describes the auxiliary assessment system for the early death risk of intensive care unit patients provided by the present invention. The auxiliary assessment system for the early death risk of intensive care unit patients described below and the method for constructing the electrocardiogram-based early death risk prediction model for intensive care unit patients described above can be referenced to each other.
[0094] See also Figure 5 The present invention provides an auxiliary assessment system for the early death risk of patients in an intensive care unit, which may include:
[0095] The data receiving module is used to: receive from at least one terminal a plurality of 12-lead electrocardiograms of a patient in an intensive care unit to be tested within a preset time range and time difference data between each of the plurality of 12-lead electrocardiograms and the latest 12-lead electrocardiogram;
[0096] A prediction module, configured to obtain an ICU patient early death risk prediction result for the ICU patient to be tested based on a plurality of 12-lead electrocardiograms of the ICU patient to be tested within a preset time range and time difference data between each 12-lead electrocardiogram and the most recent 12-lead electrocardiogram among the plurality of 12-lead electrocardiograms, and an ICU patient early death risk prediction model based on an electrocardiogram obtained by any of the above-mentioned methods for constructing an ICU patient early death risk prediction model based on an electrocardiogram;
[0097] The data output module is used to output the early death risk prediction results of the intensive care unit patients to be tested to at least one terminal.
[0098] Figure 6 An example of a physical structure diagram of an electronic device is shown below. Figure 6 As shown, the electronic device may include: a processor 810, a communication interface 820, a memory 830, and a communication bus 840, wherein the processor 810, the communication interface 820, and the memory 830 communicate with each other via the communication bus 840. The processor 810 may call the logic instructions in the memory 830 to perform the following steps:
[0099] receiving, from at least one terminal, a plurality of 12-lead electrocardiograms of a patient in an intensive care unit to be tested within a preset time range and time difference data between each 12-lead electrocardiogram and a latest 12-lead electrocardiogram among the plurality of 12-lead electrocardiograms;
[0100] According to multiple 12-lead electrocardiograms of the intensive care unit patient to be tested within a preset time range and time difference data between each 12-lead electrocardiogram and the most recent 12-lead electrocardiogram among the multiple 12-lead electrocardiograms, an early death risk prediction model for intensive care unit patients based on an electrocardiogram is obtained by any of the above-mentioned methods for constructing an early death risk prediction model for intensive care unit patients based on an electrocardiogram to obtain an early death risk prediction result for the intensive care unit patient to be tested;
[0101] Outputting the early death risk prediction result of the ICU patient to be tested to at least one terminal.
[0102] In addition, the logic instructions in the above-mentioned memory 830 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when sold or used as an independent product. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.
[0103] In another aspect, the present invention further provides a computer program product, comprising a computer program, which may be stored on a non-transitory computer-readable storage medium, and wherein when the computer program is executed by a processor, the computer is capable of performing the following steps:
[0104] receiving, from at least one terminal, a plurality of 12-lead electrocardiograms of a patient in an intensive care unit to be tested within a preset time range and time difference data between each 12-lead electrocardiogram and a latest 12-lead electrocardiogram among the plurality of 12-lead electrocardiograms;
[0105] According to multiple 12-lead electrocardiograms of the intensive care unit patient to be tested within a preset time range and time difference data between each 12-lead electrocardiogram and the most recent 12-lead electrocardiogram among the multiple 12-lead electrocardiograms, an early death risk prediction model for intensive care unit patients based on an electrocardiogram is obtained by any of the above-mentioned methods for constructing an early death risk prediction model for intensive care unit patients based on an electrocardiogram to obtain an early death risk prediction result for the intensive care unit patient to be tested;
[0106] Outputting the early death risk prediction result of the ICU patient to be tested to at least one terminal.
[0107] In another aspect, the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, which is configured to execute the following steps when executed by a processor:
[0108] receiving, from at least one terminal, a plurality of 12-lead electrocardiograms of a patient in an intensive care unit to be tested within a preset time range and time difference data between each 12-lead electrocardiogram and a latest 12-lead electrocardiogram among the plurality of 12-lead electrocardiograms;
[0109] According to multiple 12-lead electrocardiograms of the intensive care unit patient to be tested within a preset time range and time difference data between each 12-lead electrocardiogram and the most recent 12-lead electrocardiogram among the multiple 12-lead electrocardiograms, an early death risk prediction model for intensive care unit patients based on an electrocardiogram is obtained by any of the above-mentioned methods for constructing an early death risk prediction model for intensive care unit patients based on an electrocardiogram to obtain an early death risk prediction result for the intensive care unit patient to be tested;
[0110] Outputting the early death risk prediction result of the ICU patient to be tested to at least one terminal.
[0111] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, i.e., they may be located in one location or distributed across multiple network units. Some or all of the modules may be selected based on actual needs to achieve the objectives of the present embodiment. Persons of ordinary skill in the art will be able to understand and implement the present invention without inventive effort.
[0112] Through the description of the above embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus a necessary general hardware platform, or of course, by hardware. Based on this understanding, the essence of the above technical solution or the part that contributes to the existing technology can be embodied in the form of a software product. The computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a magnetic disk, an optical disk, etc., and includes a number of instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or certain parts of the embodiments.
[0113] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the various embodiments of the present invention.
Claims
1. A method for constructing an electrocardiogram-based early mortality risk prediction model for intensive care unit patients, characterized in that: include: Obtain multiple 12-lead electrocardiograms (ECGs) of a patient population in an intensive care unit (ICU) within a preset time range, as well as time difference data between each 12-lead ECG and the latest 12-lead ECG among the multiple 12-lead ECGs, wherein the 12-lead ECGs and time difference data corresponding to each ICU patient in the ICU patient population are both annotated with a patient prognosis label, and the patient prognosis label includes an outcome label indicating whether the patient died and the time between the time of death and the latest 12-lead ECG; Based on multiple 12-lead electrocardiograms of intensive care unit patients within a preset time range and the time difference data between each 12-lead electrocardiogram and the most recent 12-lead electrocardiogram among the multiple 12-lead electrocardiograms, a model was trained to learn the relationship between different outcomes of intensive care unit patients and their 12-lead electrocardiograms at different time points through a patient temporal network framework with clinical significance. This resulted in an electrocardiogram-based prediction model for the risk of early death in intensive care unit patients.
2. The method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients according to claim 1, characterized in that: The temporal network framework of the patient grouping based on clinical significance includes input layer, convolution layer, multi-scale attention aggregation module, temporal confidence module, output layer, Furthermore, based on multiple 12-lead electrocardiograms of a group of intensive care unit patients within a preset time range and the time difference data between each 12-lead electrocardiogram and the most recent 12-lead electrocardiogram among the multiple 12-lead electrocardiograms, a model is trained to learn the relationship between different outcomes of intensive care unit patients and their 12-lead electrocardiograms at different time points through a patient time series network framework based on clinical significance, thereby obtaining an electrocardiogram-based early mortality risk prediction model for intensive care unit patients, including: Input multiple 12-lead electrocardiograms of a patient group in an intensive care unit within a preset time range and the time difference data of each 12-lead electrocardiogram from the latest 12-lead electrocardiogram among the multiple 12-lead electrocardiograms into the input layer of a patient timing network framework for lead grouping based on clinical significance; For each 12-lead ECG, the 12-lead ECG is divided into 6 groups of ECG data according to the preset clinical significance. The ECG features of the 6 groups of ECG data are extracted through the convolutional layer of the patient temporal network framework based on the clinical significance of the lead grouping. For each 12-lead ECG, the ECG features of the six groups of ECG data are fused through the multi-scale attention aggregation module of the clinically significant lead grouping patient temporal network framework to obtain the fused ECG features; For each 12-lead ECG, the time difference data from the latest 12-lead ECG among multiple 12-lead ECGs is used to extract the time difference feature through the time confidence module of the patient timing network framework based on clinical lead grouping. The time difference feature is then fused with the corresponding fused ECG feature to obtain the ECG confidence. According to the ECG confidence of multiple 12-lead ECGs of each ICU patient within a preset time range, the early mortality risk prediction results of each ICU patient were obtained through the output layer of the patient timing network framework with clinically significant lead grouping.
3. The method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients according to claim 2, characterized in that: The six groups include any one of the following or any combination thereof: high lateral wall group, inferior wall group, septal group, anterior wall group, lateral wall group, and auxiliary group. The pre-set clinical significance includes any one of the following or any combination thereof: High lateral wall group: leads I and avL, mainly reflecting the information of the high lateral wall of the left ventricle; Inferior wall group: leads II, III, and avF, which mainly reflect the information of the inferior wall of the heart; Interval group: V1 and V2 leads, which mainly reflect the information of the interval between the left ventricle and the right ventricle; Anterior wall group: leads V3 and V4, which mainly reflect the information of the left ventricular anterior wall; Lateral wall group: leads V5 and V6, which mainly reflect the information of the left ventricular lateral wall; Auxiliary group: avR lead, as additional auxiliary information.
4. The method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients according to claim 2, characterized in that: The convolutional layer of the patient temporal network framework for lead grouping based on clinical significance includes multiple encoders for extracting ECG features of ECG data of six groups respectively; The multi-scale attention aggregation module based on the clinically significant lead grouping patient temporal network framework includes multiple one-dimensional convolution kernels of different sizes and a self-attention mechanism module. For each 12-lead ECG, the multi-scale attention aggregation module of the clinically significant lead grouping patient temporal network framework is used to fuse the ECG features of the six groups of ECG data to obtain fused ECG features, including: For each 12-lead ECG, the multi-scale attention aggregation module uses multiple one-dimensional convolution kernels of different sizes to extract features at different time scales from the ECG features of the six groups of ECG data, obtaining multi-scale features at multiple time points. According to the multi-scale features of multiple time points, the importance weight of the multi-scale features at each time point is obtained through the self-attention mechanism module of the multi-scale attention aggregation module. Then, according to the multi-scale features of each time point and their importance weight, the multi-scale features of multiple time points are fused to obtain the fused ECG features of each 12-lead ECG.
5. The method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients according to claim 4, characterized in that: The time confidence module of the clinically significant lead grouping patient timing network framework includes a linear layer, a convolutional layer, and a gated fusion submodule. For each 12-lead ECG, according to the time difference data from the latest 12-lead ECG among multiple 12-lead ECGs, the time difference feature is extracted through the time confidence module of the clinically significant lead grouping patient timing network framework, and the time difference feature is fused with the corresponding fused ECG feature to obtain the ECG confidence, including: For each 12-lead ECG, the time difference data from the latest 12-lead ECG among multiple 12-lead ECGs is used to extract the time difference feature through the linear layer and convolution layer of the time confidence module. The shape of the extracted time difference feature is then deformed to the same shape as the ECG feature. Through the gated fusion submodule of the time confidence module, the deformed time difference features are fused with the corresponding fused ECG features to obtain the ECG confidence.
6. The method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients according to claim 5, characterized in that: The output layer of the clinically significant lead grouping patient time series network framework includes a pooling layer and a fully connected layer. The output layer of the clinically significant lead grouping patient time series network framework obtains the early death risk prediction result of each intensive care unit patient based on the electrocardiogram confidence of multiple 12-lead electrocardiograms within a preset time range of each intensive care unit patient through the output layer of the clinically significant lead grouping patient time series network framework, including: The fused ECG features and time confidence are averaged and pooled through the pooling layer of the output layer; The pooled fused ECG features and temporal confidence are mapped to the output space through the fully connected layer to obtain the early death risk prediction results of each ICU patient.
7. The method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients according to any one of claims 1 to 6, characterized in that: The method includes: training a model to learn the relationship between different outcomes of ICU patients and their 12-lead ECGs at different time points based on multiple 12-lead ECGs of ICU patients within a preset time range and time difference data between each 12-lead ECG and the latest 12-lead ECG among the multiple 12-lead ECGs, using a clinically significant lead grouping patient time series network framework, and obtaining an ECG-based early mortality risk prediction model for ICU patients, including: When training the model, stochastic gradient descent is used to minimize the loss function value.
8. An auxiliary assessment system for early death risk of patients in intensive care units, characterized by: include: The data receiving module is used to: receive from at least one terminal a plurality of 12-lead electrocardiograms of a patient in an intensive care unit to be tested within a preset time range and time difference data between each of the plurality of 12-lead electrocardiograms and the latest 12-lead electrocardiogram; A prediction module, configured to obtain an ICU patient early death risk prediction result for the ICU patient to be tested based on a plurality of 12-lead electrocardiograms of the ICU patient to be tested within a preset time range and time difference data between each 12-lead electrocardiogram and the most recent 12-lead electrocardiogram among the plurality of 12-lead electrocardiograms, using an electrocardiogram-based ICU patient early death risk prediction model obtained by the method for constructing an electrocardiogram-based ICU patient early death risk prediction model according to any one of claims 1 to 7; The data output module is used to output the early death risk prediction results of the intensive care unit patients to be tested to at least one terminal.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the program, the method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients according to any one of claims 1 to 7 is implemented, and / or when the processor executes the program, the following steps are implemented: receiving, from at least one terminal, a plurality of 12-lead electrocardiograms of a patient in an intensive care unit to be tested within a preset time range and time difference data between each 12-lead electrocardiogram and a latest 12-lead electrocardiogram among the plurality of 12-lead electrocardiograms; According to multiple 12-lead electrocardiograms of the intensive care unit patient to be tested within a preset time range and time difference data between each 12-lead electrocardiogram and the most recent 12-lead electrocardiogram among the multiple 12-lead electrocardiograms, an early death risk prediction result for the intensive care unit patient to be tested is obtained by using the electrocardiogram-based early death risk prediction model for intensive care unit patients according to the method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients according to any one of claims 1 to 7; Outputting the early death risk prediction result of the ICU patient to be tested to at least one terminal.
10. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients according to any one of claims 1 to 7 is implemented, and / or when the processor executes the program, the following steps are implemented: receiving, from at least one terminal, a plurality of 12-lead electrocardiograms of a patient in an intensive care unit to be tested within a preset time range and time difference data between each 12-lead electrocardiogram and a latest 12-lead electrocardiogram among the plurality of 12-lead electrocardiograms; According to multiple 12-lead electrocardiograms of the intensive care unit patient to be tested within a preset time range and time difference data between each 12-lead electrocardiogram and the most recent 12-lead electrocardiogram among the multiple 12-lead electrocardiograms, an early death risk prediction result for the intensive care unit patient to be tested is obtained by using the electrocardiogram-based early death risk prediction model for intensive care unit patients according to the method for constructing an electrocardiogram-based early death risk prediction model for intensive care unit patients according to any one of claims 1 to 7; Outputting the early death risk prediction result of the ICU patient to be tested to at least one terminal.