Skip to content

node_intervention

BroadcastCoordinatorEventFromNode

Bases: NodeIntervention

The BroadcastCoordinatorEventFromNode is a node-level intervention that broadcasts an event for coordinators. For example, if a death occurs in a node, an event can be broadcasted that will trigger some sort of response by the healthcare system. NodeLevelHealthTriggeredIV could be used to listen for the death of an individual and distribute this intervention to the node. The node intervention could then broadcast its event that another coordinator is listening for. One can use ReportCoordinatorEventRecorder to report on the events broadcasted by this intervention. Note, this coordinator class must be used with listeners that are operating on the same core. For more information, see Simulation core components.

Parameters:

Name Type Description Default
campaign (campaign, required)

An instance of the emod_api.campaign module.

required
broadcast_event (str, required)

The Coordinator Event to be broadcast by this node. An Event Coordinator could be activated from this event. Default value: None

required
common_intervention_parameters CommonInterventionParameters

The CommonInterventionParameters object that contains the 4 common parameters: disqualifying_properties, dont_allow_duplicates, intervention_name, new_property_value. The following parameters are not valid for this intervention: cost Default value: None

None
Source code in emodpy/campaign/node_intervention.py
class BroadcastCoordinatorEventFromNode(NodeIntervention):
    """
    The **BroadcastCoordinatorEventFromNode** is a node-level intervention that broadcasts an event for coordinators.
    For example, if a death occurs in a node, an event can be broadcasted that will trigger some sort of response
    by the healthcare system. **NodeLevelHealthTriggeredIV** could be used to listen for the death of an individual
    and distribute this intervention to the node. The node intervention could then broadcast its event that another
    coordinator is listening for. One can use [ReportCoordinatorEventRecorder][emodpy.reporters.common.ReportCoordinatorEventRecorder] to report
    on the events broadcasted by this intervention. Note, this coordinator class must be used with listeners that
    are operating on the same core. For more information, see Simulation core components.

    Args:
        campaign (api_campaign, required):
            An instance of the emod_api.campaign module.

        broadcast_event(str, required):
            The Coordinator Event to be broadcast by this node. An Event Coordinator could be activated from
            this event.
            Default value: None

        common_intervention_parameters (CommonInterventionParameters, optional):
            The CommonInterventionParameters object that contains the 4 common
            parameters: disqualifying_properties, dont_allow_duplicates, intervention_name, new_property_value.
            The following parameters are not valid for this intervention:
            cost
            Default value: None
    """

    def __init__(self,
                 campaign: api_campaign,
                 broadcast_event: str,
                 common_intervention_parameters: CommonInterventionParameters = None):
        super().__init__(campaign, 'BroadcastCoordinatorEventFromNode', common_intervention_parameters)

        self._intervention.Broadcast_Event = campaign.set_broadcast_coordinator_event(broadcast_event)

    def _set_cost(self, cost: float) -> None:
        raise ValueError('Cost_To_Consumer is not a valid parameter for the BroadcastCoordinatorEventFromNode intervention.')

BroadcastNodeEvent

Bases: NodeIntervention

The BroadcastNodeEvent node intervention class broadcasts node-level events. This can be used with the campaign class, SurveillanceEventCoordinator, that can monitor and listen for events received from BroadcastNodeEvent and then perform an action based on the broadcasted event. You can also use this for the reporting, by recording broadcasted events with ReportNodeEventRecorder or ReportSurveillanceEventRecorder. You must use this intervention with listeners that are operating on the same core. You can also use NLHTIVNode. For more information, see Simulation core components.

Parameters:

Name Type Description Default
campaign (campaign, required)

An instance of the emod_api.campaign module.

required
broadcast_event (str, required)

The name of the Node Event to broadcast. Default value: None

required
common_intervention_parameters CommonInterventionParameters

The CommonInterventionParameters object that contains the 5 common parameters: intervention_name, new_property_value, disqualifying_properties, dont_allow_duplicates, cost. Default value: None

