<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>Bayesian LSTM Forecasting of COVID-19 ICU Occupancy With Uncertainty Estimations</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Katarzyna Nieszporek</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Giulia Capecchi</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Maria Grazia Bocci</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Department of Artificial Intelligence, Czestochowa University of Technology</institution>
          ,
          <addr-line>Czestochowa</addr-line>
          ,
          <country country="PL">Poland</country>
        </aff>
        <aff id="aff1">
          <label>1</label>
          <institution>Intensive Care Unit, National Institute for Infectious Diseases “Lazzaro Spallanzani” IRCCS</institution>
          ,
          <addr-line>Rome</addr-line>
          ,
          <country country="IT">Italy</country>
        </aff>
      </contrib-group>
      <fpage>107</fpage>
      <lpage>115</lpage>
      <abstract>
        <p>The COVID-19 pandemic has exposed the fragility of healthcare systems, especially in the management of Intensive Care Unit (ICU) resources. Accurate forecasting of ICU occupancy is essential to support public health decisions and to prevent saturation during epidemic waves. In this work, we propose a predictive model based on Long Short-Term Memory (LSTM) neural networks, combined with Monte Carlo dropout to estimate model uncertainty. This approach allows us to generate probabilistic forecasts of ICU demand, including confidence intervals that help quantify prediction reliability. We apply the model to real-world data from California counties, using historical ICU occupancy records collected during the pandemic. We show that the model can anticipate trends up to several weeks in advance, maintaining good accuracy and consistent uncertainty calibration. To assess robustness, we compare the proposed LSTM model with simpler architectures, including GRU-based and feedforward neural networks, confirming the superior performance of LSTM in capturing complex temporal patterns. Our results highlight the importance of integrating uncertainty estimates into forecasting systems, particularly in high-risk domains such as healthcare. The method is computationally eficient, easy to implement, and adaptable to other time series prediction tasks where uncertainty awareness is required.</p>
      </abstract>
      <kwd-group>
        <kwd>eol&gt;ICU occupancy prediction</kwd>
        <kwd>COVID-19</kwd>
        <kwd>LSTM networks</kwd>
        <kwd>time series forecasting</kwd>
        <kwd>healthcare resource planning</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>1. Introduction</title>
      <p>
        ration, while excessively conservative estimates can lead Several studies have explored the application of
mato the waste of precious resources [
        <xref ref-type="bibr" rid="ref5">15</xref>
        ]. chine learning techniques for forecasting hospital
ad
      </p>
      <p>
        To address this, we adopt the concept of model un- missions, ICU transfers, and mortality risk. These
apcertainty as formulated by Gal and Ghahramani [
        <xref ref-type="bibr" rid="ref6 ref7">16, 17</xref>
        ], proaches typically rely on the analysis of clinical data,
who demonstrated that dropout, typically used for reg- epidemiological curves, and time series models. For
inularization in deep learning, can also be interpreted as stance, Chamola and Sikdar [
        <xref ref-type="bibr" rid="ref12">22</xref>
        ] provided a broad review
an approximate Bayesian inference method. This insight of artificial intelligence methods applied to disaster and
allows us to construct neural models that do not just pandemic management, including early warning systems,
provide point predictions, but also quantify the uncer- resource allocation strategies, and decision support tools.
tainty associated with those predictions. This probabilis- Their work highlights the potential of AI to improve
tic information is crucial in high-stakes contexts, where preparedness and response capacity in large-scale
emerdecisions must often be made even when the available gencies.
data is incomplete or ambiguous [
        <xref ref-type="bibr" rid="ref8">18</xref>
        ]. A specific example of this approach is presented by
      </p>
      <p>
        In this work, we apply this methodology to a Long Cheng et al. [
        <xref ref-type="bibr" rid="ref13">23</xref>
        ], who developed a risk prediction tool
Short-Term Memory (LSTM) network [
        <xref ref-type="bibr" rid="ref9">19</xref>
        ], a class of re- using Random Forests to estimate the probability of ICU
current neural networks particularly suited to model tem- transfer within 24 hours. This tool is based on electronic
poral dependencies in sequential data. These networks health record data and allows physicians to identify
highare able to retain and exploit long-term dependencies risk patients in advance. Similarly, Ruyssinck et al. [
        <xref ref-type="bibr" rid="ref14">24</xref>
        ]
in time series data, making them particularly efective proposed a model for ICU bed prediction using Random
for modeling the evolution of ICU admissions over time Survival Forests. In their study, the Sequential Organ
[
        <xref ref-type="bibr" rid="ref10 ref11">20, 21</xref>
        ]. By applying Monte Carlo (MC) dropout dur- Failure Assessment (SOFA) score was used as a key
ining both training and inference, our model is capable of put, and the model outperformed traditional machine
generating probabilistic forecasts of ICU occupancy that learning methods for survival analysis in critical care.
include confidence intervals, enabling decision-makers Another relevant contribution is the work by Li et al.
to interpret the model outputs with greater caution and [
        <xref ref-type="bibr" rid="ref15">25</xref>
        ], who employed a Deep Neural Network (DNN)
comawareness. bined with a feature selection method (Boruta algorithm)
      </p>
      <p>We test this approach on real-world data concerning to build a risk score for ICU admission and patient
morICU occupancy across counties in California during the tality. Their model showed good performance, especially
COVID-19 pandemic, with the goal of providing a flex- in identifying the most relevant clinical predictors.
ible and interpretable forecasting system. The results Beyond direct ICU prediction, many authors have
proindicate that the model is able to provide meaningful posed machine learning systems designed to detect early
forecasts, even several weeks in advance, and that the warning signals and support preventive decision-making.
uncertainty estimation can serve as a key element in the For instance, studies during the COVID-19 pandemic
process of healthcare planning. In addition to evaluating have explored how to integrate clinical markers with
psyprediction accuracy, we also assess the calibration of the chological, behavioral, and societal factors. A growing
uncertainty estimates, that is, how well the predicted number of works has highlighted the potential of
comconfidence intervals match the true variability of future bining multimodal data, including physiological signals
data. and high-level cognitive features, to support healthcare</p>
      <p>In the following sections, we will review related works response strategies.
