emodpy_malaria.interventions.drug_campaign module

This module contains functionality for malaria intervention distribution via a cascade of care that may contain diagnostics and drug treatments.

emodpy_malaria.interventions.drug_campaign.drug_configs_from_code(campaign, drug_code: Optional[str] = None)

Add a single or multiple drug regimen to the configuration file based on its code and add the corresponding AntimalarialDrug intervention to the return dictionary. For example, passing the ALP drug code will add the drug configuration for artemether, lumefantrine, and primaquine to the configuration file and will return a dictionary containing a full treatment course for those three drugs. For more information, see Malaria_Drug_Params in Drugs and treatments.

Parameters
  • campaign – The emod_api.campaign object to which the intervention will be added.

  • drug_code – The code of the drug regimen. This must be listed in the drug_cfg dictionary.

Returns

A dictionary containing the intervention for the given drug regimen.

emodpy_malaria.interventions.drug_campaign.add_drug_campaign(campaign, campaign_type: str = 'MDA', drug_code: Optional[str] = None, start_days: Optional[list] = None, coverage: float = 1.0, repetitions: int = 1, tsteps_btwn_repetitions: int = 60, diagnostic_type: str = 'BLOOD_SMEAR_PARASITES', diagnostic_threshold: float = 40, measurement_sensitivity: float = 0.1, fmda_radius: int = 0, node_selection_type: str = 'DISTANCE_ONLY', trigger_coverage: float = 1.0, snowballs: int = 0, treatment_delay: int = 0, triggered_campaign_delay: int = 0, node_ids: Optional[list] = None, target_group: any = 'Everyone', drug_ineligibility_duration: int = 0, ind_property_restrictions: Optional[list] = None, disqualifying_properties: Optional[list] = None, trigger_condition_list: Optional[list] = None, listening_duration: int = - 1, adherent_drug_configs: Optional[list] = None, target_residents_only: int = 1, check_eligibility_at_trigger: bool = False, receiving_drugs_event_name='Received_Campaign_Drugs')

Add a drug intervention campaign from a list of malaria campaign types. This intervention uses the MalariaDiagnostic class to create either a scheduled or a triggered event to the campaign and the AntimalarialDrug class to configure drug interventions. You can also specify a delay period for a triggered event that broadcasts afterwards. If the campaign is repeated or triggered, separate NodeLevelHealthTriggeredIV interventions are created with a delay that sends an event to distribute drugs.