None
Source code in emodpy/campaign/node_intervention.py
class BroadcastNodeEvent(NodeIntervention):
    """
    The **BroadcastNodeEvent** node intervention class broadcasts node-level events. This can be used with the campaign
    class, **SurveillanceEventCoordinator**, that can monitor and listen for events received from
    **BroadcastNodeEvent** and then perform an action based on the broadcasted event. You can also use this for
    the reporting, by recording broadcasted events with [ReportNodeEventRecorder][emodpy.reporters.common.ReportNodeEventRecorder] or
    [ReportSurveillanceEventRecorder][emodpy.reporters.common.ReportSurveillanceEventRecorder].
    You must use this intervention with listeners that are operating on the same core. You can
    also use **NLHTIVNode**. For more information, see Simulation core components.

    Args:
        campaign (api_campaign, required):
            An instance of the emod_api.campaign module.

        broadcast_event(str, required):
            The name of the Node Event to broadcast.
            Default value: None

        common_intervention_parameters (CommonInterventionParameters, optional):
            The CommonInterventionParameters object that contains the 5 common
            parameters: intervention_name, new_property_value, disqualifying_properties, dont_allow_duplicates, cost.
            Default value: None
    """

    def __init__(self,
                 campaign: api_campaign,
                 broadcast_event: str,
                 common_intervention_parameters: CommonInterventionParameters = None):
        super().__init__(campaign, 'BroadcastNodeEvent', common_intervention_parameters)

        if not broadcast_event or not isinstance(broadcast_event, str):
            raise ValueError("broadcast_event must be a non-empty string.")
        self._intervention.Broadcast_Event = campaign.set_broadcast_node_event(broadcast_event)

ImportPressure

Bases: NodeIntervention

The ImportPressure intervention class extends the ImportCases outbreak event. Rather than importing a deterministic number of cases on a scheduled day, ImportPressure applies a set of per-day rates of importation of infected individuals, over a corresponding set of durations. ImportPressure inherits from Outbreak; the Antigen and Genome parameters are defined as they are for all Outbreak events.

WARNING

Be careful when configuring import pressure in multi-node simulations. Daily_Import_Pressures defines a rate of per-day importation for each node that the intervention is distributed to. In a 10 node simulation with Daily_Import_Pressures = [0.1, 5.0], the total importation rate summed over all nodes will be 1/day and 50/day during the two time periods. You must divide the per-day importation rates by the number of nodes.

Parameters:

Name Type Description Default
campaign (campaign, required)

An instance of the emod_api.campaign module.

required
durations (list[int], required)

The durations over which to apply import pressure. Must be a non-empty list and must have the same length as daily_import_pressures.

required
daily_import_pressures (list[float], required)

The rate of per-day importation for each node that the intervention is distributed to. Must be a non-empty list and must have the same length as durations.

required
import_age float

The age (in days) of infected import cases. Minimum value: 0 Maximum value: 43800 Default value: 365

365
genome int

The genetic substrain ID of the outbreak infection. Together with Antigen, they are a unitary object representing a strain of infection, which allows for differentiation among infections. Minimum value: -1 Maximum value: 16777200.0 Default value: 0

0
antigen int

The antigenic base strain ID of the outbreak infection. Minimum value: 0 Maximum value: 10 Default value: 0

