A method for predicting preoperative pulmonary complications in cardiac surgery
By employing hierarchical progressive data preprocessing and multi-model comparison, combined with feature importance analysis, a predictive model for preoperative pulmonary complications in cardiac surgery was constructed. This model addresses the shortcomings of existing models in identifying high-risk populations and key factors, enabling accurate prediction and efficient pre-rehabilitation treatment, and reducing the incidence of postoperative pulmonary complications.
Patent Information
- Application Number
- CN202511613033.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-06
- Publication Date
- 2026-02-17
- Estimated Expiration
- 2045-11-06
AI Technical Summary
Existing models for predicting pulmonary complications after cardiac surgery are complex and limited, failing to accurately identify high-risk individuals and key risk factors. This results in a lack of targeted pre-rehabilitation treatment, wasting medical resources and limiting the effectiveness of pre-rehabilitation.
A hierarchical and progressive data preprocessing workflow is adopted, including outlier handling, missing value handling, feature correlation analysis, and data discretization. It combines various machine learning algorithm models (such as logistic regression, random forest, CatBoost, etc.) and constructs a predictive model based on preoperative and intraoperative indicators through feature importance analysis and cross-validation, providing accurate pre-rehabilitation treatment plans.
It improves the accuracy and stability of the prediction model, enabling more precise identification of high-risk individuals for PPCs, reducing the incidence of postoperative pulmonary complications, minimizing waste of medical resources, and enhancing the effectiveness of pre-rehabilitation treatment.
Smart Images

