Algorithms/solvers to support and KiSAO ids
jonrkarr opened this issue · 4 comments
Solvers to initially support
KISAO terms exist for each of these algorithms and each of their parameters
gillespy2.solvers.numpy.ode_solver.ODESolver
(integrator
=lsoda
): KISAO:0000088atol
(float, default=1e-12): KISAO:0000211: absolute tolerancertol
(float, default=1e-6): KISAO:0000209: relative tolerancelband
(int, default=None): KISAO:0000480: lower half bandwithuband
(int, default=None): KISAO:0000479: upper half bandwithnsteps
(int, default=500): KISAO:0000415: maximum number of stepsfirst_step
(float, default=0.0): KISAO:0000483: initial step sizemin_step
(float, default=0.0): KISAO:0000485: minimum step sizemax_step
(float, default=inf): KISAO:0000467: maximum step sizemax_order_ns
(int, default=12) : KISAO:0000219: maximum non-stiff order (Adams order)max_order_s
(int, default=5) : KISAO:0000220: maximum stiff order (BDF order)
gillespy2.solvers.cpp.ssa_c_solver.SSACSolver
: KISAO:0000029: SSAseed
(int, default=None): KISAO:0000488
gillespy2.solvers.numpy.tau_leaping_solver.TauLeapingSolver
: KISAO:0000039: tau-leapingseed
(int, default=None): KISAO:0000488tau_tol
(float, default=0.03): KISAO:0000228: epsilon
Additional solvers to support
These require additional KiSAO terms. We should discuss with Anna Zhukova how they would prefer to represent vode/adams and vode/bdf within KiSAO. Same for hybrid-tau/RK45, hybrid-tau/RK23, etc.
I'm also not sure what the TauHybridSolver is. Unfortunately, GillesPy2 doesn't have much documentation or references. I think this might be slow-scale tau-leaping (10.1016/j.cma.2008.02.024). We need to ask Brian Drawert.
gillespy2.solvers.numpy.ode_solver.ODESolver
(integrator
=dopri5
): KISAO:0000087- atol (float, 1e-12): KISAO:0000211
- rtol (float, 1e-6): KISAO:0000209
- nsteps (int, 500): KISAO:0000415
- first_step (float, 0): KISAO:0000483
- max_step (float, inf): KISAO:0000467
- safety (float, 0.9) : Safety factor on new step selection
- ifactor (float, 10): Maximum factor to increase/decrease step size by in one step (description appears to be incorrect in SciPy)
- dfactor (float, 0.2): Minimum factor to increase/decrease step size by in one step
- beta (float, 0): Beta parameter for stabilised step size control
gillespy2.solvers.numpy.ode_solver.ODESolver
(integrator
=dop835
): KISAO:0000436- Same parameters as
dopri5
- Same parameters as
gillespy2.solvers.numpy.ode_solver.ODESolver
(integrator
=vode
)- method (string, default=adams, range=['adams', 'bdf']): KISAO_0000475
- with_jacobian (bool, default=false):
- atol (float, default=1e-12): KISAO:0000211
- rtol (float, default=1e-6): KISAO:0000209
- lband (int, default=None): KISAO:0000480
- uband (int, default=None): KISAO:0000479
- order (int, default=12): KISAO:0000484
- nsteps (int, default=500): KISAO:0000415
- max_step (float, default=inf): KISAO:0000467
- min_step (float, default=0.0): KISAO:0000485
- first_step (float, default=0.0): KISAO:0000483
gillespy2.solvers.numpy.ode_solver.ODESolver
(integrator
=zvode
)- Same parameters as
vode
- Same parameters as
gillespy2.solvers.numpy.tau_hybrid_solver.TauHybridSolver
: maybe KISAO:0000028 , need to ask developersseed
(int, default=None): KISAO:0000488tau_tol
(float, default=0.03): KISAO:0000228integrator
(string, default=lsoda, range=['RK45’, ‘RK23’, ‘Radau’, ‘BDF’, and ‘LSODA’]): KISAO_0000475
Solvers to potentially ignore
These solvers provide the same functionality as solvers above. We can ask Brian Drawert whether we should be using these, or the implementations above.
gillespy2.solvers.stochkit.stochkit_solvers.StochKitSolver
(algorithm
=ssa
)seed
: KISAO:0000488
gillespy2.solvers.stochkit.stochkit_solvers.StochKitSolver
(algorithm
=tau_leaping
)seed
: KISAO:0000488epsilon
: KISAO:0000228threshold
(minimum reactions per leap): KISAO:0000230
gillespy2.solvers.stochkit.stochkit_solvers.StochKitODESolver
Unclear whether this works and, if so, what the parameters are
Solvers to ignore
- Identical to other solvers
gillespy2.solvers.cpp.variable_ssa_c_solver.VariableSSACSolver
From release notes: "This solver works identically to SSACSolver, but is optimized for multiple trajectories using variable input values for species and Parameters."gillespy2.solvers.numpy.ssa_solver.NumPySSASolver
I assume this is equivalent to the C solver, but slower
- Deprecated
gillespy2.solvers.cython.cython_ssa_solver.CythonSSASolver
gillespy2.solvers.numpy.basic_ode_solver.BasicODESolver
gillespy2.solvers.numpy.basic_tau_hybrid_solver.BasicTauHybridSolver
gillespy2.solvers.numpy.basic_tau_leaping_solver.BasicTauLeapingSolver
More documentation
https://gillespy2.github.io/GillesPy2/docs/build/html/classes/gillespy2.solvers.html
https://docs.scipy.org/doc/scipy/reference/generated/scipy.integrate.ode.html
https://docs.scipy.org/doc/scipy/reference/generated/scipy.integrate.solve_ivp.html
I implemented this mapping in biosimulators_gillespy2.core
.
Todo
- request KISAO terms
- test
Submitted requests for new KISAO terms
- 3 algorithms
- 5 algorithm parameters
Ticket status: https://sourceforge.net/p/kisao/feature-requests/
In the dev-kisao branch, I applied the newly requested KiSAO terms. This can be merged once the terms are incorporated into KiSAO.
The above is implemented