0
Source code in emodpy/campaign/node_intervention.py
class ImportPressure(NodeIntervention):
    """
    The **ImportPressure** intervention class extends the **ImportCases** outbreak event. Rather than importing
    a deterministic number of cases on a scheduled day, **ImportPressure** applies a set of per-day rates of
    importation of infected individuals, over a corresponding set of durations. **ImportPressure** inherits
    from **Outbreak**; the **Antigen** and **Genome** parameters are defined as they are for all Outbreak events.

    **WARNING**

    Be careful when configuring import pressure in multi-node simulations. **Daily_Import_Pressures** defines a
    rate of per-day importation for each node that the intervention is distributed to. In a 10 node simulation
    with **Daily_Import_Pressures** = [0.1, 5.0], the total importation rate summed over all nodes will be 1/day
    and 50/day during the two time periods. You must divide the per-day importation rates by the number of nodes.

    Args:
        campaign (api_campaign, required):
            An instance of the emod_api.campaign module.

        durations(list[int], required):
            The durations over which to apply import pressure. Must be a non-empty list and
            must have the same length as **daily_import_pressures**.

        daily_import_pressures(list[float], required):
            The rate of per-day importation for each node that the intervention is distributed to.
            Must be a non-empty list and must have the same length as **durations**.

        import_age(float, optional):
            The age (in days) of infected import cases.
            Minimum value: 0
            Maximum value: 43800
            Default value: 365

        genome(int, optional):
            The genetic substrain ID of the outbreak infection. Together with **Antigen**, they are a unitary
            object representing a strain of infection, which allows for differentiation among infections.
            Minimum value: -1
            Maximum value: 16777200.0
            Default value: 0

        antigen(int, optional):
            The antigenic base strain ID of the outbreak infection.
            Minimum value: 0
            Maximum value: 10
            Default value: 0

    """

    def __init__(self,
                 campaign: api_campaign,
                 durations: list[int],
                 daily_import_pressures: list[float],
                 import_age: float = 365,
                 genome: int = 0,
                 antigen: int = 0):
        super().__init__(campaign, 'ImportPressure')

        if not durations or not isinstance(durations, list):
            raise ValueError("durations must be a non-empty list.")
        if not daily_import_pressures or not isinstance(daily_import_pressures, list):
            raise ValueError("daily_import_pressures must be a non-empty list.")
        if len(durations) != len(daily_import_pressures):
            raise ValueError(
                f"durations and daily_import_pressures must have the same length, "
                f"got {len(durations)} and {len(daily_import_pressures)}.")

        self._intervention.Import_Age = validate_value_range(import_age, 'import_age', 0, 43800, float)
        self._intervention.Genome = validate_value_range(genome, 'genome', -1, 16777200.0, int)
        self._intervention.Durations = durations.copy()
        self._intervention.Daily_Import_Pressures = daily_import_pressures.copy()
        if antigen is not None:  # antigen is not in Generic model, workaround for Generic model
            self._intervention.Antigen = validate_value_range(antigen, 'antigen', 0, 10, int)

    def _set_intervention_name(self, intervention_name: str) -> None:
        raise ValueError('Intervention_Name is not a valid parameter for the ImportPressure intervention.')

    def _set_dont_allow_duplicates(self, dont_allow_duplicates: bool) -> None:
        raise ValueError('Dont_Allow_Duplicates is not a valid parameter for the ImportPressure intervention.')

    def _set_new_property_value(self, new_property_value: str) -> None:
        raise ValueError('New_Property_Value is not a valid parameter for the ImportPressure intervention.')

    def _set_disqualifying_properties(self, disqualifying_properties: Union[dict[str, str], list[str]]) -> None:
        raise ValueError('Disqualifying_Properties is not a valid parameter for the ImportPressure intervention.')

    def _set_cost(self, cost: float) -> None:
        raise ValueError('Cost_To_Consumer is not a valid parameter for the ImportPressure intervention.')

MigrateFamily

Bases: NodeIntervention

The MigrateFamily intervention class tells family groups of residents of the targeted node to go on a round trip migration ("family trip"). The duration of time residents wait before migration and the time spent at the destination node can be configured; the pre-migration waiting timer does not start until all residents are at the home node.

Use of this intervention does require that human migration be enabled by setting the configuration parameters Migration_Model to FIXED_RATE_MIGRATION and Migration_Pattern to SINGLE_ROUND_TRIP.

Parameters:

Name Type Description Default
campaign (campaign, required)

An instance of the emod_api.campaign module.

required
duration_before_leaving_distribution (BaseDistribution, required)