(Section 2), present the theoretical foundations of LSTM Notable eforts have also focused on the detection
networks and model uncertainty (Section 3.1), describe and classification of disinformation related to COVID-19,
our proposed model in detail (Section 4), report on exper- which may indirectly afect the behavior of the
popuimental results and model performance (Section 5), and lation and the load on hospital systems. De Magistris
ifnally discuss the implications, limitations, and future et al. [26] proposed an explainable fake news detection
directions of our research (Section 6). system combining named entity recognition and stance
classification, showing that misinformation during a
pandemic can propagate uncertainty and reduce adherence
2. Related Works to preventive measures, thus indirectly afecting hospital
saturation patterns.</p>
      <p>The prediction of ICU occupancy during health emer- Complementary studies explored the psychological
gencies, such as the COVID-19 pandemic, has received and neurocognitive consequences of the pandemic,
esincreasing attention from the scientific community. This pecially in relation to post-COVID stress syndromes. In
interest is motivated by the urgent need to support health- particular, Russo et al. [27] proposed an innovative
apcare systems in optimizing the use of limited resources, proach using remote EMDR therapy to treat
long-COVIDespecially in times of crisis. related traumatic disorders. Such works are relevant
be</p>
    </sec>
    <sec id="sec-2">
      <title>3. Background</title>
      <p>cause they reveal how the pandemic impacted not only
physical but also psychological health, both of which can
influence the demand on healthcare facilities. In this section we present the main theoretical
founda</p>
      <p>From a methodological point of view, advanced clus- tions upon which our work is built. The aim is to provide
tering and statistical learning techniques have been used the conceptual and methodological background needed
to analyze both behavioral data and physiological signals to understand the structure and rationale of the model we
in the context of pandemic-related stress. For example, propose. Forecasting ICU occupancy during a pandemic
Ponzi et al. [28] used Expectation Maximization and presents a unique combination of challenges: on one
Gaussian Mixture Models to investigate the diferences hand, the system evolves over time in a non-linear and
in psychodiagnostic profiles before and after the pan- context-dependent way; on the other hand, any
predicdemic, using Rorschach test data. These types of investi- tive model must be able to represent and communicate its
gations, though not focused directly on ICU occupancy, own uncertainty to support decision-making processes
enrich the broader understanding of pandemic impacts in high-risk environments.
on healthcare systems. To address these requirements, our work is based on</p>
      <p>Moreover, the use of computer vision methods for two fundamental components. The first is the use of
surveillance and prevention has seen widespread exper- Long Short-Term Memory (LSTM) networks, a class of
imentation. De Magistris et al. [29] developed an auto- recurrent neural networks specifically designed to
promatic CNN-based system for face mask detection, tested cess sequential data. LSTMs are particularly well suited
in real-world scenarios during the COVID-19 emergency. to time series forecasting tasks where past values
influMonitoring compliance with mask-wearing policies is ence future observations, even across long temporal gaps.
another aspect that, indirectly, afects the spread of in- Their internal structure allows them to capture
dependenfection and therefore the load on ICU infrastructures. cies over time more efectively than traditional models,</p>
      <p>While these models and applications provide impor- making them ideal for modeling ICU admission patterns,
tant insights, most of them focus on patient-level pre- which often follow delayed and seasonally modulated
diction using static clinical data, or address secondary trends.
aspects related to prevention and communication. In The second key component is the use of Monte Carlo
contrast, our approach focuses on a population-level pre- dropout, a technique that allows us to estimate the
prediction of ICU bed usage, considering temporal dynam- dictive uncertainty of deep learning models in a
comics and variability over time. This aspect is crucial in a putationally eficient way. Instead of relying on fully
pandemic, where the number of new infections and hos- Bayesian neural networks, which are dificult to
implepitalizations can change rapidly due to social behavior, ment and often computationally prohibitive, Monte Carlo
public policies, and virus mutations. dropout enables approximate Bayesian inference through</p>
      <p>
        The closest works to our approach are the studies stochastic forward passes in standard architectures. This
by Gal and Ghahramani [
        <xref ref-type="bibr" rid="ref6 ref7">16, 17</xref>
        ], who introduced the method allows us to associate each forecast with a
conficoncept of model uncertainty in neural networks using dence interval, which is essential in a healthcare context
dropout as a Bayesian approximation. Their framework where predictions cannot be blindly trusted, and caution
allows the estimation of predictive uncertainty without is required in interpreting the results.
requiring a full Bayesian treatment, which would be com- These two elements—temporal modeling through
putationally expensive. This idea is especially valuable LSTM networks and uncertainty estimation through
in the healthcare domain, where making overconfident dropout interpreted in a Bayesian framework—are then
predictions can lead to serious consequences, such as combined in our architecture to construct a robust,
flexiunderestimating ICU demand or delaying interventions. ble, and interpretable forecasting model. The following
      </p>
      <p>Therefore, our work builds upon these contributions subsections describe each component in detail.
