https://github.com/benmaier/epicommute

Simulate an epidemic metapopulation model with mobility-reducing containment strategies

https://github.com/benmaier/epicommute

Science Score: 10.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
  • .zenodo.json file
  • DOI references
  • Academic publication links
    Links to: arxiv.org
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (10.6%) to scientific vocabulary
Last synced: 10 months ago · JSON representation

Repository

Simulate an epidemic metapopulation model with mobility-reducing containment strategies

Basic Info
  • Host: GitHub
  • Owner: benmaier
  • License: mit
  • Language: Python
  • Default Branch: master
  • Size: 421 KB
Statistics
  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • Open Issues: 0
  • Releases: 0
Fork of franksh/EpiCommute
Created almost 6 years ago · Last pushed almost 6 years ago

https://github.com/benmaier/EpiCommute/blob/master/

# EpiCommute

Simulate an epidemic on a metapopulation network with commuter-type mobility,
and potential mobility-reducing containment strategies.

The model is used and defined in the following publication:

> "COVID-19 lockdown induces structural changes in mobility networks -- Implication for mitigating disease dynamics",
> Frank Schlosser, Benjamin F. Maier, David Hinrichs, Adrian Zachariae, Dirk Brockmann,
> ([https://arxiv.org/abs/2007.01583](https://arxiv.org/abs/2007.01583))

## Install

```bash
python setup.py install
```

## Usage example

```python
>>> import numpy as np
>>> from EpiCommute import SIRModel
>>> # Create dummy data
>>> M = 10 # Number of subpopulations
>>> mobility = np.random.rand(M, M) # mobility matrix
>>> subpopulation_sizes = np.random.randint(20,100,M) # subpop.-sizes
>>> # Run simulation
>>> model = SIRModel(mobility, subpopulation_sizes)
>>> results = model.run_simulation(VERBOSE=True)
Starting Simulation ...
Simulation completed
Time: 0min 3.35s
```

More examples are given in the notebooks at `/examples`.

## Model description

The code simulates an SIR epidemic on a subpopulation network,
where subpopulations are connected by commuter-type mobility.

A detailed descriptions of the model is given in the mauscript linked above.

### Mobility

Movement of individuals between subpopulation is implemented using
commuter-type dynamics. This means that each individual lives at a home location
`i`, and works at a work location `j`.

How the individuals are distributed among the compartments is determined
by an origin-destination mobility matrix `mobility` of size `M x M`,
which contains the number of individuals commuting between pairs of locations.

The population in the system is then distributed into `M x M` compartments,
where compartment `ij` includes those individuals living at `i`
and working at `j`.

### Infection dynamics

Epidemic spread is simulated using the SIR model, consisting of susceptibles S,
infecteds I and recovereds R.

The infection step is subdivided in two phases of equal length:

- In the `home` phase, each individual has a chance to get infected at their home location i.
- In the `work` phase, infections can take place at the work locations.

### Containment/lockdown effects

The model can consider changes in absolute mobility flux (for example
due to lockdown effects). For this, it is a assumed that a matrix
`mobility` is provided with the current (possibly reduced) number
of commuters, and a matrix `mobility_baseline` with the number of commuters during normal times.

Changes in mobility flux are taken into account in two different scenarios:

- In the `isolation` scenario, it is assumed that a reduction in mobility
  means that individuals are effectively removed from the system.
- In the `distancing` scenario, a reduction in mobility instead leads
  to a reduction in the effective transmission rate in the system.

A more detailed description of the scenarios and the model can be found in the publication.

Owner

  • Name: Benjamin F. Maier
  • Login: benmaier
  • Kind: user
  • Location: Copenhagen
  • Company: Technical University of Denmark

Postdoc @suneman 's, generative art, electronic music. DTU Compute & SODAS.

GitHub Events

Total
Last Year