The distribution type to use for assigning the duration of time a family waits before migrating to the destination node after all residents are home. Each assigned value is a random draw from the distribution. Please use the following distribution classes from emodpy.utils.distributions to define the distribution: * ConstantDistribution * UniformDistribution * GaussianDistribution * ExponentialDistribution * PoissonDistribution * LogNormalDistribution * DualConstantDistribution * WeibullDistribution * DualExponentialDistribution

required
duration_at_node_distribution (BaseDistribution, required)

The distribution type to use for assigning the duration of time an individual or family spends at a destination node after intervention-based migration. Each assigned value is a random draw from the distribution. Please use the following distribution classes from emodpy.utils.distributions to define the distribution: * ConstantDistribution * UniformDistribution * GaussianDistribution * ExponentialDistribution * PoissonDistribution * LogNormalDistribution * DualConstantDistribution * WeibullDistribution * DualExponentialDistribution

required
nodeid_to_migrate_to (int, required)

The destination node ID for intervention-based migration. Minimum value: 0 Maximum value: 4294970000.0 Default value: 0

required
is_moving bool

Set to true (1) to indicate all the individuals of the family are permanently moving to a new home node for intervention-based migration. Once at the new home node, trips will be made with this node as the root (i.e. round trips come back to this node). Default value: False

False
common_intervention_parameters CommonInterventionParameters

The CommonInterventionParameters object that contains the 4 common parameters: disqualifying_properties, dont_allow_duplicates, intervention_name, new_property_value. The following parameters are not valid for this intervention: cost Default value: None

None
Source code in emodpy/campaign/node_intervention.py
class MigrateFamily(NodeIntervention):
    """
    The **MigrateFamily** intervention class tells family groups of residents of the targeted node to go on a
    round trip migration ("family trip"). The duration of time residents wait before migration and the time
    spent at the destination node can be configured; the pre-migration waiting timer does not start until all
    residents are at the home node.

    Use of this intervention does require that human migration be enabled by setting the configuration parameters
    **Migration_Model** to **FIXED_RATE_MIGRATION** and **Migration_Pattern** to **SINGLE_ROUND_TRIP**.

    Args:
        campaign (api_campaign, required):
            An instance of the emod_api.campaign module.

        duration_before_leaving_distribution(BaseDistribution, required):
            The distribution type to use for assigning the duration of time a family waits before migrating to
            the destination node after all residents are home. Each assigned value is a random draw from the
            distribution. Please use the following distribution classes
            from emodpy.utils.distributions to define the distribution:
            * ConstantDistribution
            * UniformDistribution
            * GaussianDistribution
            * ExponentialDistribution
            * PoissonDistribution
            * LogNormalDistribution
            * DualConstantDistribution
            * WeibullDistribution
            * DualExponentialDistribution

        duration_at_node_distribution(BaseDistribution, required):
            The distribution type to use for assigning the duration of time an individual or family spends at a
            destination node after intervention-based migration. Each assigned value is a random draw from the
            distribution. Please use the following distribution classes
            from emodpy.utils.distributions to define the distribution:
            * ConstantDistribution
            * UniformDistribution
            * GaussianDistribution
            * ExponentialDistribution
            * PoissonDistribution
            * LogNormalDistribution
            * DualConstantDistribution
            * WeibullDistribution
            * DualExponentialDistribution

        nodeid_to_migrate_to(int, required):
            The destination node ID for intervention-based migration.
            Minimum value: 0
            Maximum value: 4294970000.0
            Default value: 0

        is_moving(bool, optional):
            Set to true (1) to indicate all the individuals of the family are permanently moving to a new home
            node for intervention-based migration. Once at the new home node, trips will be made with this node
            as the root (i.e. round trips come back to this node).
            Default value: False

        common_intervention_parameters (CommonInterventionParameters, optional):
            The CommonInterventionParameters object that contains the 4 common
            parameters: disqualifying_properties, dont_allow_duplicates, intervention_name, new_property_value.
            The following parameters are not valid for this intervention:
            cost
            Default value: None
    """

    def __init__(self,
                 campaign: api_campaign,
                 duration_before_leaving_distribution: BaseDistribution,
                 duration_at_node_distribution: BaseDistribution,
                 nodeid_to_migrate_to: int,
                 is_moving: bool = False,
                 common_intervention_parameters: CommonInterventionParameters = None):
        super().__init__(campaign, 'MigrateFamily', common_intervention_parameters)

        self._intervention.NodeID_To_Migrate_To = validate_value_range(nodeid_to_migrate_to, 'nodeid_to_migrate_to', 0, 4294970000.0, int)
        self._intervention.Is_Moving = is_moving
        self.set_distribution(duration_before_leaving_distribution, 'Duration_Before_Leaving')
        self.set_distribution(duration_at_node_distribution, 'Duration_At_Node')

    def _set_cost(self, cost: float) -> None:
        raise ValueError('Cost_To_Consumer is not a valid parameter for the MigrateFamily intervention.')