by integrating the dropout-as-Bayesian approach with
LSTM networks for time series forecasting. This combi- 3.1. Long Short-Term Memory (LSTM)
nation enables us to provide not only accurate predictions Networks
of ICU occupancy, but also to associate each prediction
with a quantitative measure of uncertainty. This feature LSTM networks are a special type of Recurrent
Neuis fundamental in supporting cautious and informed de- ral Networks (RNNs), specifically designed to handle
cisions in critical contexts such as healthcare planning sequences and temporal dependencies. Traditional RNNs
during a pandemic. sufer from problems such as the vanishing or exploding
gradient, which make it dificult to learn long-term
dependencies in time series. LSTMs solve this limitation
by introducing a more sophisticated memory unit that
includes several internal gates: the input gate, the forget</p>
      <sec id="sec-2-1">
        <title>3.2. Model Uncertainty and Monte Carlo</title>
      </sec>
      <sec id="sec-2-2">
        <title>Dropout</title>
        <p>
          gate, and the output gate [
          <xref ref-type="bibr" rid="ref9">19</xref>
          ]. In our case, this allows us to not only forecast ICU
        </p>
        <p>Each LSTM cell contains a memory unit that can main- bed usage but also to associate each prediction with a
tain information over long periods of time. The input confidence interval. This is particularly useful in guiding
gate controls how much new information is stored, the decisions regarding the allocation of resources, where the
forget gate decides what information to discard, and the cost of a false prediction can be extremely high. Using
output gate determines how much of the memory is ex- dropout in this way enables a form of Bayesian modeling
posed to the next layers of the network. This internal that is computationally eficient and compatible with
mechanism allows LSTMs to learn long-range patterns modern deep learning frameworks.
and to keep important signals in memory while ignoring
irrelevant data.</p>
        <p>Due to these characteristics, LSTM networks are 4. Proposed Model
widely used in many real-world applications involving
sequential data, such as speech recognition, financial
forecasting, and medical monitoring [30]. In our study, we
use a multi-layer LSTM network to model the temporal
evolution of ICU occupancy in diferent regions, allowing
the system to capture the non-linear dependencies and
seasonalities typical of epidemic curves.</p>
        <sec id="sec-2-2-1">
          <title>The core of our approach is the design of a forecasting</title>
          <p>model based on Long Short-Term Memory (LSTM)
networks, enhanced with a method to quantify uncertainty
using Monte Carlo dropout. The goal is to build a
predictive system that can provide both the expected number of
ICU beds occupied in the near future and the associated
confidence intervals. This dual output is essential to
support decision-makers in high-risk and high-variability
environments such as healthcare.
(1)
(2)</p>
        </sec>
        <sec id="sec-2-2-2">
          <title>In traditional machine learning, models produce point</title>
          <p>estimates: they predict a single value for each input.
However, in high-stakes contexts like healthcare, it is essential
not only to predict a value, but also to know how
confident the model is in its prediction. This concept is known
as model uncertainty.</p>
          <p>
            A promising method to estimate uncertainty in neural
networks is the technique proposed by Gal and
Ghahramani [
            <xref ref-type="bibr" rid="ref6 ref7">16, 17</xref>
            ]. They demonstrated that applying dropout
during both training and testing phases can be
interpreted as a form of approximate Bayesian inference. This
allows the model to simulate a posterior distribution over
its weights and produce a distribution of outputs rather
than a single point estimate.
          </p>
          <p>In practice, this approach is implemented using Monte
Carlo dropout (MC dropout). During inference, multiple
stochastic forward passes are executed through the same
network with dropout activated, and the results are
averaged. This procedure generates both the expected output
and a measure of variance, which reflects the model’s
confidence. Formally, if we perform  forward passes,
each with a diferent dropout mask, the predictive mean
is estimated as:
and the predictive variance as:</p>
          <p>E[* ] =</p>
          <p>1 ∑︁ ˆ* ()
 =1
V[* ] =</p>
          <p>1 ∑︁ ˆ* 2() − (E[* ])2
 =1</p>
        </sec>
      </sec>
      <sec id="sec-2-3">
        <title>4.1. Motivation and Design Rationale</title>
        <p>During the pandemic, the evolution of ICU occupancy
followed complex temporal patterns. These patterns are
not only influenced by biological and medical factors (e.g.,
virus spread, severity of cases), but also by non-linear
external factors such as lockdown policies, vaccination
campaigns, or population movements. To capture these
dynamics, it is necessary to adopt a model that is able
to learn temporal dependencies and nonlinearities from
past sequences.</p>
        <p>Moreover, the data used for such predictions are
subject to noise, inconsistencies, and rapid changes in trends.
Hence, our model must also be able to express its own
uncertainty: this means providing not only a prediction, but
also an estimate of how reliable that prediction is. A
decision made on a forecast with high uncertainty should be
treated diferently than one based on a highly confident
output.</p>
      </sec>
      <sec id="sec-2-4">
        <title>4.2. Model Architecture</title>
        <sec id="sec-2-4-1">
          <title>We construct a deep LSTM model consisting of four re</title>
          <p>current layers, each followed by a dropout layer. The
use of stacked LSTM layers allows the model to learn
increasingly abstract temporal patterns, while the dropout
layers serve both as regularization (during training) and
as a Bayesian approximation (during inference).</p>
          <p>Each model takes as input a univariate time series
 representing the number of ICU patients at time .
Optionally, an encoded representation of the county is
also included if multiple counties are modeled together.
The model outputs a prediction ˆ+1, i.e., the estimated</p>
        </sec>
      </sec>
      <sec id="sec-2-5">
        <title>4.4. Monte Carlo Dropout for Uncertainty</title>
      </sec>
      <sec id="sec-2-6">
        <title>Estimation</title>
        <p>
          number of ICU beds that will be occupied in the next counties) either separately or jointly using encoded
identime step. tifiers; it provides interpretable uncertainty estimates
without requiring a full probabilistic model or
compu4.3. Dropout in Recurrent Layers tationally expensive Bayesian methods; it is compatible
with any modern deep learning framework and can be
The novelty of our approach is in the use of **recur- deployed on standard hardware.
rent dropout** with fixed masks, as proposed by Gal In the next section, we describe the experimental
proand Ghahramani [
          <xref ref-type="bibr" rid="ref7">17</xref>
          ]. In contrast to traditional dropout, tocol, including the dataset, the preprocessing steps, and