Figure CN121075661B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of cardiac surgery, specifically a method for predicting preoperative pulmonary complications in cardiac surgery. Background Technology
[0002] Postoperative pulmonary complications (PPCs) are one of the most common causes of death in patients after cardiac surgery. They not only seriously threaten patients' lives but also trigger a series of costly medical events. When patients develop PPCs postoperatively, invasive and expensive medical resources such as mechanical ventilation and intensive care are often required for intervention and treatment. This places a heavy financial burden on patients' families and puts enormous pressure on the entire healthcare payment system, significantly increasing the consumption and allocation difficulties of medical resources.
[0003] Currently, global research on risk assessment of penicillin-collapse (PPC) in cardiac surgery patients has made some progress, with three models specifically developed to assess the risk of PPC occurrence. However, these three existing risk models have significant complexity and limitations, preventing their widespread adoption in clinical practice. Further analysis reveals that the initial design intent of these models was primarily to provide surgeons with guidance on adjusting surgical procedures and anesthesiologists on selecting anesthesia regimens. They did not consider the clinical decision-making needs for precise preoperative rehabilitation treatment, and therefore could not provide effective guidance for rehabilitation teams to develop targeted preoperative rehabilitation plans, thus falling short of the core clinical needs for PPC prevention and control.
[0004] Meanwhile, due to the inability of current technologies to accurately identify high-risk groups and key risk factors for PPCs, most current clinical preventive and rehabilitative treatments for PPCs adopt a comprehensive, "one-size-fits-all" approach. These approaches lack specificity, and some treatments are labor-intensive, time-consuming, and costly. Applying all rehabilitative techniques indiscriminately to all cardiac surgery patients not only wastes the labor costs of rehabilitation specialists but also leads to inefficient use of medical resources. Furthermore, because it fails to accurately match the actual risk needs of patients, the final rehabilitative treatment effect is very limited, making it difficult to effectively reduce the risk of PPCs and failing to meet the urgent clinical need for precise PPC prevention and control.
[0005] Therefore, the present invention provides a method for predicting pulmonary complications before cardiac surgery. Summary of the Invention
[0006] In order to overcome the shortcomings of the prior art, at least one technical problem raised in the background art is solved.
[0007] The technical solution adopted by this invention to solve its technical problem is: a method for predicting preoperative pulmonary complications in cardiac surgery, comprising the following steps:
[0008] S1. Data preprocessing, including outlier handling, missing value handling, feature correlation analysis, data discretization, and data standardization:
[0009] S11. Outlier handling: Filter out outliers and irrelevant data in the case dataset to avoid outliers interfering with subsequent model learning.
[0010] S12. Missing value handling: For features with a missing value rate greater than 30% in the case dataset, these features are directly removed.
[0011] For features with a missing rate of less than 30%, if the feature is a continuous variable, imputation is performed using the median or by training a regression model to predict missing values and then imputing. If the feature is a categorical variable, imputation is performed using the mode.
[0012] S13. Feature correlation analysis: Calculate the Pearson correlation coefficient between each feature and the postoperative pulmonary complication outcome of cardiac surgery patients. Use this correlation coefficient to conduct exploratory analysis of the data to understand the data distribution and the correlation between each feature and the outcome. Based on the obtained distribution and correlation information, perform data processing and feature processing.
[0013] S14. Data discretization: The continuous data in the case dataset is segmented according to medical test thresholds, so that the continuous data becomes a discretized interval and the continuous feature data is mapped to binary or multi-class features.
[0014] S15. Data standardization eliminates the differences in the units of various feature variables in the case dataset to accelerate the efficiency of subsequent model convergence.
[0015] S2. Modeling and prediction, which includes the following operations:
[0016] S21. Select a machine learning algorithm model. The machine learning algorithm models include Logistic Regression (LR), Random Forest (RF), CatBoost, LightGBM, and XGBoost.
[0017] S22. First, the 12 preoperative indicators in the case dataset after preprocessing in step S1 are used as feature data and input into the 5 machine learning algorithm models selected in step S21 for modeling and learning. Five prediction models for pulmonary complications based on the 12 preoperative indicators are constructed, and then the performance of these 5 prediction models on the test set is evaluated.
[0018] S23. Based on the 12 preoperative indicators, 5 intraoperative indicators are added to obtain a total of 17 feature indicators. The preprocessed data corresponding to these 17 feature indicators are input into the 5 machine learning algorithm models selected in step S21 for modeling and learning again, and 5 prediction models of lung complications based on the 17 feature indicators are constructed. Then, the performance of these 5 prediction models on the test set is evaluated.
[0019] S24. Perform feature importance analysis on the CatBoost model based on 17 feature indicators, and determine the feature with the highest feature contribution through the feature importance graph. The features with the highest feature contribution include cardiopulmonary bypass count, aortic clamping time, operation duration and total autologous blood recovery. Based on this CatBoost model, predict preoperative pulmonary complications of cardiac surgery.
[0020] Preferably, in step S1, after performing feature correlation analysis, features with low correlation and no significant contribution to the prediction results are screened out based on the correlation information between each feature and the outcome.
[0021] Preferably, in step S2, when evaluating the performance of the prediction model, in addition to using the AUC value as the evaluation index, at least one of accuracy, precision, recall and F1 score is also used as an auxiliary evaluation index.
[0022] Preferably, in steps S22 and S23, before modeling and learning, the preprocessed feature data is divided into a training set and a test set according to a preset ratio, wherein the preset ratio is training set: test set = 7:3 or 8:2.
[0023] Preferably, in step S2, during the construction of the prediction model, the model is trained and optimized using 5-fold cross-validation or 10-fold cross-validation.
[0024] The beneficial effects of this invention are as follows:
[0025] 1. The present invention provides a method for predicting preoperative pulmonary complications in cardiac surgery. This method ensures data quality and feature validity from the source through a hierarchical and progressive data preprocessing workflow: filtering outliers and irrelevant data avoids noise interference with model learning; and handling missing values differently based on the missing rate (features with a missing rate > 30% are removed, and features with a missing rate < 30% are filled using median, regression prediction, or mode according to variable type). Compared to the simple filling method of existing models, this significantly reduces data bias and improves data integrity and reliability.
[0026] By calculating the Pearson correlation coefficient to screen highly correlated features and eliminating low-contribution features, and combining it with recursive feature elimination (RFE) to identify 12 core preoperative risk factors, the problem of feature redundancy and unclear identification of key factors in existing models is solved. This makes the feature set more in line with the prediction needs of PPCs, reduces the time and space overhead of the algorithm, and improves the efficiency of model operation.
[0027] Discretizing continuous data based on medical test thresholds not only aligns with clinical medical cognition but also enhances data robustness and feature interpretability. Standardization eliminates dimensional differences, accelerates model convergence, avoids prediction biases caused by inconsistent data formats in existing models, and provides high-quality data input for subsequent modeling.
[0028] 2. The present invention provides a method for predicting preoperative pulmonary complications in cardiac surgery, which achieves a qualitative improvement in predictive performance through multi-model comparison and feature increment optimization: five mainstream machine learning models, including logistic regression (LR), random forest (RF), and CatBoost, are selected and modeled based on 12 preoperative indicators and 5 newly added intraoperative indicators, respectively. The results show that the CatBoost model based on 17 features has an AUC of 0.8069 on the test set, which is significantly higher than other models such as LR (0.7291) and RF (0.7453). Moreover, the NPV (0.9495), PPV (0.2651), and F1 score (0.3745) are the best, which solves the problem of low prediction accuracy of existing models and can more accurately identify high-risk groups for PPCs.
[0029] By adding key intraoperative indicators (cardiopulmonary bypass count, aortic clamping time, etc.), we further explore the core factors for PPC prediction, making the model more consistent with the actual clinical diagnosis and treatment process. At the same time, we use 5-fold or 10-fold cross-validation to optimize the model and avoid overfitting. Compared with the single training method of existing models, we significantly improve the generalization ability of the model and ensure that it can play a stable predictive role in different clinical scenarios. This solves the problem of poor clinical applicability and difficulty in widespread promotion of existing models.
[0030] Existing models can be used to guide the selection of surgical and anesthesia methods and support pre-rehabilitation treatment. This method, through hierarchical modeling with 12 preoperative indicators for preliminary prediction (AUC 0.7594) and 17 indicators for precise prediction (AUC 0.8069), not only meets the needs of early preoperative risk screening, but also achieves more accurate prediction by combining intraoperative indicators. It provides a sufficient time window and accurate risk basis for the formulation of preoperative rehabilitation treatment plans, filling the gap in the field of pre-rehabilitation guidance of existing models.
[0031] 3. The present invention provides a method for predicting preoperative pulmonary complications in cardiac surgery, which achieves model transparency and treatment precision through feature importance analysis and Shapvalue plot interpretation: the feature importance plot identifies intraoperative indicators such as cardiopulmonary bypass count, aortic clamping time, operation duration, and total autologous blood recovery, as well as preoperative indicators such as age and eGFR, as key factors for predicting PPCs, thus solving the problem of ambiguous risk factors in existing models and enabling clinicians to accurately focus on high-risk aspects;
[0032] By using Shapvalue plots to quantify the impact of various features on prediction results (e.g., lower eGFR and longer operation duration lead to higher PPC risk), the prediction logic is more consistent with clinical understanding compared to existing "black box" models, making it easier for doctors to understand and trust, and improving the clinical acceptance and application rate of the model. Based on clearly defined high-risk groups and key risk factors, clinicians can develop targeted pre-rehabilitation plans (e.g., strengthening lung function training for elderly patients with low eGFR, and optimizing surgical procedures for patients with long operation time risks), replacing the existing "undifferentiated" comprehensive plan. This avoids the inefficient consumption of rehabilitation experts' labor costs and medical resources, while improving the effectiveness of pre-rehabilitation treatment, reducing the incidence of PPC from the source, alleviating the pressure on the healthcare payment system, and solving the problems of waste of medical resources and limited pre-rehabilitation effects in the background technology. Attached Figure Description
[0033] The invention will now be further described with reference to the accompanying drawings.
[0034] Figure 1 This is the ROC plot of the preoperative feature training set in this invention;
[0035] Figure 2 This is the ROC plot of the preoperative feature test set in this invention;
[0036] Figure 3 This is the Shapvalue diagram in this invention;
[0037] Figure 4 This is a diagram illustrating the data annotation and model building process based on the Melbourne Scale in this invention. Detailed Implementation
[0038] To make the technical means, creative features, objectives and effects of this invention easier to understand, the invention will be further described below in conjunction with specific embodiments.
[0039] like Figures 1 to 4 As shown in the figure, an embodiment of the present invention provides a method for predicting preoperative pulmonary complications in cardiac surgery, the method comprising the following steps:
[0040] S1. Data preprocessing, including outlier handling, missing value handling, feature correlation analysis, data discretization, and data standardization:
[0041] S11. Outlier handling: Filter out outliers and irrelevant data in the case dataset to avoid outliers interfering with subsequent model learning.
[0042] S12. Missing value handling: For features with a missing value rate greater than 30% in the case dataset, these features are directly removed.
[0043] For features with a missing rate of less than 30%, if the feature is a continuous variable, imputation is performed using the median or by training a regression model to predict missing values and then imputing. If the feature is a categorical variable, imputation is performed using the mode.
[0044] S13. Feature correlation analysis: Calculate the Pearson correlation coefficient between each feature and the postoperative pulmonary complications of cardiac surgery patients. Use this correlation coefficient to conduct exploratory analysis of the data to understand the data distribution and the correlation between each feature and the outcome. Based on the obtained distribution and correlation information, perform data processing and feature processing to improve feature quality and provide a basis for the selection of subsequent model methods.
[0045] S14. Data discretization: The continuous data in the case dataset is segmented according to medical test thresholds, turning the continuous data into discretized intervals. The continuous feature data is mapped to binary or multi-class features to increase the data's noise resistance, improve the interpretability of features, and reduce the time and space overhead of subsequent algorithms.
[0046] S15. Data standardization eliminates the differences in the units of various feature variables in the case dataset to accelerate the efficiency of subsequent model convergence.
[0047] S2. Modeling and prediction, which includes the following operations:
[0048] S21. Select a machine learning algorithm model. The machine learning algorithm models include Logistic Regression (LR), Random Forest (RF), CatBoost, LightGBM, and XGBoost.
[0049] S22. First, the 12 preoperative indicators in the case dataset after preprocessing in step S1 are used as feature data and input into the 5 machine learning algorithm models selected in step S21 for modeling and learning. Five prediction models for pulmonary complications based on the 12 preoperative indicators are constructed. Then, the performance of these 5 prediction models on the test set is evaluated. The evaluation shows that the CatBoost model has the highest AUC value on the test set, which is 0.7594.
[0050] S23. Based on the 12 preoperative indicators, 5 intraoperative indicators are added, resulting in a total of 17 feature indicators. The preprocessed data corresponding to these 17 feature indicators are input into the 5 machine learning algorithm models selected in step S21 for modeling and learning again, and 5 prediction models for pulmonary complications based on the 17 feature indicators are constructed. Then, the performance of these 5 prediction models on the test set is evaluated. The evaluation shows that the CatBoost model still has the highest AUC value on the test set, which is 0.8069.
[0051] S24. Perform feature importance analysis on the CatBoost model based on 17 feature indicators, and determine the feature with the highest feature contribution through the feature importance graph. The features with the highest feature contribution include cardiopulmonary bypass count, aortic clamping time, operation duration and total autologous blood recovery. Based on this CatBoost model, predict preoperative pulmonary complications of cardiac surgery.
[0052] In step S1, after performing feature correlation analysis, features with low correlation and no significant contribution to the prediction results are screened out based on the correlation information between each feature and the outcome, thereby further optimizing the feature set.
[0053] In step S2, when evaluating the performance of the prediction model, in addition to using the AUC value as the evaluation metric, at least one of accuracy, precision, recall and F1 score is used as an auxiliary evaluation metric to comprehensively evaluate the model performance.
[0054] In steps S22 and S23, before modeling and learning, the preprocessed feature data is divided into a training set and a test set according to a preset ratio, which is training set: test set = 7:3 or 8:2.
[0055] In step S2, during the construction of the prediction model, 5-fold cross-validation or 10-fold cross-validation is used to train and optimize the model in order to improve the model's stability and generalization ability.
[0056] Specifically,
[0057] By combining the Melbourne Rating Scale to time-stamp patient outcomes and extracting relevant outcome-related data as modeling data, we used CatBoost to train and model the data, constructing a predictive model that can predict whether postoperative pulmonary complications will occur before patients undergo cardiac surgery.
[0058] (a) Determine the diagnostic label for postoperative pulmonary complications in patients based on the Melbourne Scale.
[0059] Based on the judgment indicators of the Melbourne scale, the data sources for the relevant indicators can be found. The data sources involve data from different hospital information systems, including reports and conclusions from imaging examination systems, medical orders from the HIS system, surgical operation records from the surgical anesthesia system, and data from mechanical ventilators in the intensive care unit.
[0060] The raw data came from hospital electronic information systems (HIS, LIS, PACS, etc.), and were integrated according to the patient's unique ID to form a structured raw case dataset. Postoperative pulmonary complications (PPCs) were labeled according to clinical definitions and the Melbourne Group Scale (MGS) rules, resulting in a binary outcome variable (PPCs: present / absent). The labeling process was independently determined by two clinicians, with any conflicts arbitrated by a third physician. The PPC outcome judgment criteria defined in the Melbourne Group Scale correspond to the relevant data sources, and the key diagnostic terms for PPC judgment are shown in Table 1.
[0061] Based on the data sources and key diagnostic terms listed in Table 1, key data fields of the patient's current visit can be collected from various information systems and used as modeling parameters. Based on the judgment rules, PPC disease labels are made to construct a PPC predictive analysis dataset.
[0062] The data is divided into two categories: ① Historical (baseline) data, including static variables such as past medical history, laboratory tests, imaging indicators, and demographic information; ② Incremental data, which has the same collection dimensions as historical data and is initially included in the PPCs analysis dataset. After the model is built, data is collected again as incremental data for model optimization. The data source and timestamp are retained, ultimately forming an analysis candidate set containing 28 candidate indicators.
[0063] Table 1 shows the labeling of postoperative complications (PPCs) in cardiac surgery patients. This is an abstract, general rule. Table 1 below is a table of PPC outcome indicators and judgment rules:
[0064] .
[0065] (II) Data Acquisition and Feature Selection
[0066] Extract patient data based on the following criteria from the hospital data system:
[0067] ① Preoperative diagnosis was infective endocarditis or aortic dissection;
[0068] ② The surgical procedures included aortic root surgery, aortic arch surgery, bypass surgery, or heart valve surgery. A total of 6,608 cases constituted a retrospective study cohort. Recursive Feature Elimination (RFE) based on an optimal model was used to screen for the best feature set. Ultimately, 12 risk factors were identified as having the greatest impact on PPC outcome events: age, glomerular filtration rate (eGFR), smoking history, albumin, left ventricular ejection fraction (LVEF), total bilirubin (TBIL), white blood cell count (WBC), arterial oxygen partial pressure (PaO2), lactate dehydrogenase (LDH), previous cardiac surgery, hemoglobin, and left ventricular diameter.
[0069] Modeling Process: Five machine learning algorithms were used: LR, RF, CatBoost, LightGBM, and XGBoost. First, the five algorithms were trained on 12 preoperative indicators, with CatBoost showing the highest AUC (0.7594) on the test set. Then, five intraoperative indicators were added, resulting in a total of 17 features. The five algorithms were trained again, and CatBoost again showed the best AUC (0.7594) on the test set. The feature importance graph revealed that the features contributing the most were: cardiopulmonary bypass activation count, aortic clamping time, surgical duration, and total autologous blood salvage, indicating that intraoperative indicators played a major role in predicting pulmonary complications.
[0070] Model Interpretation: The constructed model is interpreted by plotting Shapvalues. For example, we found that longer surgery duration has a positive impact on postoperative complications, and older age or lower glomerular filtration rate also have a positive impact on postoperative complications.
[0071] Model parameters:
[0072] CatBoostClassifier(loss_function="Logloss",
[0073] eval_metric="AUC",
[0074] learning_rate=0.01,
[0075] iterations=1000,
[0076] random_seed=42,
[0077] od_type="Iter",
[0078] depth=4,
[0079] early_stopping_rounds=800,
[0080] colsample_bylevel=0.2,
[0081] l2_leaf_reg=30,
[0082] random_strength=800,
[0083] scale_pos_weight=1,
[0084] silent=True )
[0086] RandomForestClassifier(n_estimators=300, max_depth=4, min_samples_split=20,min_samples_leaf=5, max_features=3, oob_score=True, random_state=2023)
[0087] LogisticRegression(class_weight='balanced', random_state=5000, max_iter=200, solver='lbfgs', penalty='l2')
[0088] LGBMClassifier( boosting_type='gbdt'
[0089] ,objective='binary'
[0090] ,learning_rate=0.02
[0091] ,n_estimators=300
[0092] ,max_depth=3
[0093] ,num_leaves=20
[0094] ,min_child_samples=20
[0095] ,min_child_weight=10
[0096] ,bagging_fraction=1
[0097] ,feature_fraction=0.9
[0098] ,subsample=1
[0099] ,colsample_bytree=0.8
[0100] ,reg_alpha=5
[0101] ,reg_lambda=10
[0102] ,random_state=2024 )
[0104] XGBClassifier(objective='binary:logistic'
[0105] ,learning_rate=0.02
[0106] ,n_estimators=350
[0107] ,max_depth=3
[0108] ,min_child_weight=10
[0109] ,gamma=0.98
[0110] ,subsample=1
[0111] ,colsample_bytree=0.9
[0112] ,scale_pos_weight=1
[0113] ,reg_alpha=1
[0114] ,reg_lambda=20
[0115] ,n_jobs=-1
[0116] ,seed=2019).
[0117] (III) Experiments and Results
[0118] The sample data of 6608 were divided into training data (5286 cases) and test data (1322 cases) according to the proportion. We compared five models, including logistic regression (LR), random forest, LightGBM, XGBoost and CatBoost, and conducted a detailed performance evaluation on the training set and the test set.
[0119] The key performance metrics of each model on the training and test sets, including AUC (area under the curve), NPV (negative predictive value), PPV (positive predictive value), recall, specificity, and F1 score, are analyzed as shown in Table XXX.
[0120] Among the five models, Logistic Regression (LR) had an AUC of 0.7117 on the training set and an AUC of 0.7291 on the test set, demonstrating a moderate level of predictive ability.
[0121] The NPV was 0.9442, PPV was 0.2366, F1 score was 0.3408, recall was 0.6087, and specificity was 0.7711.
[0122] Random Forest: The AUC on the training set is 0.7857 and the AUC on the test set is 0.7453, which is slightly better than LR; the NPV is 0.9587, the PPV is 0.1812, the F1 score is 0.2943, the recall is 0.7826, and the specificity is 0.5878.
[0123] LightGBM: The training set AUC is 0.7995 and the test set AUC is 0.7427, showing a high training set AUC but a slight decrease on the test set;
[0124] The NPV was 0.9445, PPV was 0.2316, F1 score was 0.3366, recall was 0.6159, and specificity was 0.7618.
[0125] XGBoost: The highest AUC on the training set is 0.8083, and the AUC on the test set is 0.7455, showing good generalization ability;
[0126] The NPV was 0.9447, PPV was 0.2342, F1 score was 0.3393, recall was 0.6159, and specificity was 0.7652.
[0127] CatBoost: The AUC on the training set is 0.7805 and the AUC on the test set is 0.7594, with the best performance on the test set;
[0128] The NPV was 0.9495, PPV was 0.2651, F1 score was 0.3745, recall was 0.6377, and specificity was 0.7939.
[0129] As shown in Table 2, Table 2 below is a chart of key performance metrics on the training and test sets during model development:
[0130] .
[0131] Based on the test set AUC, NPV, PPV, and F1 score, CatBoost performed best among all models. Its AUC on the test set was 0.7594, demonstrating high predictive and generalization abilities. The ROC of the feature training set for the five models is as follows: Figure 1 As shown, the ROC of the feature test set is as follows: Figure 2 As shown.
[0132] CatBoost significantly outperformed other models in NPV (0.9495), PPV (0.2651), and F1 score (0.3745), demonstrating its advantage in handling imbalanced positive and negative samples and balancing accuracy. Although XGBoost had a slightly higher AUC on the training set, CatBoost performed better on the test set across multiple key metrics, particularly in recall and specificity. Ultimately, we decided to prioritize the CatBoost model for prediction tasks.
[0133] for Figure 3 The Shapvalue plot can be used for model interpretation, quantifying the contribution of each feature to the model's prediction results. For example, we found that the smaller the eGFR value, the more positive the impact on the outcome.
[0134] Figure 1 Here is the ROC curve of the preoperative features of the training set, and AUC is the area under the curve.
[0135] Figure 2 ROC curve for preoperative features of the test set; AUC is the area under the curve.
[0136] Figure 3 The SHAP value plot shows the contribution of each feature to the model.
[0137] The foregoing has shown and described the basic principles, main features, and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The embodiments and descriptions in the specification are merely illustrative of the principles of the invention. Various changes and modifications can be made to the invention without departing from its spirit and scope, and all such changes and modifications fall within the scope of the present invention as claimed. The scope of protection of the present invention is defined by the appended claims and their equivalents.
Claims
1. A method for predicting preoperative pulmonary complications in cardiac surgery, characterized in that, The method includes the following steps: S1. Data preprocessing, including outlier handling, missing value handling, feature correlation analysis, data discretization, and data standardization: S11. The outlier processing involves filtering out outliers and irrelevant data in the case dataset to avoid outliers interfering with subsequent model learning. S12. For missing value processing, features with a missing rate greater than 30% in the case dataset are directly removed. For features with a missing rate of less than 30%, if the feature is a continuous variable, imputation is performed using the median or by training a regression model to predict missing values and then imputing. If the feature is a categorical variable, imputation is performed using the mode. S13. The feature correlation analysis calculates the Pearson correlation coefficient between each feature and the postoperative pulmonary complication outcome of cardiac surgery patients. The data is then used to conduct exploratory analysis based on the correlation coefficient to understand the data distribution and the correlation between each feature and the outcome. Data processing and feature processing are then performed based on the obtained distribution and correlation information. S14. The data discretization involves segmenting the continuous data in the case dataset according to medical test thresholds, transforming the continuous data into discretized intervals, and mapping the continuous feature data into binary or multi-class features. S15. The data standardization eliminates the differences in the units of various feature variables in the case dataset, so as to accelerate the efficiency of subsequent model convergence. S2. Modeling and prediction, which includes the following operations: S21. Select a machine learning algorithm model, which includes Logistic Regression (LR), Random Forest (RF), CatBoost, LightGBM, and XGBoost. S22. First, the 12 preoperative indicators in the case dataset after preprocessing in step S1 are used as feature data and input into the 5 machine learning algorithm models selected in step S21 for modeling and learning. Five prediction models for pulmonary complications based on the 12 preoperative indicators are constructed, and then the performance of these 5 prediction models on the test set is evaluated. S23. Based on the 12 preoperative indicators, 5 intraoperative indicators are added to obtain a total of 17 feature indicators. The preprocessed data corresponding to these 17 feature indicators are input into the 5 machine learning algorithm models selected in step S21 for modeling and learning again, and 5 prediction models of lung complications based on the 17 feature indicators are constructed. Then, the performance of these 5 prediction models on the test set is evaluated. S24. Perform feature importance analysis on the CatBoost model based on 17 feature indicators, and determine the feature with the highest feature contribution through the feature importance graph. The feature with the highest feature contribution includes cardiopulmonary bypass count, aortic clamping time, operation duration and total autologous blood recovery. Based on this CatBoost model, predict preoperative pulmonary complications of cardiac surgery.
2. The method for predicting preoperative pulmonary complications in cardiac surgery according to claim 1, characterized in that: In step S1, after performing feature correlation analysis, features with low correlation and no significant contribution to the prediction results are screened out based on the correlation information between each feature and the outcome.
3. The method for predicting preoperative pulmonary complications in cardiac surgery according to claim 1, characterized in that: In step S2, when evaluating the performance of the prediction model, in addition to using the AUC value as the evaluation metric, at least one of accuracy, precision, recall and F1 score is used as an auxiliary evaluation metric.
4. The method for predicting preoperative pulmonary complications in cardiac surgery according to claim 1, characterized in that: In steps S22 and S23, before modeling and learning, the preprocessed feature data is divided into a training set and a test set according to a preset ratio, wherein the preset ratio is training set: test set = 7:3 or 8:
2.
5. The method for predicting preoperative pulmonary complications in cardiac surgery according to claim 1, characterized in that: In step S2, during the construction of the prediction model, the model is trained and optimized using 5-fold cross-validation or 10-fold cross-validation.
Citation Information
Patent Citations
PRO prognosis risk model for chronic heart failure patient and construction method
CN115274116A
Scalable system and method for forecasting wind turbine failure with varying lead time windows
US20200210824A1