MultiNodeInterventionDistributor

Bases: NodeIntervention

The MultiNodeInterventionDistributor intervention class is a node-level intervention that distributes multiple other node-level interventions when the distributor only allows specifying one intervention. This class can be thought of as an "adapter", where it can adapt interventions or coordinators that were designed to distribute one intervention to instead distribute many.

Parameters:

Name Type Description Default
campaign (campaign, required)

An instance of the emod_api.campaign module.

required
node_intervention_list (list[NodeIntervention], required)

A list of NodeIntervention objects for the multi-node-level interventions to be distributed by this intervention.

required
common_intervention_parameters CommonInterventionParameters

The CommonInterventionParameters object that contains the 4 common parameters: intervention_name, dont_allow_duplicates, new_property_value, disqualifying_properties. The following parameters are not valid for this intervention: cost Default value: None

None
Source code in emodpy/campaign/node_intervention.py
class MultiNodeInterventionDistributor(NodeIntervention):
    """
    The **MultiNodeInterventionDistributor** intervention class is a node-level intervention that distributes
    multiple other node-level interventions when the distributor only allows specifying one intervention.
    This class can be thought of as an "adapter", where it can adapt interventions or coordinators that were
    designed to distribute one intervention to instead distribute many.

    Args:
        campaign (api_campaign, required):
            An instance of the emod_api.campaign module.

        node_intervention_list(list[NodeIntervention], required):
            A list of NodeIntervention objects for the multi-node-level interventions to be distributed by this
            intervention.

        common_intervention_parameters (CommonInterventionParameters, optional):
            The CommonInterventionParameters object that contains the 4 common
            parameters: intervention_name, dont_allow_duplicates, new_property_value, disqualifying_properties.
            The following parameters are not valid for this intervention:
            cost
            Default value: None
    """

    def __init__(self,
                 campaign: api_campaign,
                 node_intervention_list: list[NodeIntervention],
                 common_intervention_parameters: CommonInterventionParameters = None):
        super().__init__(campaign, 'MultiNodeInterventionDistributor', common_intervention_parameters)

        self._intervention.Node_Intervention_List = [node_intervention.to_schema_dict()
                                                     for node_intervention in node_intervention_list]

    def _set_cost(self, cost: float) -> None:
        raise ValueError('Cost_To_Consumer is not a valid parameter for the MultiNodeInterventionDistributor intervention.')

NodePropertyValueChanger

Bases: NodeIntervention

The NodePropertyValueChanger intervention class sets a given node property to a new value. You can also define a duration in days before the node property reverts back to its original value, the probability that a node will change its node property to the target value, and the number of days over which nodes will attempt to change their node properties to the target value. This node-level intervention functions in a similar manner as the individual-level intervention, PropertyValueChanger.

Parameters:

Name Type Description Default
campaign (campaign, required)

An instance of the emod_api.campaign module.

required
target_np_key_value (str, required)

The NodeProperty key:value pair, as defined in the demographics file, to assign to the node.

required
revert float

The number of days to keep the value of the property/key, specified in Target_NP_Key_Value and set by the intervention, for the node. When the time has expired, the intervention will reset the property/key back to the value it had when the intervention was first applied. Minimum value: 0 Maximum value: 3.40282e+38 Default value: 3.40282e+38

3.40282e+38
maximum_duration float

The maximum amount of time in days nodes have to update the property value. This timing works in conjunction with Daily_Probability. Minimum value: -1 Maximum value: 3.40282e+38 Default value: 3.40282e+38

3.40282e+38
daily_probability float

The daily probability that the node's property value changes to the Target_NP_Key_Value. Minimum value: 0 Maximum value: 1 Default value: 1

1
common_intervention_parameters CommonInterventionParameters

The CommonInterventionParameters object that contains the 4 common parameters: disqualifying_properties, dont_allow_duplicates, intervention_name, new_property_value. The following parameters are not valid for this intervention: cost Default value: None

None
Source code in emodpy/campaign/node_intervention.py
class NodePropertyValueChanger(NodeIntervention):
    """
    The **NodePropertyValueChanger** intervention class sets a given node property to a new value. You can also
    define a duration in days before the node property reverts back to its original value, the probability that
    a node will change its node property to the target value, and the number of days over which nodes will
    attempt to change their node properties to the target value. This node-level intervention functions
    in a similar manner as the individual-level intervention, **PropertyValueChanger**.

    Args:
        campaign (api_campaign, required):
            An instance of the emod_api.campaign module.

        target_np_key_value(str, required):
            The **NodeProperty** key:value pair, as defined in the demographics file, to assign to the node.

        revert(float, optional):
            The number of days to keep the value of the property/key, specified in **Target_NP_Key_Value** and
            set by the intervention, for the node. When the time has expired, the intervention will reset the
            property/key back to the value it had when the intervention was first applied.
            Minimum value: 0
            Maximum value: 3.40282e+38
            Default value: 3.40282e+38

        maximum_duration(float, optional):
            The maximum amount of time in days nodes have to update the property value. This timing works in
            conjunction with **Daily_Probability**.
            Minimum value: -1
            Maximum value: 3.40282e+38
            Default value: 3.40282e+38

        daily_probability(float, optional):
            The daily probability that the node's property value changes to the **Target_NP_Key_Value**.
            Minimum value: 0
            Maximum value: 1
            Default value: 1

        common_intervention_parameters (CommonInterventionParameters, optional):
            The CommonInterventionParameters object that contains the 4 common
            parameters: disqualifying_properties, dont_allow_duplicates, intervention_name, new_property_value.
            The following parameters are not valid for this intervention:
            cost
            Default value: None
    """

    def __init__(self,
                 campaign: api_campaign,
                 target_np_key_value: str,
                 revert: float = 3.40282e+38,
                 maximum_duration: float = 3.40282e+38,
                 daily_probability: float = 1,
                 common_intervention_parameters: CommonInterventionParameters = None):
        super().__init__(campaign, 'NodePropertyValueChanger', common_intervention_parameters)

        self._intervention.Target_NP_Key_Value = validate_key_value_pair(target_np_key_value)
        self._intervention.Revert = validate_value_range(revert, 'revert', 0, 3.40282e+38, float)
        self._intervention.Maximum_Duration = validate_value_range(maximum_duration, 'maximum_duration', -1, 3.40282e+38, float)
        self._intervention.Daily_Probability = validate_value_range(daily_probability, 'daily_probability', 0, 1, float)

    def _set_cost(self, cost: float) -> None:
        raise ValueError('Cost_To_Consumer is not a valid parameter for the NodePropertyValueChanger intervention.')

Outbreak

Bases: NodeIntervention

The Outbreak class allows the introduction of a disease outbreak event by the addition of new infected or susceptible individuals to a node. Outbreak is a node-level intervention; to distribute an outbreak to specific categories of existing individuals within a node, use OutbreakIndividual.

Parameters:

Name Type Description Default
campaign (campaign, required)

An instance of the emod_api.campaign module.

required
probability_of_infection float