where diferent neurons are dropped at each time step, the empirical evaluation of our model.
here the same dropout mask is applied consistently across
all time steps for the recurrent weights. This strategy en- 4.6. Theoretical Justification and Bayesian
sures a proper approximation of the variational inference
process in RNNs. Framing
        </p>
        <p>During training, dropout is applied both to input and
recurrent connections. The same is done during
inference, which transforms the deterministic prediction into
a stochastic one. Each forward pass through the network
generates a slightly diferent result, depending on the
random dropout masks.</p>
        <sec id="sec-2-6-1">
          <title>The model presented in this work relies on a theoret</title>
          <p>ical framework that interprets dropout as an
approximation of Bayesian inference. This idea, introduced by
Gal and Ghahramani, allows us to treat standard neural
networks as approximate Bayesian models, without
requiring changes in the model architecture or complex
probabilistic methods.</p>
          <p>In classical Bayesian inference, the goal is to estimate
the posterior distribution of the model parameters given
the observed data. Formally, we aim to compute:</p>
        </sec>
        <sec id="sec-2-6-2">
          <title>To estimate the uncertainty, we use the Monte Carlo (MC)</title>
          <p>dropout method. Specifically, we perform  stochastic
forward passes at test time, each time using a diferent
dropout mask. This process yields a set of predictions
{ˆ(+1)1, ˆ(+2)1, . . . , ˆ(+ )1}.</p>
          <p>From this set, we compute:
• The predictive mean:
• The predictive variance:
¯+1 =</p>
          <p>1 ∑︁ ˆ+1</p>
          <p>()
 =1
V[+1] =</p>
          <p>1 ∑︁ (︁
 =1</p>
          <p>() )︁ 2
ˆ+1
− (¯+1)2
( | ) =
( |  ) · ( )
()</p>
          <p>(3)
where  represents the weights of the model and  is
the training dataset. However, this posterior is typically
intractable in neural networks, due to the high
dimensionality of the parameter space and the non-linear nature of
the model.</p>
          <p>To overcome this dicfiulty, variational inference can
be used. The idea is to approximate the true
posterior distribution ( | ) with a simpler distribution
( ), and to find the parameters of  that minimize
the Kullback-Leibler divergence between  and the true
posterior. This is equivalent to maximizing the evidence
lower bound (ELBO), defined as:</p>
          <p>These statistics allow us to construct prediction
