tlo.methods.malaria module¶
this is the malaria module which assigns malaria infections to the population: asymptomatic, clinical and severe it also holds the hsi events pertaining to malaria testing and treatment including the malaria RDT using DxTest
- class Malaria(name=None, resourcefilepath=None)[source]¶
Bases:
tlo.core.Module
PARAMETERS:
Item
Type
Description
mal_inc
REAL
monthly incidence of malaria in all ages
interv
REAL
data frame of intervention coverage by year
clin_inc
REAL
data frame of clinical incidence by age, district, intervention coverage
inf_inc
REAL
data frame of infection incidence by age, district, intervention coverage
sev_inc
REAL
data frame of severe case incidence by age, district, intervention coverage
itn_district
REAL
data frame of ITN usage rates by district
irs_district
REAL
data frame of IRS usage rates by district
sev_symp_prob
REAL
probabilities of each symptom for severe malaria cases
sensitivity_rdt
REAL
Sensitivity of rdt
cfr
REAL
case-fatality rate for severe malaria
dur_asym
REAL
duration (days) of asymptomatic malaria
dur_clin
REAL
duration (days) of clinical symptoms of malaria
dur_clin_para
REAL
duration (days) of parasitaemia for clinical malaria cases
rr_hiv
REAL
relative risk of clinical malaria if hiv-positive
treatment_adjustment
REAL
probability of death from severe malaria if on treatment
p_sev_anaemia_preg
REAL
probability of severe anaemia in pregnant women with clinical malaria
itn_proj
REAL
coverage of ITN for projections 2020 onwards
mortality_adjust
REAL
adjustment of case-fatality rate to match WHO/MAP
data_end
REAL
final year of ICL malaria model outputs, after 2018 = projections
irs_rates_boundary
REAL
threshold for indoor residual spraying coverage
irs_rates_upper
REAL
indoor residual spraying high coverage
irs_rates_lower
REAL
indoor residual spraying low coverage
testing_adj
REAL
adjusted testing rates to match rdt/tx levels
itn
REAL
projected future itn coverage
PROPERTIES:
Item
Type
Description
ma_is_infected
BOOL
Current status of malaria
ma_date_infected
DATE
Date of latest infection
ma_date_symptoms
DATE
Date of symptom start for clinical infection
ma_date_death
DATE
Date of death due to malaria
ma_tx
BOOL
Currently on anti-malarial treatment
ma_date_tx
DATE
Date treatment started for most recent malaria episode
ma_inf_type
CATEGORICAL
specific symptoms with malaria infection. Possible values are: [none, asym, clinical, severe, ]
ma_age_edited
REAL
age values redefined to match with malaria data
ma_clinical_counter
INT
annual counter for malaria clinical episodes
ma_tx_counter
INT
annual counter for malaria treatment episodes
ma_clinical_preg_counter
INT
annual counter for malaria clinical episodes in pregnant women
ma_iptp
BOOL
if woman has IPTp in current pregnancy
Class attributes:
CAUSES_OF_DEATH : {‘Malaria’: <tlo.methods.causes.Cause object at 0x7febf1f10760>}
CAUSES_OF_DISABILITY : {‘Malaria’: <tlo.methods.causes.Cause object at 0x7febf1f107f0>}
INIT_DEPENDENCIES : {‘Contraception’, ‘HealthSystem’, ‘SymptomManager’, ‘Demography’}
METADATA : {<Metadata.USES_SYMPTOMMANAGER: 2>, <Metadata.USES_HEALTHBURDEN: 4>, <Metadata.USES_HEALTHSYSTEM: 3>, <Metadata.DISEASE_MODULE: 1>}
OPTIONAL_INIT_DEPENDENCIES : {‘HealthBurden’}
Functions (defined or overridden in class Malaria):
- __init__(name=None, resourcefilepath=None)[source]¶
Create instance of Malaria module
- Parameters
name – Name of this module (optional, defaults to name of class)
resourcefilepath – Path to the TLOmodel resources directory
- read_parameters(data_folder)[source]¶
Read parameter values from file, if required.
Must be implemented by subclasses.
- Parameters
data_folder – path of a folder supplied to the Simulation containing data files. Typically modules would read a particular file within here.
- initialise_population(population)[source]¶
Set our property values for the initial population.
Must be implemented by subclasses.
This method is called by the simulation when creating the initial population, and is responsible for assigning initial values, for every individual, of those properties ‘owned’ by this module, i.e. those declared in its PROPERTIES dictionary.
TODO: We probably need to declare somehow which properties we ‘read’ here, so the simulation knows what order to initialise modules in!
- Parameters
population – the population of individuals
- initialise_simulation(sim)[source]¶
Schedule the Main Regular Polling Events
Define the DxTests
Look-up and save the codes for consumables
- on_birth(mother_id, child_id)[source]¶
Initialise our properties for a newborn individual.
Must be implemented by subclasses.
This is called by the simulation whenever a new person is born.
- Parameters
mother – the mother for this child (can be -1 if the mother is not identified).
child – the new child
- on_hsi_alert(person_id, treatment_id)[source]¶
This is called whenever there is an HSI event commissioned by one of the other disease modules.
- clinical_symptoms(population, clinical_index)[source]¶
assign clinical symptoms to new clinical malaria cases and schedule symptom resolution
- Parameters
population –
clinical_index –
- severe_symptoms(population, severe_index, child=False)[source]¶
assign clinical symptoms to new severe malaria cases. Symptoms can only be resolved by treatment handles both adult and child (using the child parameter) symptoms
- Parameters
population – the population dataframe
severe_index – the indices of new clinical cases
child – to apply severe symptoms to children (otherwise applied to adults)
- class MalariaPollingEventDistrict(module)[source]¶
Bases:
tlo.events.RegularEvent
,tlo.events.Event
,tlo.events.PopulationScopeEventMixin
Functions (defined or overridden in class MalariaPollingEventDistrict):
- class MalariaScheduleTesting(module)[source]¶
additional malaria testing happening outside the symptom-driven generic HSI event to increase tx coverage up to reported levels
Bases:
tlo.events.RegularEvent
,tlo.events.Event
,tlo.events.PopulationScopeEventMixin
Functions (defined or overridden in class MalariaScheduleTesting):
- class MalariaIPTp(module)[source]¶
malaria prophylaxis for pregnant women
Bases:
tlo.events.RegularEvent
,tlo.events.Event
,tlo.events.PopulationScopeEventMixin
Functions (defined or overridden in class MalariaIPTp):
- class MalariaDeathEvent(module, individual_id, cause)[source]¶
Performs the Death operation on an individual and logs it.
Bases:
tlo.events.Event
,tlo.events.IndividualScopeEventMixin
Functions (defined or overridden in class MalariaDeathEvent):
- __init__(module, individual_id, cause)[source]¶
Create a new event.
Note that just creating an event does not schedule it to happen; that must be done by calling Simulation.schedule_event.
- Parameters
module – the module that created this event. All subclasses of Event take this as the first argument in their constructor, but may also take further keyword arguments.
priority – a keyword-argument to set the priority (see Priority enum)
- class HSI_Malaria_rdt(module, person_id)[source]¶
this is a point-of-care malaria rapid diagnostic test, with results within 2 minutes
Bases:
tlo.methods.healthsystem.HSI_Event
,tlo.events.IndividualScopeEventMixin
Functions (defined or overridden in class HSI_Malaria_rdt):
- __init__(module, person_id)[source]¶
Create a new event.
Note that just creating an event does not schedule it to happen; that must be done by calling Simulation.schedule_event.
- Parameters
module – the module that created this event. All subclasses of Event take this as the first argument in their constructor, but may also take further keyword arguments.
- class HSI_Malaria_non_complicated_treatment_age0_5(module, person_id)[source]¶
this is anti-malarial treatment for children <15 kg. Includes treatment plus one rdt
Bases:
tlo.methods.healthsystem.HSI_Event
,tlo.events.IndividualScopeEventMixin
Functions (defined or overridden in class HSI_Malaria_non_complicated_treatment_age0_5):
- __init__(module, person_id)[source]¶
Create a new event.
Note that just creating an event does not schedule it to happen; that must be done by calling Simulation.schedule_event.
- Parameters
module – the module that created this event. All subclasses of Event take this as the first argument in their constructor, but may also take further keyword arguments.
- class HSI_Malaria_non_complicated_treatment_age5_15(module, person_id)[source]¶
this is anti-malarial treatment for children >15 kg. Includes treatment plus one rdt
Bases:
tlo.methods.healthsystem.HSI_Event
,tlo.events.IndividualScopeEventMixin
Functions (defined or overridden in class HSI_Malaria_non_complicated_treatment_age5_15):
- __init__(module, person_id)[source]¶
Create a new event.
Note that just creating an event does not schedule it to happen; that must be done by calling Simulation.schedule_event.
- Parameters
module – the module that created this event. All subclasses of Event take this as the first argument in their constructor, but may also take further keyword arguments.
- class HSI_Malaria_non_complicated_treatment_adult(module, person_id)[source]¶
this is anti-malarial treatment for adults. Includes treatment plus one rdt
Bases:
tlo.methods.healthsystem.HSI_Event
,tlo.events.IndividualScopeEventMixin
Functions (defined or overridden in class HSI_Malaria_non_complicated_treatment_adult):
- __init__(module, person_id)[source]¶
Create a new event.
Note that just creating an event does not schedule it to happen; that must be done by calling Simulation.schedule_event.
- Parameters
module – the module that created this event. All subclasses of Event take this as the first argument in their constructor, but may also take further keyword arguments.
- class HSI_Malaria_complicated_treatment_child(module, person_id)[source]¶
this is anti-malarial treatment for complicated malaria in children
Bases:
tlo.methods.healthsystem.HSI_Event
,tlo.events.IndividualScopeEventMixin
Functions (defined or overridden in class HSI_Malaria_complicated_treatment_child):
- __init__(module, person_id)[source]¶
Create a new event.
Note that just creating an event does not schedule it to happen; that must be done by calling Simulation.schedule_event.
- Parameters
module – the module that created this event. All subclasses of Event take this as the first argument in their constructor, but may also take further keyword arguments.
- class HSI_Malaria_complicated_treatment_adult(module, person_id)[source]¶
this is anti-malarial treatment for complicated malaria in adults
Bases:
tlo.methods.healthsystem.HSI_Event
,tlo.events.IndividualScopeEventMixin
Functions (defined or overridden in class HSI_Malaria_complicated_treatment_adult):
- __init__(module, person_id)[source]¶
Create a new event.
Note that just creating an event does not schedule it to happen; that must be done by calling Simulation.schedule_event.
- Parameters
module – the module that created this event. All subclasses of Event take this as the first argument in their constructor, but may also take further keyword arguments.
- class HSI_MalariaIPTp(module, person_id)[source]¶
this is IPTp for pregnant women
Bases:
tlo.methods.healthsystem.HSI_Event
,tlo.events.IndividualScopeEventMixin
Functions (defined or overridden in class HSI_MalariaIPTp):
- __init__(module, person_id)[source]¶
Create a new event.
Note that just creating an event does not schedule it to happen; that must be done by calling Simulation.schedule_event.
- Parameters
module – the module that created this event. All subclasses of Event take this as the first argument in their constructor, but may also take further keyword arguments.
- class MalariaCureEvent(module)[source]¶
Bases:
tlo.events.RegularEvent
,tlo.events.Event
,tlo.events.PopulationScopeEventMixin
Functions (defined or overridden in class MalariaCureEvent):
- class MalariaParasiteClearanceEvent(module)[source]¶
Bases:
tlo.events.RegularEvent
,tlo.events.Event
,tlo.events.PopulationScopeEventMixin
Functions (defined or overridden in class MalariaParasiteClearanceEvent):
- class MalariaLoggingEvent(module)[source]¶
Bases:
tlo.events.RegularEvent
,tlo.events.Event
,tlo.events.PopulationScopeEventMixin
Functions (defined or overridden in class MalariaLoggingEvent):
- class MalariaTxLoggingEvent(module)[source]¶
Bases:
tlo.events.RegularEvent
,tlo.events.Event
,tlo.events.PopulationScopeEventMixin
Functions (defined or overridden in class MalariaTxLoggingEvent):
- class MalariaPrevDistrictLoggingEvent(module)[source]¶
Bases:
tlo.events.RegularEvent
,tlo.events.Event
,tlo.events.PopulationScopeEventMixin
Functions (defined or overridden in class MalariaPrevDistrictLoggingEvent):
- class MalariaResetCounterEvent(module)[source]¶
Bases:
tlo.events.RegularEvent
,tlo.events.Event
,tlo.events.PopulationScopeEventMixin
Functions (defined or overridden in class MalariaResetCounterEvent):