Parameters
  • campaign – The emod_api.campaign object to which the intervention will be added.

  • campaign_type

    The type of drug campaign. Available options are:

    MDA

    Add a mass drug administration intervention.

    MSAT

    Add a mass screening and treatment intervention.

    SMC

    Add a seasonal malaria chemoprevention intervention.

    fMDA

    Add a focal mass drug administration intervention based on results from a diagnostic survey, which is either scheduled or triggered (when trigger_condition_list is present).

    MTAT

    Add a mass testing and treatment intervention.

    rfMSAT

    Add a reactive focal mass screening and treatment intervention. Detecting malaria triggers diagnostic surveys to run on neighboring nodes and so on, up to the number of triggered interventions defined in the snowballs parameter.

    rfMDA

    Add a reactive focal mass drug administration intervention. This triggers BroadcastEventToOtherNodes to broadcast a “Give_Drugs_rfMDA” event, which triggers MultiInterventionDistributor to distribute drugs and a “ReceivedTreatment” event followed by a delayed “Give_Drugs_rfMDA” event to neighboring nodes, which will trigger another drug distribution.

  • drug_code – The code of the drug regimen to distribute. This must be listed in the drug_cfg dictionary.

  • start_days – List of start days (integers) when the drug regimen will be distributed. Due to diagnostic/treatment configuration, the earliest start day is 1. When trigger_condition_list is used, the first entry of start_days is the day to start listening for the trigger(s).

  • coverage – The demographic coverage of the distribution (the fraction of people at home during the campaign).

  • repetitions – The number of repetitions.

  • tsteps_btwn_repetitions – The timesteps between the repetitions.

  • diagnostic_type – The setting for Diagnostic_Type in MalariaDiagnostic. In addition to the accepted values listed there, you may also set TRUE_INFECTION_STATUS, which calls StandardDiagnostic instead.

  • diagnostic_threshold – The setting for Diagnostic_Threshold in MalariaDiagnostic.

  • measurement_sensitivity – The setting for Measurement_Sensitivity in MalariaDiagnostic.

  • detection_threshold – The setting for Detection_Threshold in MalariaDiagnostic.

  • fmda_radius – Radius (in km) of focal response upon finding infection. Used in simulations with many small nodes to simulate community health workers distributing drugs to surrounding houses. Used when campaign_type is set to fMDA.

  • node_selection_type – The setting for Node_Selection_Type in BroadcastEventToOtherNodes.

  • trigger_coverage – The fraction of trigger events that will trigger reactive case detection (RCD). Used when campaign_type is set to rfMSAT or rfMDA. To set the fraction of individuals reached during RCD response, use coverage.

  • snowballs – The number of times each triggered intervention will be distributed to surrounding nodes. For example, one snowball gives drugs to nodes neighboring the first node and two snowballs gives drugs to the nodes neighboring those nodes. Used when campaign_type is set to rfMSAT.

  • treatment_delay – For campaign_type set to MSAT or fMDA, the length of time between administering a diagnostic and giving drugs; for values of rfMSAT or rfMDA, the length of time between treating the index case and triggering an RCD response.

  • triggered_campaign_delay – When using trigger_condition_list, this indicates the delay period between receiving the trigger event and running the triggered campaign intervention.

  • node_ids – The setting for Node_List in Nodeset_Config classes.

  • target_group – A dictionary of {'agemin': x, 'agemax': y} to target MDA, SMC, MSAT, fMDA to individuals between x and y years of age. Default is Everyone.

  • drug_ineligibility_duration – The number of days to set the DrugStatus individual property to RecentDrug, after which the property value is reverted. This property value prevents people from receiving drugs too frequently, but they can still receive diagnostics during this period. For more information, see Targeting interventions to nodes or individuals.

  • ind_property_restrictions – The setting for Property_Restrictions_Within_Node in TriggeredEventCoordinator that individuals must have to receive the diagnostic intervention.

  • disqualifying_properties – The setting for Disqualifying_Properties in AntimalarialDrug or in MalariaDiagnostic.

  • trigger_condition_list – The setting for Start_Trigger_Condition_List in TriggeredEventCoordinator.

  • listening_duration – The setting for Duration in TriggeredEventCoordinator.

  • adherent_drug_configs – List of adherent drug configurations, which are dictionaries from configure_adherent_drug.

  • target_residents_only – The setting for Target_Residents_Only in TriggeredEventCoordinator.

  • check_eligibility_at_trigger – Set to True to check the individual or node’s eligibility at the initial trigger; set to False to check eligibility when the event is actually distributed after a delay.

  • receiving_drugs_event_name – The event to broadcast when a person receives drugs.

Returns

A dictionary with drug campaign parameters.

emodpy_malaria.interventions.drug_campaign.add_MDA(campaign, start_days: Optional[list] = None, coverage: float = 1.0, drug_configs: Optional[list] = None, receiving_drugs_event: Optional[emod_api.interventions.common.BroadcastEvent] = None, repetitions: int = 1, tsteps_btwn_repetitions: int = 60, node_ids: Optional[list] = None, expire_recent_drugs: Optional[emod_api.interventions.common.PropertyValueChanger] = None, ind_property_restrictions: Optional[list] = None, disqualifying_properties: Optional[list] = None, target_group: any = 'Everyone', trigger_condition_list: Optional[list] = None, listening_duration: int = - 1, triggered_campaign_delay: int = 0, target_residents_only: int = 1, check_eligibility_at_trigger: bool = False)

Add an MDA (mass drug administration) drug intervention to your campaign. See add_drug_campaign() for more information about each argument.

Returns

None

