amici
AMICI
The AMICI Python module provides functionality for importing SBML or PySB models and turning them into C++ Python extensions.
- var amici_path
absolute root path of the amici repository or Python package
- var amiciSwigPath
absolute path of the amici swig directory
- var amiciSrcPath
absolute path of the amici source directory
- var amiciModulePath
absolute root path of the amici module
- var hdf5_enabled
boolean indicating if amici was compiled with hdf5 support
- var has_clibs
boolean indicating if this is the full package with swig interface or the raw package without
Classes
|
Enable Python static type checking for AMICI-generated model modules |
|
Context manager for temporarily changing PYTHONPATH |
Functions Summary
|
Convenience wrapper for |
|
Get model settings that are set independently of the compiled model. |
|
Import Python module of an AMICI model |
|
Convenience wrapper for |
|
Convenience wrapper around |
|
Convenience wrapper for loops of amici.runAmiciSimulation |
|
Set model settings. |
|
Convenience wrapper for |
Functions
- amici.ExpData(*args)[source]
Convenience wrapper for
amici.amici.ExpData
constructors- Parameters
args – arguments
- Return type
- Returns
ExpData Instance
- amici.get_model_settings(model)[source]
Get model settings that are set independently of the compiled model.
- Parameters
model (
typing.Union
[amici.amici.Model
,amici.amici.ModelPtr
]) – The AMICI model instance.- Return type
- Returns
Keys are AMICI model attributes, values are attribute values.
- amici.import_model_module(module_name, module_path=None)[source]
Import Python module of an AMICI model
- Parameters
module_name (
str
) – Name of the python package of the modelmodule_path (
typing.Optional
[str
]) – Absolute or relative path of the package directory
- Return type
- Returns
The model module
- amici.readSolverSettingsFromHDF5(file, solver, location='solverSettings')[source]
Convenience wrapper for
amici.readSolverSettingsFromHDF5()
- Parameters
file (
str
) – hdf5 filenamesolver (
typing.Union
[amici.amici.Solver
,amici.amici.SolverPtr
]) – Solver instance to which settings will be transferredlocation (
typing.Optional
[str
]) – location of solver settings in hdf5 file
- Return type
- amici.runAmiciSimulation(model, solver, edata=None)[source]
Convenience wrapper around
amici.amici.runAmiciSimulation()
(generated by swig)- param model
Model instance
- ` :param solver:
Solver instance, must be generated from
amici.amici.Model.getSolver()
- param edata
ExpData instance (optional)
- returns
ReturnData object with simulation results
- Return type
amici.numpy.ReturnDataView
- amici.runAmiciSimulations(model, solver, edata_list, failfast=True, num_threads=1)[source]
Convenience wrapper for loops of amici.runAmiciSimulation
- Parameters
model (
typing.Union
[amici.amici.Model
,amici.amici.ModelPtr
]) – Model instancesolver (
typing.Union
[amici.amici.Solver
,amici.amici.SolverPtr
]) – Solver instance, must be generated from Model.getSolver()edata_list (
typing.Union
[amici.amici.ExpDataPtrVector
,typing.Sequence
[typing.Union
[amici.amici.ExpData
,amici.amici.ExpDataPtr
]]]) – list of ExpData instancesfailfast (
bool
) – returns as soon as an integration failure is encounterednum_threads (
int
) – number of threads to use (only used if compiled with openmp)
- Return type
typing.List
[amici.numpy.ReturnDataView
]- Returns
list of simulation results
- amici.set_model_settings(model, settings)[source]
Set model settings.
- Parameters
model (
typing.Union
[amici.amici.Model
,amici.amici.ModelPtr
]) – The AMICI model instance.settings (
typing.Dict
[str
,typing.Any
]) – Keys are callable attributes (setters) of an AMICI model, values are provided to the setters.
- Return type
- amici.writeSolverSettingsToHDF5(solver, file, location='solverSettings')[source]
Convenience wrapper for
amici.amici.writeSolverSettingsToHDF5()
- Parameters
file (
typing.Union
[str
,object
]) – hdf5 filename, can also be object created byamici.amici.createOrOpenForWriting()
solver (
typing.Union
[amici.amici.Solver
,amici.amici.SolverPtr
]) – Solver instance from which settings will storedlocation (
typing.Optional
[str
]) – location of solver settings in hdf5 file
- Return type