Metadata-Version: 2.1
Name: summerepi2
Version: 1.3.6
Summary: Summer is a compartmental disease modelling framework, written in Python. It provides a high-level API to build and run models.
Home-page: https://github.com/monash-emu/summer2
License: BSD-2-Clause
Keywords: epidemiology,disease,compartmental,infectious
Author: David Shipman
Author-email: dshipman@gmail.com
Requires-Python: >=3.10.0
Classifier: License :: OSI Approved :: BSD License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Provides-Extra: docs
Requires-Dist: computegraph (==0.4.5)
Requires-Dist: ipykernel (>=6.15.1,<7.0.0) ; extra == "docs"
Requires-Dist: jax (>=0.4.24)
Requires-Dist: jaxlib (>=0.4.24)
Requires-Dist: matplotlib (>=3.4.3) ; extra == "docs"
Requires-Dist: nbsphinx (>=0.8.2,<0.9.0) ; extra == "docs"
Requires-Dist: networkx (>=2.6.2)
Requires-Dist: numpy (>=1.20.3)
Requires-Dist: pandas (>=1.3.2)
Requires-Dist: plotly (>=5.5.0)
Requires-Dist: pygraphviz (>=1.10,<2.0) ; extra == "docs"
Requires-Dist: recommonmark (>=0.7.1,<0.8.0) ; extra == "docs"
Requires-Dist: sphinx-rtd-theme (>=0.5.1,<0.6.0) ; extra == "docs"
Requires-Dist: sphinxcontrib-napoleon (>=0.7,<0.8) ; extra == "docs"
Project-URL: Documentation, https://summer2.readthedocs.io/en/latest/
Project-URL: Repository, https://github.com/monash-emu/summer2
Description-Content-Type: text/markdown

# summer2: compartmental disease modelling in Python

[![Automated Tests](https://github.com/monash-emu/summer2/actions/workflows/tests.yml/badge.svg)](https://github.com/monash-emu/summer2/actions/workflows/tests.yml)

summer2 is a Python-based framework for the creation and execution of [compartmental](https://en.wikipedia.org/wiki/Compartmental_models_in_epidemiology) (or "state-based") epidemiological models of infectious disease transmission.

It provides a range of structures for easily implementing compartmental models, including structure for some of the most common features added to basic compartmental frameworks, including:

- A variety of inter-compartmental flows (infections, transitions, births, deaths, imports)
- Force of infection multipliers (frequency, density)
- Post-processing of compartment sizes into derived outputs
- Stratification of compartments, including:
  - Adjustments to flow rates based on strata
  - Adjustments to infectiousness based on strata
  - Heterogeneous mixing between strata
  - Multiple disease strains

Some helpful links to learn more:

- **[Documentation](https://summer2.readthedocs.io/)** with [code examples](https://summer2.readthedocs.io/en/latest/examples/index.html)
- [Available on PyPi](https://pypi.org/project/summerepi2/) as `summerepi2`.

## Installation and Quickstart

This project requires at least Python 3.10

Set up and activate an appropriate virtual environment, then install the `summerepi2` package from PyPI

```bash
pip install summerepi2
```

You can now use the library to build and run models. See [here](https://summer2.readthedocs.io/en/latest/examples/index.html) for some code examples.

## Optional (recommended) extras

Summer has advanced interactive plotting tools built in - but they are greatly improved with the
addition of the pygraphviz library.

If you are using conda, the simplest method of installation is as follows:

```bash
conda install --channel conda-forge pygraphviz
```

For other install methods, see
https://pygraphviz.github.io/documentation/stable/install.html

## Development

[Poetry](https://python-poetry.org/) is used for packaging and dependency management.

## Releases

Releases are numbered using [Semantic Versioning](https://semver.org/)

- 1.0.0/1:
  - Initial release
- 1.2.1
  - Dropped support for Python 3.7.  Variety of bugfixes and expanded features, see documentation
- 1.2.2
  - Added capture utils
  - Removed inner jit in model building to improve debugging
- 1.2.4
  - CompartmentValues not functioning previously; include more comprehensive check in graph split
- 1.2.5
  - Previous issue was not resolved correctly; bugfix-bugfix release
- 1.2.6
  - Make full (comparment) outputs optional for jax runners
- 1.2.8
  - Improve time varying functions (allow GraphObjects in x values)
- 1.2.9
  - Derived output functions matching pandas.Series functionality (rolling, diff)
- 1.3.0
  - Support initializing whole population via GraphObject
- 1.3.1
  - Enforce jax minimum version in requirements
- 1.3.2
  - Fix parameter bug in test models
- 1.3.3
  - Fix issue with binary search for piecewise functions
- 1.3.4
  - Update import in ode.py for changed jax API
- 1.3.5
  - Force specific jax (0.4.24) to stop breaking changes

