Skip to content

Add seir vaccination example#353

Open
BittuAgarwal1237 wants to merge 7 commits intomesa:mainfrom
BittuAgarwal1237:add-seir-vaccination-example
Open

Add seir vaccination example#353
BittuAgarwal1237 wants to merge 7 commits intomesa:mainfrom
BittuAgarwal1237:add-seir-vaccination-example

Conversation

@BittuAgarwal1237
Copy link

Summary

Adds a SEIR epidemic model with a government vaccination policy meta-agent.

Motive

There's no population-level epidemic spreading example in mesa-examples. The existing virus_antibody model works at the biological/cellular level, but nothing shows how a disease spreads through a population on a grid and how a policy intervention affects that. This fills that gap.

Implementation

PersonAgents move through four states --Susceptible, Exposed, Infected, Recovered, based on contact with infected neighbors. A GovernmentAgent monitors the infection rate each step and triggers vaccination campaigns when it crosses a threshold, directly moving some susceptible people to recovered. Activation is explicit and bottom-up: people act first, then the government responds. No legacy schedulers used.

Usage Examples

pip install mesa[rec]
python -m solara run app.py

Sliders let you adjust transmission rate, incubation period, infection duration, vaccination threshold, and campaign size. The grid shows agent states in color and two charts track SEIR curves and when vaccination campaigns are active.

@jackiekazil @tpike3 @EwoutH
Screenshot 2026-03-03 175709

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant