1. 23 Sep, 2020 1 commit
2. 11 Sep, 2020 1 commit
3. 05 Sep, 2020 1 commit
4. 04 Sep, 2020 1 commit
• Pulled dates out of CovidUKStochastic class · 588d479e
Chris Jewell authored
Changes:

1. Dates are pulled out of CovidUKStochastic
2. CovidUKStochastic now behaves more like a tfd.Distribution
* CovidUKStochastic is now instantiated with an initial time, number of time steps and
time step size
* CovidUKStochastic is now instantiated with the initial state.
5. 30 Aug, 2020 1 commit
• Corrected Add/Delete move bounds. · 71205807
Chris Jewell authored
Consider an SEIR model.  For adding $x \geq 0$ S->E event times we have:
$$S(t+1) &=& S(0) - (N_{se}(t) + x) \geq 0 \\ E(t+1) &=& E(0) + (N_{se}(t) + x) \geq 0$$
such that $x$ is bounded by
$$x \leq S(0) - N_{se}(t).$$

Similarly for adding $x \geq 0$ E->I event times we have:
$$x \leq E(0) + N_{se}(t) - N_{ei}(t).$$

For deleting $x \geq 0$ S->E event times we have:
$$x \leq E(0) + N_{se}(t) - N_{ei}(t)$$
and for E->I event times we have;
$$x \leq I(0) + N_{ei}(t) - N_{ir}(t).$$
6. 28 Aug, 2020 1 commit
7. 26 Aug, 2020 2 commits
• New initialisation method · 0c2498bd
Chris Jewell authored
Changes:

1. Previously, we initialised from the first imputed event at T-s, where s was random due
to the initialisation process;

2. We now calculate the state at time T given s (and the event imputation).
• New initialisation strategy · fe6bf084
Chris Jewell authored
8. 23 Aug, 2020 1 commit
• Corrected data misalignment · 2d0e3f80
Chris Jewell authored
Changes:

1. We adopt the convention [start, end) for *all* date ranges.
2. Modified PHE case ingestor to reflect this
3. Modified CovidUK to reflect this
4. Corrected a bug in the use of time in simulation.
9. 20 Aug, 2020 1 commit
10. 17 Aug, 2020 1 commit
11. 16 Aug, 2020 2 commits
• Modified logp to combine POEs and occults · 2bb80563
Chris Jewell authored
Introduced counting process respecting AddOccultsProposal.  This now check to make sure
we don't invalidate the epidemic by adding too many events.  To achieve this, we combine
occults and POEs into 1 structure.  This has the advantage of requiring less storage, but
is less easy to monitor occults separately from POEs.
• Corrected bug in commute volume handling · b4787e9b
Chris Jewell authored
12. 08 Aug, 2020 1 commit
13. 07 Aug, 2020 2 commits
• Implemented nested Gibbs sampling · b8a89f41
Chris Jewell authored
• Implemented kernel-ised Gibbs sampler · 7adf0699
Chris Jewell authored
Changes:

1. Implemented GibbsStep and GibbsKernel classes
2. Modified mcmc.sample function to use Gibbs sampler
3. Amended bugs in event_time_mh.py and occult_proposal.py (edge cases where tf.gathers
were overshooting the bounds of the data stuctures, not apparent on a GPU but raised on
CPU).
14. 01 Aug, 2020 2 commits
15. 30 Jul, 2020 1 commit
16. 24 Jul, 2020 1 commit
17. 22 Jul, 2020 1 commit
• Implemented LTLA-level COVID-19 model · 68b27bba
Chris Jewell authored
Changes:

1. Replaced 149 UTLAs with 315 LTLAs mixing matrix;
2. Wrote geometric initialisation for censored event times;
3. Modified data ingester to take PHE Anonymised Line Listing data.
18. 09 Jul, 2020 1 commit
19. 08 Jul, 2020 1 commit
Chris Jewell authored
Changes:

1. Added occult Metropolis Hastings update.
2. Factored out Categorical2 distribution for use by both event time move and occults.
3. Refactored mcmc.py script for HDF5 output purposes
4. Apply compression to HDF5 output file.
20. 05 Jul, 2020 3 commits
21. 04 Jul, 2020 2 commits
22. 29 Jun, 2020 1 commit
23. 28 Jun, 2020 3 commits
24. 27 Jun, 2020 2 commits
25. 26 Jun, 2020 2 commits
• Changed storage order of events matrix. · 0291aa34
Chris Jewell authored
Previously, the Events matrix expected by model.log_prob was ordered
[T, M, X] where T is the number of timpoints, M is the number of
meta-populations and X is the number of transitions.  However, it was
found more convenient to work with [M, T, X] for the purposes of data
augmentation.  This meant extra tf.transpose calls.

model.log_prob now expects [M, T, X], with any further batch
dimensions added as outer dimensions.
• Minor formatting changes to mcmc.py · 8f6ef578
Chris Jewell authored
26. 25 Jun, 2020 1 commit
27. 24 Jun, 2020 1 commit
• Changes: · e72cfe76
Chris Jewell authored
1. Formatting -- black style!
2. After profiling, implemented a better workaround for the
tfd.Categorical bug.  Replaced with an inherited Categorical2 class,
3. Fixed a  bug in EventTimeProposal where tfd.FiniteDiscrete was
being used on a non-strictly-increasing outcomes vector.
4. Increased number of meta-populations to 149 to mirror UK UTLA regions.
28. 22 Jun, 2020 1 commit
• Changes: · 705ce40b
Chris Jewell authored
1. Fixed bug in covid.impl.event_time_mh._reverse_move where Multinomial one_hot tensor wasn't being advanced for the reverse move.  This is a temporary workaround while tf.nn.sparse_softmax_cross_entropy_with_logits is fixed.

2. Batched EventTimesProposal to move multiple meta-populations.

3. Batched _move_events to allow for multiple meta-population updates

4. Refactored covid.impl.event_time_proposal._abscumdiff so we calculate bound_times outside the function.  This allows clipping of times proposed outside [0, T] to [0, T], thus avoiding an error in tf.gather_nd in CPU mode.  The output of EventTimesProposal.sample and EventTimesProposal.log_prob might be inconsistent with what we expect, but that's okay as the move gets rejected as an out-of-bounds proposal anyway.
29. 20 Jun, 2020 1 commit