BDI-pathogens / OpenABM-Covid19

OpenABM-Covid19: an agent-based model for modelling the spread of SARS-CoV-2 (coronavirus) and control interventions for the Covid-19 epidemic
GNU General Public License v3.0
111 stars 76 forks source link

Performance upgrades #202

Closed roberthinch closed 3 years ago

roberthinch commented 3 years ago

Performance improvements:

  1. Speed-up (x2) interaction building by changing the way interaction tokens are re-used
  2. Memory reduction by 35% when running with a single day of interactions stored (int->short)
  3. Add option to only rebuild networks on parameter change (x20 speed-up)

Add first cut of multi-region meta-model (stand-alone Python class)

Clean up warnings generated by tests (explicit casting when updating an enumerated parameter via the Python interface)

roberthinch commented 3 years ago

I wonder if we need to document the qualitative impacts of not rebuilding the network?

There is clearly a piece of work to investigate this in detail. A very quick simulation shows that it reduces R by about 20% and increases k by about 20%, which is probably what you would expect intuitively. However, I'm not sure whether this is the place to document such studies.