This issue tracks tasks related to discrete compartmental models. See [design doc](https://docs.google.com/document/d/1FmU3-8uAhUDyBDyD2Hyr69slJfm9x14tQPFto683VSw/edit?usp=sharing) for motivation. ## Modeling - [x] #2410 Initial prototype using HMC + enumeration - [x] #2437 Implement a framework in `pyro.contrib.epidemiology` - [x] #2446 Implement an SEIR model @fritzo - [x] #2450 #2451 Generalize to overdispersed noise via `BetaBinomial` @fritzo - [x] #2457 Handle observations accumulated over an interval - [x] #2460 Allow stochastic init state and start date estimation - [x] #2466 Add a regional model - [x] #2474 Add a `CoalescentTimes` distribution - [x] #2514 Eliminate need for `ComparmentalModel.transition_bwd()` - [x] #2517 Add a model with time-varying global parameters - [x] #2558 ~~#2468~~ Incorporate phylogeny observations into the likelihood (see [OverdispersedSEIRModel](https://github.com/pyro-ppl/pyro/blob/sir-phylogenetic-likelihood/pyro/contrib/epidemiology/seir.py)) - [x] #2558, #2559 Add example of branching flows #2552 - [ ] Add example of causal intervention (ideally [interactive on nbviewer](https://minrk-ipywidgets.readthedocs.io/en/latest/embedding.html#rendering-interactive-widgets-on-nbviewer)) - [ ] Add example of cyclic flows #2552 - [ ] Support enumeration of discrete globals, e.g. to condition on multiple phylogenetic samples ## Inference - [x] #2428 Use block diagonal mass matrix after #2425 is merged - [x] #2429 Fix global parameters that are easy to physically measure - [x] #2430 Try a frequency-smoothed DCT transform @fritzo - [x] #2434 Try larger enumeration windows @martinjankowiak - [x] #2452 Use SMC to generically initialize to a feasible trajectory - [x] #2465 Try structured adaptation matrices in HMC @fehiepsi - [x] #2492 #2493 Try a wavelet transform @martinjankowiak - [x] #2495 Implement a `SplitReparam` to split off low-frequency components of Haar reparams - [x] #2510 #2513 #2522 Try continuous relaxed inference - [x] #2498 Make all `Binomial` distributions overdispersed - [x] #2523 Support Haar reparameterization for non-compartmental time series - [x] #2529 Try SVI on the continuous relaxed model - [ ] Try IWAE with DReG gradients, compare with ELBO (see #2598) - [ ] Try one-step-lookahead SMC - [ ] Try a windowed [modified DCT](https://en.wikipedia.org/wiki/Modified_discrete_cosine_transform) transform ## Engineering - [x] #2431 Fix prediction bug when using `--dct` - [x] #2433 Fix cubic spline weights @martinjankowiak - [x] #2493 Use `.with_cache(1)` in `DiscreteCosineTransform` (see https://github.com/pytorch/pytorch/pull/36882 ) - [ ] Make `SafeLog` jit-script-compatible (see comment in hmm.py) ## Tidying up for first release DONE - [x] #2499 combine sir.py + seir.py -> models.py - [x] #2553 Add a notebook tutorial introducing the module purpose and usage - [x] #2558 ~~#2518~~ Add a notebook tutorial on regional models - [x] #2563 https://github.com/pyro-ppl/sandbox/pull/13 Set good default values for inference
This issue tracks tasks related to discrete compartmental models.
See design doc for motivation.
Modeling
pyro.contrib.epidemiologyBetaBinomial@fritzoCoalescentTimesdistributionComparmentalModel.transition_bwd()Add coalescent likelihoods to contrib.epidemiology #2468Incorporate phylogeny observations into the likelihood (see OverdispersedSEIRModel)Inference
SplitReparamto split off low-frequency components of Haar reparamsBinomialdistributions overdispersedEngineering
--dct.with_cache(1)inDiscreteCosineTransform(see Add a .with_cache() method to distributions.Transform objects pytorch/pytorch#36882 )SafeLogjit-script-compatible (see comment in hmm.py)Tidying up for first release DONE
Add epidemiology tutorial with a regional SEIR model #2518Add a notebook tutorial on regional models