The Covid-19 outbreak has greatly changed our lives, and authorities worldwide are using public health measures, such as lockdowns and enforcing mask use, to try to mitigate the pandemic. In recent months, these measures have increasingly been enacted in local areas, to limit the negative side effects in communities where the spread is limited. Many of these decisions are guided by the outcomes of observations, as well as so-called Susceptible-Exposed-Infectious-Recovered (SEIR) models that operate on a national level.
At Brunel and within the HiDALGO project, we developed the Flu And Coronavirus Simulator (FACS)to try and support the NHS and others in understanding the viral spread. FACS is an open source simulation tool that models the spread in local areas, to supplement e.g. CovidSimand many other codes that work on a more national level.
The Flu And Coronavirus Simulator Software
We started working on FACS during the March lockdown, loosely derived from concepts we used in the Flee migration modelling code. FACS has been open development from the start, and we frequently provide justifications for algorithmic changes either directly in the code or as part of raised GitHub Issues. The code is young and rapidly developed, which both has advantages (for what it covers it’s relatively small, simple and easy to modify) and disadvantages (it’s more prone to have mistakes and is less polished than many older codes).
FACS uses OpenStreetMap data to extract buildings and residential areas within the region, and places agents in households throughout the borough, and adds in other locations such as supermarkets, leisure facilities, hospitals and schools (see image). It also uses an agent-based modelling algorithm where each person is first represented as an agent with a home in the borough, and with certain needs. For instance, an agent may want to shop at a supermarket for one hour per week or to reside in the office for 30 hours per week.
Every day, the code then randomly books visits for these agents to nearby locations, based on their needs. Once all the visits for a given day are booked, FACS then uses an equation to determine how likely it is that infectious visitors in that location are going to infect susceptible ones. A first version of the equation is in the paper, but we actually managed to discover a better equation during a recent scientific group discussion.
Any good simulation study of Covid-19 spread should include runs with differing assumptions and possible scenarios. To facilitate this for FACS, we developed a plugin for the FabSim3 tool, named FabCovid19. We used FabCovid19 to easily run different scenarios for different boroughs with one-liner bash commands, and we are also currently using it to investigate how sensitive our forecasts are to some of our main assumptions.
Using FACS, we can estimate the spread of infections and hospital arrivals for different scenarios, such as when authorities decide to close schools locally or when they require people to wear masks. At the time of writing we have trialled the model for eight different boroughs in London, and though not all models are realistic yet we do see an overarching trend of the recent versions of the code producing a second wave of Covid-19 infections which hits somewhat more gradually than the first one (assuming no additional public health interventions are imposed).
We made FACS available under a BSD 3-clause license, and at time of writing we are reusing the code to model Covid-19 spread in Madrid, and a research group at NUST in Pakistan is reusing the code to build a model for Islamabad.