The probability that new individuals are infected. 1.0 implies all new individuals are infected while 0.0 adds all of the people as susceptible individuals. Minimum value: 0 Maximum value: 1 Default value: 1

1
number_cases_per_node int

The number of new imported individuals. .. note:: This will increase the population with demographics of 50/50 male/female and user-defined ages Minimum value: 0 Maximum value: 2147480000.0 Default value: 1

1
import_age float

The age (in days) of infected import cases. Minimum value: 0 Maximum value: 43800 Default value: 365

365
genome int

The genetic substrain ID of the outbreak infection. Together with Antigen, they are a unitary object representing a strain of infection, which allows for differentiation among infections. Minimum value: -1 Maximum value: 16777200.0 Default value: 0

0
antigen int

The antigenic base strain ID of the outbreak infection. Minimum value: 0 Maximum value: 10 Default value: 0

0
Source code in emodpy/campaign/node_intervention.py
class Outbreak(NodeIntervention):
    """
    The **Outbreak** class allows the introduction of a disease outbreak event by the addition of new infected
    or susceptible individuals to a node. **Outbreak** is a node-level intervention; to distribute an outbreak
    to specific categories of existing individuals within a node, use **OutbreakIndividual**.

    Args:
        campaign (api_campaign, required):
            An instance of the emod_api.campaign module.

        probability_of_infection(float, optional):
            The probability that new individuals are infected. 1.0 implies all new individuals are infected
            while 0.0 adds all of the people as susceptible individuals.
            Minimum value: 0
            Maximum value: 1
            Default value: 1

        number_cases_per_node(int, optional):
            The number of new imported individuals.
            .. note:: This will increase the population with demographics of 50/50 male/female and user-defined
            ages
            Minimum value: 0
            Maximum value: 2147480000.0
            Default value: 1

        import_age(float, optional):
            The age (in days) of infected import cases.
            Minimum value: 0
            Maximum value: 43800
            Default value: 365

        genome(int, optional):
            The genetic substrain ID of the outbreak infection. Together with **Antigen**, they are a unitary
            object representing a strain of infection, which allows for differentiation among infections.
            Minimum value: -1
            Maximum value: 16777200.0
            Default value: 0

        antigen(int, optional):
            The antigenic base strain ID of the outbreak infection.
            Minimum value: 0
            Maximum value: 10
            Default value: 0

    """

    def __init__(self,
                 campaign: api_campaign,
                 probability_of_infection: float = 1,
                 number_cases_per_node: int = 1,
                 import_age: float = 365,
                 genome: int = 0,
                 antigen: int = 0):
        super().__init__(campaign, 'Outbreak')

        self._intervention.Probability_Of_Infection = validate_value_range(probability_of_infection, 'probability_of_infection', 0, 1, float)
        self._intervention.Number_Cases_Per_Node = validate_value_range(number_cases_per_node, 'number_cases_per_node', 0, 2147480000.0, int)
        self._intervention.Import_Age = validate_value_range(import_age, 'import_age', 0, 43800, float)
        self._intervention.Genome = validate_value_range(genome, 'genome', -1, 16777200.0, int)
        self._intervention.Antigen = validate_value_range(antigen, 'antigen', 0, 10, int)

    def _set_intervention_name(self, intervention_name: str) -> None:
        raise ValueError('Intervention_Name is not a valid parameter for the Outbreak intervention.')

    def _set_dont_allow_duplicates(self, dont_allow_duplicates: bool) -> None:
        raise ValueError('Dont_Allow_Duplicates is not a valid parameter for the Outbreak intervention.')

    def _set_new_property_value(self, new_property_value: str) -> None:
        raise ValueError('New_Property_Value is not a valid parameter for the Outbreak intervention.')

    def _set_disqualifying_properties(self, disqualifying_properties: Union[dict[str, str], list[str]]) -> None:
        raise ValueError('Disqualifying_Properties is not a valid parameter for the Outbreak intervention.')

    def _set_cost(self, cost: float) -> None:
        raise ValueError('Cost_To_Consumer is not a valid parameter for the Outbreak intervention.')