tapios / risk-networks

Code for risk networks: a blend of compartmental models, graphs, data assimilation and semi-supervised learning
Other
2 stars 2 forks source link

Health service #59

Closed odunbar closed 4 years ago

odunbar commented 4 years ago

To resolve #53 This implements a HealthService class that modifies the contact network of a population so that nodes may be identified always with patients in the solvers. It's purpose is to tackle the administration of the networks, so that the KineticModel and the MasterEquations do not have to know about the movements of nodes due to hospitalizations, for example do not require solving extra equations for node categories.

Another benefit is that it works by modification of the edges of a network and not the nodes. Therefore for new contact networks the hospitalization do not perturb any node data or diagram data used by the KineticModel which was missed before (and therefore a bug). The only edge data which needs to be set (very) carefully is the new contact duration weights.

The current implementation still requires an example and testing. hence is WIP, also I had to implement quite a delicate system for weighting due to the contact duration weights, There may be an external solution to the HealthService to tackle this

glwagner commented 4 years ago

What are the specific differences between the way we model contacts between health care workers and hospitalized patients, and in ordinary interactions within the community?

odunbar commented 4 years ago

I have added a simple example to show the health service in action with discharging, admitting, demonstrating the limit capacity and putting people on a waiting list.

I believe it now ready for merge.