Seq2Seq Surrogates of Epidemic Models to Facilitate Bayesian Inference

Giovanni Charles, Timothy M Wolock, Peter Winskill, Azra C. Ghani, Samir Bhatt, Seth Flaxman

Abstract: Epidemic models are powerful tools in understanding infectious disease. However, as they increase in size and complexity, they can quickly become computationally intractable. Recent progress in modelling methodology has shown that surrogate models can be used to emulate complex epidemic models with a high-dimensional parameter space. We show that deep sequence-to-sequence (seq2seq) models can serve as accurate surrogates for complex epidemic models with sequence based model parameters, effectively replicating seasonal and long-term transmission dynamics. Once trained, our surrogate can predict scenarios a several thousand times faster than the original model, making them ideal for policy exploration. We demonstrate that replacing a traditional epidemic model with a learned simulator facilitates robust Bayesian inference.

Introduction

Epidemiologists rely on complex simulations, such as Individual-Based Models (IBMs), to predict infectious disease spread and evaluate interventions like insecticide-treated bed nets. However, these models are computationally intensive; a single malaria simulation can take several minutes. This creates a significant bottleneck for Bayesian inference, where algorithms like Hamiltonian Monte Carlo (HMC) require thousands of model evaluations to estimate unknown parameters from real-world data. Traditional surrogate models often fail to capture the seasonal fluctuations and time-varying interventions inherent in epidemic dynamics.

Methodology

The researchers developed a deep learning surrogate model using a Sequence-to-Sequence (Seq2Seq) Recurrent Neural Network (RNN) architecture. Unlike static surrogates, this LSTM-based model accepts a sequence of inputs—such as annual bed net usage over 16 years—and produces a corresponding sequence of daily malaria prevalence.

The surrogate model accurately replicates the complex seasonal and long-term trends of the IBM across diverse scenarios.

The surrogate was trained on 10,000 IBM simulations generated via Latin Hypercube Sampling, covering a 28-dimensional parameter space including mosquito species, climate, and human demography. Once trained, the neural network acts as a differentiable proxy for the expensive IBM, allowing it to be integrated into Bayesian frameworks like TensorFlow Probability for rapid HMC-based inference.

Key Results

The Seq2Seq surrogate achieved a remarkable 25,000-fold speedup for batch predictions. While the original IBM required 24 hours to process 10,000 samples, the surrogate completed the same task in just 3 seconds. Quantitatively, the model demonstrated high precision with a Mean Squared Error (MSE) as low as 0.0007. Performance remained robust even when generalizing to 30-year horizons (the "long" dataset) and real-world historical intervention statistics (the "historic" dataset).

Scatter plots showing the high correlation between surrogate predictions and IBM ground truth for both long-term and historical datasets.

Furthermore, the surrogate enabled full Bayesian parameter estimation for a site in Senegal in just 11 minutes on a standard 8-core CPU—a task that would be computationally prohibitive using the original IBM.

Discussion and Future Work

By capturing the "memory" of the system, the Seq2Seq architecture effectively models how current interventions influence future disease prevalence. This approach democratizes high-level epidemiological modeling by allowing complex simulations to run on standard hardware without supercomputing clusters.

However, some limitations remain. The model shows slightly reduced accuracy in very low-prevalence scenarios. Future work will explore increasing temporal granularity (e.g., monthly intervals) and incorporating probabilistic RNNs for better uncertainty quantification. Expanding the surrogate to include additional interventions like vaccines or indoor residual spraying will also be a priority.

Summary updated

Abstract

Epidemic models are powerful tools in understanding infectious disease. However, as they increase in size and complexity, they can quickly become computationally intractable. Recent progress in modelling methodology has shown that surrogate models can be used to emulate complex epidemic models with a high-dimensional parameter space. We show that deep sequence-to-sequence (seq2seq) models can serve as accurate surrogates for complex epidemic models with sequence based model parameters, effectively replicating seasonal and long-term transmission dynamics. Once trained, our surrogate can predict scenarios a several thousand times faster than the original model, making them ideal for policy exploration. We demonstrate that replacing a traditional epidemic model with a learned simulator facilitates robust Bayesian inference.
BibTeX
@inproceedings{charles2023seq,
  author = {Giovanni Charles and Timothy M Wolock and Peter Winskill and Azra C. Ghani and Samir Bhatt and Seth Flaxman},
  title = {{Seq2Seq Surrogates of Epidemic Models to Facilitate Bayesian Inference}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2023},
  url = {https://openreview.net/forum?id=e2hIkAsxNo},
}
Figure