vivarium.processes.death module¶
Model of Conditional Cell Death¶
Fully-capitalized words and phrases have the meanings specified in RFC 2119.
This module holds machinery for modeling cell death that is conditioned on the state of the cell. This machinery consists of death detector classes and death process classes.
Death Detector Classes¶
Death detector classes encode a model (which may be configured upon instantiation) for when a cell should die. These classes can be instantiated to give death detectors, which are used by the death processes we describe below.
Death detector classes MUST subclass DetectorInterface
and
implement DetectorInterface.check_can_survive()
as specified in
its documentation.
Death Process Classes¶
During a simulation, death is executed by a death process, whose
model is declared in a death process class. Each of these
process classes SHOULD use a death detector, as detailed above, to
determine when the cell should die. The mechanism by which the cell’s
death is modeled depends on the form of death being modeled. For an
example, see DeathFreezeState
.
-
class
vivarium.processes.death.
AntibioticDetector
(antibiotic_threshold=0.9, antibiotic_key='antibiotic')[source]¶ Bases:
vivarium.processes.death.DetectorInterface
Death detector for antibiotics
Checks whether the cell can survive the current internal antibiotic concentrations.
- Parameters
-
check_can_survive
(states)[source]¶ Checks if the current antibiotic concentration is survivable
The internal antibiotic concentration MUST be stored in a variable of a port named
internal
.- Returns
- False if the antibiotic concentration is strictly
greater than the the threshold. True otherwise.
- Return type
-
vivarium.processes.death.
DETECTOR_CLASSES
= {'antibiotic': <class 'vivarium.processes.death.AntibioticDetector'>}¶ Map from detector class names to detector classes
-
class
vivarium.processes.death.
DeathFreezeState
(initial_parameters=None)[source]¶ Bases:
vivarium.core.process.Process
Model Death by Removing Processes
This process class models death by, with a few exceptions, freezing the internal state of the cell. We implement this by removing from this process’s compartment all processes, specified with the
targets
configuration.Configuration:
``detectors``: A list of the names of the detector classes to include. Death will be triggered if any one of these triggers death. Names are specified in
DETECTOR_CLASSES
.``targets``: A list of the names of the processes that will be removed when the cell dies. The names are specified in the compartment’s topology.
``internal``: The internal state of the cell.
``global``: Should be linked to the
global
store.``processes``: Should be linked to the store that has the processes as children.
-
name
= 'death'¶
-
class
vivarium.processes.death.
DetectorInterface
[source]¶ Bases:
object
Interface that MUST be subclassed by all death detectors
Each subclass SHOULD check for a condition that might kill the cell.
For an example of a death detector class, see
AntibioticDetector
.
-
class
vivarium.processes.death.
ToyAntibioticInjector
(initial_parameters=None)[source]¶ Bases:
vivarium.core.process.Process
-
name
= 'toy_antibiotic_injector'¶
-