intervals at various confidence levels (e.g., 68%, 95%, 99%). The In the interpretation proposed by Gal, the application
wider the interval, the higher the uncertainty. This is of dropout during training and inference corresponds to
especially important for hospital administrators: a sharp sampling from a variational distribution ( ), where
increase in uncertainty may signal unusual trends, re- the weights are randomly masked by a binary matrix
quiring increased attention or human intervention. drawn from a Bernoulli distribution. Specifically, each
weight matrix is redefined as:
ℒ = E( )[log ( |  )] −</p>
          <p>KL(( )‖( )) (4)</p>
        </sec>
      </sec>
      <sec id="sec-2-7">
        <title>4.5. Advantages of the Proposed</title>
      </sec>
      <sec id="sec-2-8">
        <title>Architecture</title>
        <sec id="sec-2-8-1">
          <title>The model we propose ofers several advantages: it is based on well-established deep learning techniques (LSTM, dropout), but reinterpreted in a Bayesian framework; it can handle multiple time series (e.g., diferent</title>
          <p>=  · diag(),  ∼</p>
        </sec>
        <sec id="sec-2-8-2">
          <title>Bernoulli()</title>
          <p>(5)</p>
        </sec>
        <sec id="sec-2-8-3">
          <title>This formulation allows the use of dropout not only as</title>
          <p>a regularization method, but as a way to simulate
multiple network configurations drawn from the approximate
posterior distribution. Each stochastic forward pass
corresponds to a sample from the variational approximation.</p>
          <p>The predictive distribution for a new input * is ob- 5.2. Time Series Preprocessing
tained by marginalizing over the weight distribution:
(* | * , ) =
∫︁
(* | * ,  ) · ( ) 
(6)</p>
        </sec>
        <sec id="sec-2-8-4">
          <title>Since this integral cannot be computed analytically, it</title>
          <p>is estimated by Monte Carlo sampling. In practice, we
perform multiple forward passes through the network
using diferent dropout masks and compute the empirical
mean and variance of the predictions:
E[* ] ≈</p>
          <p>1 ∑︁ ˆ* ,
 =1</p>
          <p>Var[* ] ≈</p>
          <p>1 ∑︁ (ˆ* )2− (E[* ])2
 =1</p>
          <p>Since our objective is to predict ICU occupancy over time,
we treated each county’s record as a univariate time
series. The raw data are noisy and afected by local
fluctuations (e.g., reporting delays, corrections). Therefore, we
applied the following preprocessing steps:</p>
          <p>1. Missing Data Handling: Missing values were
interpolated using a linear method, as long as the
proportion of missing points was below 10% in a time series.</p>
          <p>Counties with too many missing values were excluded.</p>
          <p>2. Normalization: To make the training process more
stable, we scaled the data. Two scaling strategies were
used: Standard Scaler: applied to grouped counties (mean
0, standard deviation 1); MinMax Scaler: applied to
singlecounty models, with upper bound equal to the mean ICU
occupancy mean (rather than 1), to reduce saturation
efects.</p>
          <p>3. Sliding Window: To generate training sequences,
we applied a sliding window of fixed size  = 14 days.</p>
          <p>Each input sample is a sequence of ICU values over 14
days, and the target is the ICU value on the 15th day.</p>
          <p>(7)</p>
          <p>This approach makes it possible to estimate the
epistemic uncertainty of the model without requiring the
use of fully Bayesian neural networks, which are often
dificult to implement and computationally expensive.</p>
          <p>In summary, the Bayesian interpretation of dropout
provides a principled way to incorporate model
uncertainty into deep learning. This is particularly important
in healthcare applications, where decisions based on pre- 5.3. Grouping Similar Counties
dictions must also take into account the confidence in
those predictions. By applying Monte Carlo dropout, To avoid building a separate model for each county, we
our model can ofer both the expected evolution of ICU explored the possibility of grouping counties with similar
occupancy and a reliable measure of its own uncertainty. ICU occupancy profiles. We applied the Dynamic Time
Warping (DTW) algorithm to compute pairwise distances
between the normalized time series. Counties with low
5. Experiments DTW distance were grouped together, resulting in six
distinct clusters.</p>
          <p>In this section, we describe the experimental framework This grouping reduces the number of models to be
used to validate our approach. We first present the dataset trained. and improves model generalization by sharing
and the criteria adopted for its selection. Then we ex- statistical patterns across counties with similar epidemic
plain the preprocessing operations necessary to train the curves.
model. Finally, we report the training strategies and the
performance metrics used to evaluate both accuracy and 5.4. Dropout Rate Tuning
uncertainty.</p>
        </sec>
        <sec id="sec-2-8-5">
          <title>We empirically evaluated several values of dropout prob</title>
          <p>5.1. Dataset Description ability  in the range [0.05, 0.3]. We observed that lower
dropout rates (e.g.,  = 0.08) yield more stable
predicWe used an open-access dataset provided by the Cali- tions, especially when training on small datasets. Higher
fornia Department of Public Health (CDPH) [31]. The dropout values resulted in wider uncertainty bands, but
dataset includes daily data on the COVID-19 pandemic sometimes degraded the mean prediction.
collected at the county level, covering the period from This analysis confirmed the need to carefully tune
March 2020 to May 2021. Specifically, we focused on the dropout rates when using MC dropout for uncertainty
number of ICU beds occupied by confirmed COVID-19 estimation.
patients in each county.</p>
          <p>The dataset includes measurements for 58 counties. 5.5. Monte Carlo Estimation
However, not all of them have complete or stable records.</p>
          <p>To ensure data reliability, we performed a quality control At test time, we performed  = 1000 stochastic forward
phase and excluded counties with excessive missing val- passes through the trained model. For each input
winues or inconsistent time series. The final dataset included dow, we obtained the predictive mean ¯ as the average
36 counties, which represent a good balance between
geographic coverage and data quality.</p>
          <p>with  = 1, 1.96, 2.58</p>
        </sec>
        <sec id="sec-2-8-6">
          <title>This allowed us to associate each forecast with a visual band representing the model’s confidence.</title>
        </sec>
      </sec>
      <sec id="sec-2-9">
        <title>5.6. Evaluation Metrics</title>
        <sec id="sec-2-9-1">
          <title>We evaluated model performance using two Root Mean</title>
          <p>Square Error (RMSE): to assess the accuracy of point
forecasts
⎯</p>
          <p>RMSE = ⎷⎸⎸ 1 ∑︁( − ˆ)2
=1
Moreover we also used Calibration of Uncertainty as
the percentage of true values falling within the predicted
95% confidence interval.</p>
          <p>Across all counties, the average RMSE was 1.7 on the
training set and 3.0 on the test set, confirming the model’s
ability to generalize across time.</p>
          <p>These results demonstrate the model’s ability to
produce reliable and interpretable forecasts, even several
weeks ahead. The use of uncertainty estimates increases
trustworthiness and allows for more cautious resource
planning.</p>
        </sec>
      </sec>
      <sec id="sec-2-10">
        <title>5.7. Comparison with Alternative</title>
      </sec>
      <sec id="sec-2-11">
        <title>Architectures</title>
        <p>To better assess the efectiveness of the proposed
LSTMbased model with Monte Carlo dropout, we conducted a
comparative study with two alternative neural
architectures. The objective was to evaluate the importance of
temporal memory, recurrent structure, and uncertainty
estimation by analyzing models with diferent levels of
complexity and expressiveness.
5.7.1. GRU-based model
95% C.I.
94.1%
91.3%
88.6%
Model
LSTM + MC Dropout
GRU + MC Dropout
Feedforward + MC Dropout
5.7.2. Feedforward model with sliding window</p>
        <sec id="sec-2-11-1">
          <title>As a baseline, we tested a simple feedforward neural net</title>
          <p>work with no recurrent connections. The input to the
network was a fixed-size sliding window of the
previous 14 days of ICU occupancy, and the output was the
prediction for the following day.</p>
          <p>This model was also trained with dropout, and
uncertainty estimation was performed using Monte Carlo
sampling. Despite its simplicity, the feedforward model
performed reasonably well on counties with very regular
trends. However, it failed to capture long-term
dependencies and reacted poorly to abrupt changes, such as
second-wave peaks.
5.7.3. Performance comparison</p>
        </sec>
        <sec id="sec-2-11-2">
          <title>The table below summarizes the performance of the three</title>
          <p>models in terms of Root Mean Square Error (RMSE) and
confidence interval calibration, defined as the percentage
of true values falling within the 95% confidence band.</p>
          <p>The results show that the LSTM model achieves the
best accuracy and the most reliable uncertainty
quantification. The GRU model ofers a good trade-of between
speed and precision, but sufers slightly in unstable or
noisy series. The feedforward model is clearly less
capable in capturing temporal patterns, but still provides
reasonable performance in regular conditions.</p>
          <p>These findings support the adoption of LSTM networks
when forecasting complex time series in healthcare
contexts, especially when the time horizon is long and the
dynamics are non-linear. While simpler models may be
suficient for low-variability environments, they do not
generalize well to unseen epidemic behaviors.</p>
          <p>In addition, the LSTM model showed more stable
uncertainty calibration, with narrower but better-aligned
confidence intervals. This is important in critical settings,
where over- or under-confidence
of outputs, the standard deviation   as a measure of un- Table 1
certainty, and the confidence intervals at 68%, 95%, and Comparison of model performance
99% using standard Gaussian quantiles:</p>
        </sec>
        <sec id="sec-2-11-3">
          <title>Gated Recurrent Units (GRUs) are a simplified variant of</title>
          <p>LSTM networks. They have fewer parameters and use
only two gates: an update gate and a reset gate. The
reduced complexity makes GRUs faster to train, especially
when computational resources are limited. 6. Conclusion</p>
          <p>In our experiments, we implemented a GRU model
with the same structure as the LSTM model (four recur- The work presented in this article proposes a
forecastrent layers), applying Monte Carlo dropout in the same ing method for ICU occupancy based on a combination
way. The performance was slightly lower than the LSTM of recurrent neural networks and approximate Bayesian
model, particularly in time series with strong seasonality inference techniques. By integrating Long Short-Term
or abrupt changes. However, training time was reduced Memory (LSTM) models with Monte Carlo dropout, we
by approximately 30%. were able to develop a system that does not limit itself
to generating single-point predictions, but also estimates healthcare systems more resilient. In scenarios
characthe uncertainty associated with each forecast. This ap- terized by volatility and risk, the ability to predict with
proach represents a step forward in the context of health- caution and to quantify doubt becomes just as important
care, where decision-making often takes place under time as the ability to predict with precision.
pressure, with incomplete information and high social
responsibility.</p>
          <p>Through the analysis of data collected in California 7. Declaration on Generative AI
during the COVID-19 pandemic, we observed that the
proposed model is capable of maintaining stable perfor- During the preparation of this work, the authors used
mance across counties with diferent demographic and ChatGPT, Grammarly in order to: Grammar and spelling
epidemiological characteristics. The inclusion of uncer- check, Paraphrase and reword. After using this
tool/sertainty estimation allowed us to associate confidence in- vice, the authors reviewed and edited the content as
tervals with each prediction, ofering health managers needed and take full responsibility for the publication’s
and decision-makers an additional layer of interpretabil- content.
ity and caution. This feature is especially important in
a context where underestimating the future demand for References
critical care resources can lead to saturation and systemic
failures, while overestimating it can cause ineficient al- [1] A. Remuzzi, G. Remuzzi, Covid-19 and italy: what
location. next?, The Lancet 395 (2020) 1225–1228.</p>
          <p>However, some limitations must be acknowledged. [2] M. L. Ranney, V. Grifeth, A. K. Jha, Critical
supThe data used for training and evaluation cover only ply shortages—the need for ventilators and
perthe initial phase of the pandemic, limiting the model’s sonal protective equipment during the covid-19
ability to learn from multiple waves or long-term sea- pandemic, New England Journal of Medicine 382
sonal patterns. Moreover, our model operates at the level (2020) e41.
of aggregated time series, without incorporating indi- [3] G. Grasselli, A. Zangrillo, A. Zanella, et al.,
Basevidual clinical features that could enrich the prediction line characteristics and outcomes of 1591 patients
with information about the severity or progression of infected with sars-cov-2 admitted to icus of the
lompatients’ conditions. This restricts the system’s ability to bardy region, italy, JAMA 323 (2020) 1574–1581.
adapt its forecasts to variations in population risk or to [4] L. Jiang, et al., Occupancy and ventilator use of
the evolution of treatment protocols. A further limitation intensive care units in new york state during the
concerns the spatial resolution of the dataset. Although covid-19 pandemic, JAMA 324 (2020) 835–837.
county-level data are useful for regional planning, they [5] J. T. Wu, K. Leung, G. M. Leung, Nowcasting and
are not always suficient to guide decisions at the hospi- forecasting the potential domestic and international
tal level, where operational constraints and patient flow spread of the 2019-ncov outbreak originating in
dynamics are far more detailed and localized. wuhan, china: a modelling study, The Lancet 395</p>
          <p>In future developments, it would be desirable to inte- (2020) 689–697.
grate clinical variables directly into the time series mod- [6] A. J. Kucharski, T. W. Russell, C. Diamond, et al.,
eling process, in order to capture not only the epidemio- Early dynamics of transmission and control of
logical evolution of the virus, but also the specific char- covid-19: a mathematical modelling study, The
acteristics of the population afected. Furthermore, the Lancet Infectious Diseases 20 (2020) 553–558.
model could be extended beyond COVID-19, adapting it [7] C. Krubiner, R. Faden, Covid-19 vaccine
trito other types of health emergencies that generate sudden als should seek worthwhile health gains for
lowincreases in ICU demand, such as influenza epidemics or income countries, The Lancet 396 (2020) 741–743.
extreme climatic events. Another direction could concern [8] R. C. Maves, et al., Crisis standards of care: Lessons
the introduction of spatial correlations between diferent from new york city hospitals during the covid-19
geographic units, which would make it possible to simu- pandemic, Health Security 18 (2020) 447–452.
late the redistribution of patients between hospitals or [9] L. Rosenbaum, Facing covid-19 in italy — ethics,
regions in case of local overload. Finally, the creation of logistics, and therapeutics on the epidemic’s front
an interactive forecasting tool, accessible in real time to line, New England Journal of Medicine 382 (2020)
public health authorities, could transform this model into 1873–1875.
an operational resource capable of supporting decision- [10] S. L. Barber, et al., Covid-19 pandemic planning:
making processes directly in the field. considerations for state and territorial health
ofi</p>
          <p>The results of this study confirm that deep learning cials, Journal of Public Health Management and
methods, when equipped with mechanisms for uncer- Practice 26 (2020) E16–E20.
tainty estimation, can contribute concretely to making</p>
        </sec>
      </sec>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          [11]
          <string-name>
            <given-names>E.</given-names>
            <surname>Marseille</surname>
          </string-name>
          , et al.,
          <article-title>Cost-efectiveness of intensive 19 patients using clinical variables</article-title>
          ,
          <source>PeerJ</source>
          <volume>8</volume>
          (
          <year>2020</year>
          )
          <article-title>care for hospitalized covid-19 patients: experience e10337. from new york city</article-title>
          ,
          <source>BMC Health Services Research</source>
          [26]
          <string-name>
            <surname>G. De Magistris</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          <string-name>
            <surname>Russo</surname>
          </string-name>
          , P. Roma, J. T. Starczewski,
          <volume>21</volume>
          (
          <year>2021</year>
          )
          <fpage>1</fpage>
          -
          <lpage>9</lpage>
          .
          <string-name>
            <given-names>C.</given-names>
            <surname>Napoli</surname>
          </string-name>
          ,
          <article-title>An explainable fake news detector based</article-title>
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          [12]
          <string-name>
            <given-names>M.</given-names>
            <surname>Chinazzi</surname>
          </string-name>
          , et al.,
          <article-title>The efect of travel restrictions on named entity recognition and stance classificaon the spread of the 2019 novel coronavirus (covid- tion applied to covid-19, Information (Switzerland) 19) outbreak</article-title>
          ,
          <source>Science</source>
          <volume>368</volume>
          (
          <year>2020</year>
          )
          <fpage>395</fpage>
          -
          <lpage>400</lpage>
          . 13 (
          <year>2022</year>
          ). doi:
          <volume>10</volume>
          .3390/info13030137.
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          [13]
          <string-name>
            <given-names>G.</given-names>
            <surname>Giordano</surname>
          </string-name>
          , et al.,
          <source>Modelling the covid-19 epidemic</source>
          [27]
          <string-name>
            <given-names>S.</given-names>
            <surname>Russo</surname>
          </string-name>
          ,
          <string-name>
            <given-names>F.</given-names>
            <surname>Fiani</surname>
          </string-name>
          ,
          <string-name>
            <given-names>C.</given-names>
            <surname>Napoli</surname>
          </string-name>
          ,
          <article-title>Remote eye movement and implementation of population-wide interven- desensitization and reprocessing treatment of longtions in italy</article-title>
          ,
          <source>Nature Medicine</source>
          <volume>26</volume>
          (
          <year>2020</year>
          )
          <fpage>855</fpage>
          -
          <lpage>860</lpage>
          . covid
          <article-title>- and post-covid-related traumatic disorders:</article-title>
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          [14]
          <string-name>
            <given-names>M.</given-names>
            <surname>Abdar</surname>
          </string-name>
          , et al.,
          <article-title>A review of uncertainty quantifica- An innovative approach</article-title>
          ,
          <source>Brain Sciences</source>
          <volume>14</volume>
          (
          <year>2024</year>
          ).
          <article-title>tion in deep learning: Techniques, applications</article-title>
          and doi:10.3390/brainsci14121212. challenges,
          <source>Information Fusion</source>
          <volume>76</volume>
          (
          <year>2021</year>
          )
          <fpage>243</fpage>
          -
          <lpage>297</lpage>
          . [28]
          <string-name>
            <given-names>V.</given-names>
            <surname>Ponzi</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Russo</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Wajda</surname>
          </string-name>
          ,
          <string-name>
            <given-names>R.</given-names>
            <surname>Brociek</surname>
          </string-name>
          , C. Napoli,
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          [15]
          <string-name>
            <given-names>A.</given-names>
            <surname>Ghosh</surname>
          </string-name>
          , et al.,
          <article-title>Impact of covid-19 pandemic on Analysis pre and post covid-19 pandemic rorschach healthcare system and socio-economic structure test data of using em algorithms and gmm modof india</article-title>
          ,
          <source>Sustainable Cities and Society</source>
          <volume>64</volume>
          (
          <year>2021</year>
          )
          <article-title>els</article-title>
          , in
          <source>: CEUR Workshop Proceedings</source>
          , volume
          <volume>3360</volume>
          ,
          <fpage>102601</fpage>
          .
          <year>2022</year>
          , pp.
          <fpage>55</fpage>
          -
          <lpage>63</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          [16]
          <string-name>
            <given-names>Y.</given-names>
            <surname>Gal</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Z.</given-names>
            <surname>Ghahramani</surname>
          </string-name>
          ,
          <article-title>Dropout as a bayesian ap-</article-title>
          [29]
          <string-name>
            <surname>G. De Magistris</surname>
            , E. Iacobelli,
            <given-names>R.</given-names>
          </string-name>
          <string-name>
            <surname>Brociek</surname>
            ,
            <given-names>C.</given-names>
          </string-name>
          <article-title>Napoli, proximation: Representing model uncertainty in An automatic cnn-based face mask detection algodeep learning</article-title>
          , in: international conference on ma
          <article-title>- rithm tested during the covid-19 pandemics, in: chine learning</article-title>
          ,
          <source>PMLR</source>
          ,
          <year>2016</year>
          , pp.
          <fpage>1050</fpage>
          -
          <lpage>1059</lpage>
          . CEUR Workshop Proceedings, volume
          <volume>3398</volume>
          ,
          <year>2022</year>
          ,
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          [17]
          <string-name>
            <given-names>Y.</given-names>
            <surname>Gal</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Z.</given-names>
            <surname>Ghahramani</surname>
          </string-name>
          , A theoretically grounded pp.
          <fpage>36</fpage>
          -
          <lpage>41</lpage>
          .
          <article-title>application of dropout in recurrent neural networks</article-title>
          , [30]
          <string-name>
            <given-names>A.</given-names>
            <surname>Graves</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Schmidhuber</surname>
          </string-name>
          ,
          <article-title>Framewise phoneme Advances in neural information processing systems classification with bidirectional lstm and other neu29 (</article-title>
          <year>2016</year>
          )
          <fpage>1019</fpage>
          -
          <lpage>1027</lpage>
          . ral network architectures,
          <source>Neural Networks 18</source>
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          [18]
          <string-name>
            <given-names>A.</given-names>
            <surname>Kendall</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Y.</given-names>
            <surname>Gal</surname>
          </string-name>
          ,
          <article-title>What uncertainties do we need (</article-title>
          <year>2005</year>
          )
          <fpage>602</fpage>
          -
          <lpage>610</lpage>
          .
          <article-title>in bayesian deep learning for computer vision</article-title>
          ?, Ad- [31] California Department of Public Health, Covid-19
          <source>vances in Neural Information Processing Systems hospital data</source>
          ,
          <year>2020</year>
          . URL: https://data.chhs.ca.
          <source>gov/ 30</source>
          (
          <year>2017</year>
          ). dataset/covid-19
          <string-name>
            <surname>-</surname>
          </string-name>
          hospital-data.
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          [19]
          <string-name>
            <given-names>S.</given-names>
            <surname>Hochreiter</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Schmidhuber</surname>
          </string-name>
          ,
          <article-title>Long short-term memory</article-title>
          ,
          <source>Neural Computation</source>
          <volume>9</volume>
          (
          <year>1997</year>
          )
          <fpage>1735</fpage>
          -
          <lpage>1780</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          [20]
          <string-name>
            <given-names>B.</given-names>
            <surname>Lim</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Zohren</surname>
          </string-name>
          ,
          <article-title>Time-series forecasting with deep learning: a survey</article-title>
          ,
          <source>Philosophical Transactions of the Royal Society A</source>
          <volume>379</volume>
          (
          <year>2021</year>
          )
          <fpage>20200209</fpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref11">
        <mixed-citation>
          [21]
          <string-name>
            <given-names>K.</given-names>
            <surname>Bandara</surname>
          </string-name>
          ,
          <string-name>
            <given-names>C.</given-names>
            <surname>Bergmeir</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Smyl</surname>
          </string-name>
          ,
          <article-title>Forecasting time series with lstm: A review</article-title>
          ,
          <source>International Journal of Forecasting</source>
          (
          <year>2020</year>
          ).
        </mixed-citation>
      </ref>
      <ref id="ref12">
        <mixed-citation>
          [22]
          <string-name>
            <given-names>V.</given-names>
            <surname>Chamola</surname>
          </string-name>
          ,
          <string-name>
            <given-names>V.</given-names>
            <surname>Hassija</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Gupta</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Goyal</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Guizani</surname>
          </string-name>
          ,
          <string-name>
            <given-names>B.</given-names>
            <surname>Sikdar</surname>
          </string-name>
          ,
          <article-title>Disaster and pandemic management using machine learning: A survey</article-title>
          ,
          <source>IEEE Internet of Things Journal</source>
          (
          <year>2020</year>
          ).
        </mixed-citation>
      </ref>
      <ref id="ref13">
        <mixed-citation>
          [23] F.-Y. Cheng, H. Joshi,
          <string-name>
            <given-names>P.</given-names>
            <surname>Tandon</surname>
          </string-name>
          ,
          <string-name>
            <given-names>R.</given-names>
            <surname>Freeman</surname>
          </string-name>
          , D. L. Reich, M. Mazumdar,
          <string-name>
            <given-names>R.</given-names>
            <surname>Kohli-Seth</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Levin</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Timsina</surname>
          </string-name>
          ,
          <string-name>
            <surname>A. Kia,</surname>
          </string-name>
          <article-title>Using machine learning to predict icu transfer in hospitalized covid-19 patients</article-title>
          ,
          <source>Journal of clinical medicine 9</source>
          (
          <year>2020</year>
          )
          <fpage>1668</fpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref14">
        <mixed-citation>
          [24]
          <string-name>
            <given-names>J.</given-names>
            <surname>Ruyssinck</surname>
          </string-name>
          ,
          <string-name>
            <surname>J. van der Herten</surname>
          </string-name>
          ,
          <string-name>
            <given-names>R.</given-names>
            <surname>Houthooft</surname>
          </string-name>
          ,
          <string-name>
            <given-names>F.</given-names>
            <surname>Ongenae</surname>
          </string-name>
          ,
          <string-name>
            <given-names>I.</given-names>
            <surname>Couckuyt</surname>
          </string-name>
          ,
          <string-name>
            <given-names>B.</given-names>
            <surname>Gadeyne</surname>
          </string-name>
          ,
          <string-name>
            <given-names>K.</given-names>
            <surname>Colpaert</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Decruyenaere</surname>
          </string-name>
          , F. De Turck, T. Dhaene,
          <article-title>Random survival forests for predicting the bed occupancy in the intensive care unit</article-title>
          ,
          <source>Computational and mathematical methods in medicine 2016</source>
          (
          <year>2016</year>
          ).
        </mixed-citation>
      </ref>
      <ref id="ref15">
        <mixed-citation>
          [25]
          <string-name>
            <given-names>X.</given-names>
            <surname>Li</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Ge</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Zhu</surname>
          </string-name>
          ,
          <string-name>
            <given-names>H.</given-names>
            <surname>Li</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Graham</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Singer</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P. S.</given-names>
            <surname>Richman</surname>
          </string-name>
          ,
          <string-name>
            <given-names>T. Q.</given-names>
            <surname>Duong</surname>
          </string-name>
          ,
          <article-title>Deep learning prediction of likelihood of icu admission and mortality in covid-</article-title>
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>