emodpy_malaria.interventions.drug_campaign.add_MSAT(campaign, start_days: Optional[list] = None, coverage: float = 1.0, drug_configs: Optional[list] = None, receiving_drugs_event: Optional[emod_api.interventions.common.BroadcastEvent] = None, repetitions: int = 1, tsteps_btwn_repetitions: int = 60, treatment_delay: int = 0, diagnostic_type: str = 'BLOOD_SMEAR_PARASITES', diagnostic_threshold: float = 40, measurement_sensitivity: float = 0.1, node_ids: Optional[list] = None, expire_recent_drugs: Optional[emod_api.interventions.common.PropertyValueChanger] = None, ind_property_restrictions: Optional[list] = None, disqualifying_properties: Optional[list] = None, target_group: any = 'Everyone', trigger_condition_list: Optional[list] = None, triggered_campaign_delay: int = 0, listening_duration: int = - 1, check_eligibility_at_trigger: bool = False)

Add an MSAT (mass screening and treatment) drug intervention to your campaign. See add_drug_campaign() for more information about each argument.

Returns

None

emodpy_malaria.interventions.drug_campaign.add_fMDA(campaign, start_days: Optional[list] = None, trigger_coverage: float = 1, coverage: float = 1, drug_configs: Optional[list] = None, receiving_drugs_event: Optional[emod_api.interventions.common.BroadcastEvent] = None, repetitions: int = 1, tsteps_btwn_repetitions: int = 365, treatment_delay: int = 0, diagnostic_type: str = 'BLOOD_SMEAR_PARASITES', diagnostic_threshold: float = 40, measurement_sensitivity: float = 0.1, fmda_radius: int = 0, node_selection_type: str = 'DISTANCE_ONLY', node_ids: Optional[list] = None, expire_recent_drugs: Optional[emod_api.interventions.common.PropertyValueChanger] = None, ind_property_restrictions: Optional[list] = None, disqualifying_properties: Optional[list] = None, target_group: any = 'Everyone', trigger_condition_list: Optional[list] = None, listening_duration: int = - 1, triggered_campaign_delay: int = 0, check_eligibility_at_trigger: bool = False)

Add an fMDA (focal mass drug administration) drug intervention to your campaign. See add_drug_campaign() for more information about each argument.

Returns

None

emodpy_malaria.interventions.drug_campaign.add_rfMSAT(campaign, start_day: int = 0, coverage: float = 1, drug_configs: Optional[list] = None, receiving_drugs_event: Optional[emod_api.interventions.common.BroadcastEvent] = None, listening_duration: int = - 1, treatment_delay: int = 0, trigger_coverage: float = 1, diagnostic_type: str = 'BLOOD_SMEAR_PARASITES', diagnostic_threshold: float = 40, measurement_sensitivity: float = 0.1, fmda_radius: int = 0, node_selection_type: str = 'DISTANCE_ONLY', snowballs: int = 0, node_ids: Optional[list] = None, expire_recent_drugs: Optional[emod_api.interventions.common.PropertyValueChanger] = None, ind_property_restrictions: Optional[list] = None, disqualifying_properties: Optional[list] = None)

Add a rfMSAT (reactive focal mass screening and treatment) drug intervention to your campaign. See add_drug_campaign() for more information about each argument.

Returns

None

emodpy_malaria.interventions.drug_campaign.add_rfMDA(campaign, start_day: int = 0, coverage: float = 1, drug_configs: Optional[list] = None, receiving_drugs_event: Optional[emod_api.interventions.common.BroadcastEvent] = None, listening_duration: int = - 1, treatment_delay: int = 0, trigger_coverage: float = 1, fmda_radius: int = 0, node_selection_type: str = 'DISTANCE_ONLY', node_ids: Optional[list] = None, expire_recent_drugs: Optional[emod_api.interventions.common.PropertyValueChanger] = None, ind_property_restrictions: Optional[list] = None, disqualifying_properties: Optional[list] = None)

Add an rfMDA (reactive focal mass drug administration) drug intervention to your campaign. See add_drug_campaign() for more information about each argument.

Returns

None

emodpy_malaria.interventions.drug_campaign.fmda_cfg(campaign, fmda_type: any = 0, node_selection_type: str = 'DISTANCE_ONLY', event_trigger: str = 'Give_Drugs')

Create an fMDA (focal mass drug administration) configuration.

Parameters
Returns

Configured BroadcastEventToOtherNodes intervention.