key: cord-255473-kizyv6mp authors: Ferrari, D.; Milic, J.; Tonelli, R.; Ghinelli, F.; Meschiari, M.; Volpi, S.; Faltoni, M.; Franceschi, G.; Iadisernia, V.; Yaacoub, D.; Ciusa, G.; Bacca, E.; Rogati, C.; Tutone, M.; Burastero, G.; Raimondi, A.; Menozzi, M.; Franceschini, E.; Cuomo, G.; Corradi, L.; Orlando, G.; Santoro, A.; Di Gaetano, M.; Puzzolante, C.; Carli, F.; Bedini, A.; Fantini, R.; Tabbi, L.; Castaniere, I.; Busani, S.; Clini, E.; Girardis, M.; Sarti, M.; Cossarizza, A.; Mussini, C.; Mandreoli, F.; Missier, P.; Guaraldi, G. title: Machine learning in predicting respiratory failure in patients with COVID-19 pneumonia - challenges, strengths, and opportunities in a global health emergency date: 2020-06-02 journal: nan DOI: 10.1101/2020.05.30.20107888 sha: doc_id: 255473 cord_uid: kizyv6mp Background Machine learning can assist clinicians in forecasting patients with COVID-19 who develop respiratory failure requiring mechanical ventilation. This analysis aimed to determine a 48 hours prediction of moderate to severe respiratory failure, as assessed with PaO2/FiO2 < 150 mmHg, in hospitalized patients with COVID-19 pneumonia. Methods This was an observational study that comprised all consecutive adult patients with COVID-19 pneumonia admitted to the Infectious Diseases Clinic of the University Hospital of Modena, Italy from 21 February to 6 April 2020. COVID-19 was confirmed with PCR positive nasopharyngeal swabs while the presence of pneumonia was radiologically confirmed. Patients received standard of care according to national guidelines for clinical management of SARS-CoV-2 infection. The patients' full medical history, demographic and epidemiological features, clinical data, complete blood count, coagulation, inflammatory and biochemical markers were routinely collected and aggregated in a clinically-oriented logical framework in order to build different datasets. The dataset was used to train a learning framework relying on Microsoft LightGBM and leveraging a hybrid approach, where clinical expertise is applied alongside a data-driven analysis. Shapley Additive exPlanations (SHAP) values were used to quantify the positive or negative impact of each variable included in the model on the predicted outcome. The study outcome was the onset of moderate to severe respiratory failure defined as PaO2/FiO2 ratio < 150 mmHg ([≥] 13.3 kPa) in at least one of two consecutive arterial blood gas analyses in the following 48 hours. Results A total of 198 patients contributed to generate 1068 valuable observations which allowed to build 3 prediction models based respectively on 31-variables signs and symptoms, 39-variables laboratory biomarkers and 91-variables as a composition of the two. A fourth boosted mixed model which included 20 variables was selected from the model 3, achieved the best predictive performance (AUC=0.84). Its clinical performance was applied in a narrative case report as an example. Conclusion This study developed a machine learning algorithm, with a 84% prediction accuracy, which is potentially able to assist clinicians in decision making process with therapeutic implications. The aim of this study was to estimate a 48 hour prediction of moderate to severe respiratory failure, requiring mechanical ventilation, in hospitalized patients with COVID-19 pneumonia. This was an observational study that comprised consecutive patients with COVID-19 pneumonia admitted to hospital from 21 February to 6 April 2020. The patients' medical history, demographic, epidemiologic and clinical data were collected in an electronic patient chart. The dataset was used to train predictive models using an established machine learning framework leveraging a hybrid approach where clinical expertise is applied alongside a data-driven analysis. The study outcome was the onset of moderate to severe respiratory failure defined as PaO2/FiO2 ratio <150 mmHg in at least one of two consecutive arterial blood gas analyses in the following 48 hours. Shapley Additive exPlanations values were used to quantify the positive or negative impact of each variable included in each model on the predicted outcome. A total of 198 patients contributed to generate 1068 usable observations which allowed to build 3 predictive models based respectively on 31-variables signs and symptoms, 39variables laboratory biomarkers and 91-variables as a composition of the two. A fourth "boosted mixed model" included 20 variables was selected from the model 3, achieved the best predictive performance (AUC=0.84) without worsening the FN rate. Its clinical performance was applied in a narrative case report as an example. This study developed a machine model with 84% prediction accuracy, which is able to assist clinicians in decision making process and contribute to develop new analytics to improve care at high technology readiness levels. COVID pandemic found all health care system inadequately prepared and urges the need for new tools to face this unprecedented public health and clinical emergency. The clinical complexity of COVID-19 ranges from asymptomatic cases to severe pneumonia [1] [2] [3] whose progression to respiratory failure is difficult to predict. Pneumonia mostly occurs in the second or third week of a symptomatic infection and it is characterized by a mortality rate of 3-10%, which increases risk of multiorgan failure and mechanical ventilation [4] . Patients most commonly report the sudden onset of dyspnea during daily activities or rest. Prominent clinical signs include respiratory rate ≥ 30 breaths per minute, blood oxygen saturation ≤ 93%, partial pressure of arterial oxygen to fraction of inspired oxygen ratio (PaO2/FiO2) < 300 mmHg. This is an initial phase of acute respiratory distress syndrome (ARDS) that progressively leads to moderate to severe respiratory failure [4] . Overall, there is a high degree of uncertainty both in the progression of the patient's health status and in the speed at which patients develop respiratory failure requiring mechanical ventilation. Machine learning methods such as those employed to create the model have shown potential to produce predictive models that can be applied to assist and improve clinical decisions for a broad variety of outcomes [5, 6] , and have recently been used in response to the COVID-19 emergency [7] [8] [9] . The aim of this study was to have a 48 hour prediction of moderate to severe respiratory failure, requiring mechanical ventilation, in hospitalized patients with COVID-19 pneumonia. This study included consecutive adult patients (≥18 years) admitted to Infectious Disease Clinic of the University Hospital of Modena, Italy from 21 February to 6 April 2020 with radiologically findings suggestive for COVID-19 pneumonia and confirmed by PCR method on nasopharyngeal swab. All patients received treatment according to the Italian Society of Infectious Diseases' Guidelines (SIMIT) recommendations [10] including oxygen supply to target SaO2 > 90%; hydroxychloroquine with or without azithromycin, and low molecular weight heparin. . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity. (which was not certified by peer review) The copyright holder for this preprint this version posted June 2, 2020. . https://doi.org/10.1101/2020.05.30.20107888 doi: medRxiv preprint Lopinavir/ritonavir or darunavir/cobicistat was also used up to 18 March, when a clinical trial on the former did not show any benefit of protease inhibitors against the standard of care [11] . The study outcome was the onset of moderate to severe respiratory failure defined as PaO2/FiO2 ratio < 150 mmHg (≤ 13.3 kPa) at arterial blood gas analyses in the following 48 hours. The patients' full medical history including chronic comorbidities, demographic and epidemiological data were obtained at the hospital admission. Clinical data with signs and symptoms and complete blood count, coagulation, inflammatory and biochemical markers were routinely collected in the electronic patient charts. To be considered viable for clinical use, a predictive model must not only be accurate, it must also be (1) parsimonious, that is, it must achieve its accuracy using the minimal number of variables; (2) robust to missing data, an important feature in clinical emergency setting where not all observations are complete at each assessment; (3) transparent, in the sense that the model reveals the relative importance of each variable for each prediction it makes, which may be different for different patients. This is particularly important in clinical settings as it enables healthcare professionals to interpret the pathophysiological . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity. The copyright holder for this preprint this version posted June 2, 2020. Meeting the final goal of minimizing FN (4) required that a specialized loss function be developed specifically for this task. This is a function that the algorithm must minimise in order to produce optimal predictions, and in this case it includes a tunable parameter to control the ratio of FP to FN. For this binary classifier we used the PaO2/FiO2 ratio to derive a binary outcome for the learning task, where a positive outcome is defined as PaO2/FiO2 ≥ 150, and negative PaO2/FiO2 < 150. These are referred to as the positive and negative classes, respectively. Following best practices, the dataset was divided into two parts: the training set (75% of the data -801 samples) and a complementary test set (the remaining 25% -267 samples), which was not used in the learning phase. This separation was stratified according to the distribution of the outcome, in order to maintain a constant ratio between positive and negative classes in each of the subsets. The training set was used as input to the ML algorithm to train the model, while the test set is used to verify the predictive performance using standard metrics. The test set provided independent ground truth where each instance (a patient's set of observations) was associated with one of the two possible outcomes. This . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity. The copyright holder for this preprint this version posted June 2, 2020. Model performance was measured both on the AUROC and the sensitivity.. The LightGBM algorithm not only allowed tuning of their hyper-parameters (these are the parameters that cannot be learnt by the algorithm and must be set manually) in order to maximize performance, but they also allowed more specific optimization targets than simply accuracy. For this application, clinical priority was followed to maximize the sensitivity, defined as variable selection approach was adopted, by which each variable was excluded in turn, starting from the lowest-ranked variables, and the loss in predictive performance was measured each time. This procedure identified Model 4 as the one that minimized the . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity. The copyright holder for this preprint this version posted June 2, 2020. In addition to the theoretical performance, anecdotal validation was also provided in a real-life case setting. We applied our model to the clinical course of a 55 year old male who was admitted for high fever and shortness of breath due to COVID-19 pneumonia. Antiviral therapy with darunavir/cobicistat was started in addition to hydroxychloroquine. He was discharged the following day, in the absence of respiratory failure as assessed by PaO2/FiO2 =420 mmHg. Four days later, he was readmitted to hospital with high fever (39°C), diarrhea and onset of mild respiratory failure (PaO2/FiO2 = 230 mmHg). Inflammatory biomarkers were high (CRP 18 mg/dl) with elevated neutrophils. In the following 24 hours, the patient experienced a clinically unpredictable dramatic worsening of his clinical condition due to the onset of severe respiratory distress despite adequate oxygen supply (PaO2/FiO2 = 88 mmHg, respiratory rate higher than 35 breaths per minute). He was then transferred to the Intensive Care Unit (ICU) where non-invasive mechanical ventilation with helmet in pressure support mode was initiated. After 8 days of assisted spontaneous breathing, he was weaned from NIV and discharged the following day without oxygen supply (figure 3). As shown in the case scenario presented above, the model was retrospectively applied in order to explore the prediction of "respiratory crush" in support of clinical judgment. From the physician's point of view, the first discharge was motivated by the stable clinical conditions. However, our model showed a 36.6% probability of worsening of the respiratory function in the following 48 hours, meeting the criteria for mechanical ventilation with pressure support in the next two days. Moreover, the model was able to predict at the time of the second admission, the respiratory function decline that our patient actually experienced 24 hours later. The model at day 14 predicted a 47.4% risk or new worsening, but this should have been integrated with clinical data suggested by patient's perception of improvement and rapid increase of blood gas exchange. A deployment of our support model . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity. The copyright holder for this preprint this version posted June 2, 2020. . https://doi.org/10.1101/2020.05.30.20107888 doi: medRxiv preprint at the time into our clinical practice would have provided support to clinical judgment, suggesting against the first discharge, and furthermore, recommending continuous monitoring once the patient was readmitted in order to possibly avoid ICU with urgent treatment. We have created a statistical learning model to assist clinicians in forecasting patients with COVID-19 who develop respiratory failure requiring mechanical ventilation. The model provide a reliable 48 hours prediction of moderate to severe respiratory failure, with an accuracy of 84% that minimizes the FN rate. Our model is (1) We chose to have a short-term outcome to support clinicians at hospital admission and discharge. Given the rapid and dynamic clinical changes affecting COVID-19 patients, this time frame should be considered crucial for the initiation of therapies aimed at avoiding ICU admission and mechanical ventilation. In the future we may be able to develop similar models to also support clinicians to better interpret patient's clinical improvement after they are discharged from hospital. The construction of different models followed a clinically oriented variables choice. The first model based on 31 variables obtained from signs and symptoms returned a suboptimal prediction accuracy. Adding biomarkers including respiratory variables significantly increased the forecasting capacity of the model. The best performance was obtained in the boosted mixed model, which however still requires about 20 variables. From a physician's perspective, a cluster of 20 variables may be difficult to manage in routine . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity. The copyright holder for this preprint this version posted June 2, 2020. . https://doi.org/10.1101/2020.05.30.20107888 doi: medRxiv preprint clinical practice. What our approach offers in support to the decision-making process is a simple interpretation of the predictions. Machine learning approach is at the top of the list of the research priorities proposed by the Horizon 2020 program (H2020) [16] . This study may contribute to develop new analytics to improve care at high technology readiness levels. Moderate to severe respiratory failure was chosen as an outcome being the most relevant time point in the natural history of severe COVID-19 pneumonia. At a clinical level, it represents the so-called "respiratory crush" which marks acute lung injury and leads to mechanical ventilation in ICU. At a public health level, it might allow to optimize scarce resources like respirators and ICU beds. In a similar experience from China, ML was used to predict mortality in patients with COVID-19, using three biomarkers only [7] . Not surprisingly, this hard endpoint can be predicted with a very limited number of biomarkers, reducing the clinical parameters to be monitored. However, clinical worsening seems to be more challenging to forecast. An intermediate dynamic event with multiple biomarkers appears to be more difficult to predict than a final static event, such as mortality, with a small number of variables. This science data faced several methodological challenges. Features which fed the model were chosen based both on a statistical exploratory data analysis and on clinicians' suggestion, in a hybrid approach. This allowed to take advantage of both aspects: on one side the clinical experience of physicians who selected variables and outcomes using a knowledge-based approach, and on the other side, the probabilistic nature of a data-driven framework. Microsoft LightGBM framework was chosen in particular to support missing data deriving from a clinical setting where it was not practical to collect all observations at each data point. Clinicians appreciated the "Glass box" opportunity, which showed the top variables, trusting a model in which pathophysiological interpretation could still be plausible. With regards to the 20 variables selected in the hybrid models, some can be clustered within the hypoxic damage (dyspnea, HCO3 -, pH, reparatory and heart rate) other in relation to inflammation (C-reactive protein, D-dimer, platelets, red blood cells, lymphocytes), other in relation to organ damage (lactate dehydrogenase, creatinine-kinase). Medical Decision Support Systems must provide transparency to explain how the predictive model behaves. In this perspective, an interpretation approach is necessary, both to have better . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity. The copyright holder for this preprint this version posted June 2, 2020. Our study has several limitations. Firstly, it does not take account of radiological findings on X-rays or CT, as these data were not collected consistently during the admission period. Secondly, we chose as outcome a cut-off of PaO2/FiO2 which represents one of the most important criteria for invasive mechanical ventilation, but not mechanical ventilation itself. Also, the model is oblivious to a whole panel of interleukins values, as they were not collected on daily basis regardless of their potential involvement in the development of severe respiratory failure. Lastly, the model will need to evolve with the growth of the dataset, providing a more accurate cut-off risk value. In conclusion, this study developed a machine learning algorithm aimed to assist clinicians in dealing with COVID-19 health emergency. It is proving useful in predicting severe respiratory failure requiring mechanical ventilation in the following 48 hours, allowing to anticipate urgent events potentially improving management of critically ill patients. Abbreviations: IQR -interquartile range; FiO2 -fraction of inspired oxygen; PaO2partial arterial pressure of oxygen. . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity. (which was not certified by peer review) The copyright holder for this preprint this version posted June 2, 2020. . https://doi.org/10.1101/2020.05.30.20107888 doi: medRxiv preprint Table 2 describes the four models that were used to train and test the ML tool. was admitted and discharged the following day. On day 4, the patient was re-admitted with mild respiratory insufficiency that had a 87.7% probability to experience a respiratory crush in the following 48 hours. . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity. (which was not certified by peer review) The copyright holder for this preprint this version posted June 2, 2020. . https://doi.org/10.1101/2020.05.30.20107888 doi: medRxiv preprint Clinical course and risk factors for mortality of adult inpatients with COVID-19 in Wuhan, China: a retrospective cohort study Coronavirus disease (COVID-19) in a paucisymptomatic patient: epidemiological and clinical challenge in settings with limited community transmission Clinical Characteristics of Coronavirus Disease 2019 in China Intubation and Ventilation amid the COVID-19 Outbreak: Wuhan's Experience Clinical Decision Support in the Era of Artificial Intelligence Artificial intelligence in medicine A machine learning-based model for survival prediction in patients with severe COVID-19 infection. medRxiv Machine Learning , COVID-19 ( 2019-nCoV ), and multi-OMICS Prediction models for diagnosis and prognosis of covid-19 infection: systematic review and critical appraisal National Society of Infectious Diseases' (SIMIT) Guidelines for the managment of COVID-19 infection A Trial of Lopinavir-Ritonavir in Adults Hospitalized with Severe Covid-19 LightGBM: A Highly Efficient Gradient Boosting Decision Tree A Unified Approach to Interpreting Model Predictions Deep learning and artificial intelligence in radiology: Current applications and future directions Diagnostic accuracy of 3D deeplearning-based fully automated estimation of patient-level minimum fractional flow reserve from coronary computed tomography angiography. Eur Hear J -Cardiovasc Imaging Respiratory rate per minute, median (IRQ) PaO2/FiO2, mmHg, median (IRQ) Oxygen saturation, %, median (IRQ) mg/dl We would like to thank to Office of clinical protocols and data management in Modena: This study was not funded. Actual Good Outcome