gillespy2.solvers.utilities package¶
Submodules¶
gillespy2.solvers.utilities.Tau module¶
This Python module contains the initialization and selection methods for the Tau-Leaping method described in Cao, Y.; Gillespie, D. T.; Petzold, L. R. (2006). “Efficient step size selection for the tau-leaping simulation method” (PDF). The Journal of Chemical Physics. 124 (4): 044109. Bibcode:2006JChPh.124d4109C. doi:10.1063/1.2159468. PMID 16460151. This module is for use in the basic_tau_leaping_solver and basic_tau_hybrid solver only.
- gillespy2.solvers.utilities.Tau.initialize(model, epsilon)[source]¶
This method initailizes the state for tau-leaping selections to be made. Based on Cao, Y.; Gillespie, D. T.; Petzold, L. R. (2006). “Efficient step size selection for the tau-leaping simulation method” (PDF). The Journal of Chemical Physics. 124 (4): 044109. Bibcode:2006JChPh.124d4109C. doi:10.1063/1.2159468. PMID 16460151
- gillespy2.solvers.utilities.Tau.select(*tau_args)[source]¶
Tau Selection method based on Cao, Y.; Gillespie, D. T.; Petzold, L. R. (2006). “Efficient step size selection for the tau-leaping simulation method” (PDF). The Journal of Chemical Physics. 124 (4): 044109. Bibcode:2006JChPh.124d4109C. doi:10.1063/1.2159468. PMID 16460151
gillespy2.solvers.utilities.cpp_support_test module¶
This file contains a function and variable for testing a machines support of GillesPy2 C++ solvers. Used in model.py
gillespy2.solvers.utilities.solverutils module¶
- gillespy2.solvers.utilities.solverutils.change_param_values(listOfParameters, parameters, volume, variables)[source]¶
- gillespy2.solvers.utilities.solverutils.dependency_grapher(model, reactions)[source]¶
This function returns a dependency graph for a models reactions in the form of a dictionary containing {species name: {‘dependencies’}:[list of reaction names]}.
- Parameters:
model – Model to used to create a reaction dependency graph
reactions – list[model.listOfReactions]
- Returns:
Dependency graph dictionary
- gillespy2.solvers.utilities.solverutils.numpy_resume(timeStopped, simulation_data, resume=None)[source]¶
Helper function for when resuming a simulation in a numpy based solver.
- Parameters:
timeStopped – The time in which the simulation was stopped.
simulation_data – The current models simulation data, after being parsed in the numpy solver of choice.
resume (gillespy2.core.Results) – The previous simulations data, that is being resumed
- Returns:
Combined simulation data, the old resume data and the current simulation data.
- gillespy2.solvers.utilities.solverutils.numpy_trajectory_base_initialization(model, number_of_trajectories, timeline, species, resume=None)[source]¶
- gillespy2.solvers.utilities.solverutils.species_parse(model, custom_prop_fun)[source]¶
This function uses Pythons AST module to parse custom propensity function, looking for Species in a model
- Parameters:
model – Model to be checked for species
custom_prop_fun – The custom propensity function to be parsed
- Returns:
List of species objects that are found in a custom propensity function