bionetgen package
Subpackages
- bionetgen.atomizer package
- Subpackages
- bionetgen.atomizer.atomizer package
- Submodules
- bionetgen.atomizer.atomizer.analyzeRDF module
- bionetgen.atomizer.atomizer.analyzeSBML module
- bionetgen.atomizer.atomizer.atomizationAux module
- bionetgen.atomizer.atomizer.atomizerUtils module
- bionetgen.atomizer.atomizer.detectOntology module
- bionetgen.atomizer.atomizer.moleculeCreation module
- bionetgen.atomizer.atomizer.resolveSCT module
- Module contents
- bionetgen.atomizer.merging package
- bionetgen.atomizer.rulifier package
- Submodules
- bionetgen.atomizer.rulifier.arial10 module
- bionetgen.atomizer.rulifier.compareModels module
- bionetgen.atomizer.rulifier.componentGroups module
- bionetgen.atomizer.rulifier.parameterExtraction module
- bionetgen.atomizer.rulifier.postAnalysis module
- bionetgen.atomizer.rulifier.stateTransitionDiagram module
- bionetgen.atomizer.rulifier.stdgraph module
- Module contents
- bionetgen.atomizer.utils package
- Submodules
- bionetgen.atomizer.utils.annotationComparison module
- bionetgen.atomizer.utils.annotationDeletion module
- bionetgen.atomizer.utils.annotationExtender module
- bionetgen.atomizer.utils.annotationExtractor module
- bionetgen.atomizer.utils.annotationResolver module
- bionetgen.atomizer.utils.consoleCommands module
- bionetgen.atomizer.utils.extractAtomic module
- bionetgen.atomizer.utils.modelComparison module
- bionetgen.atomizer.utils.nameNormalizer module
- bionetgen.atomizer.utils.pathwaycommons module
- bionetgen.atomizer.utils.readBNGXML module
- bionetgen.atomizer.utils.smallStructures module
- bionetgen.atomizer.utils.structures module
- bionetgen.atomizer.utils.util module
- Module contents
- bionetgen.atomizer.writer package
- bionetgen.atomizer.atomizer package
- Submodules
- bionetgen.atomizer.atomizeTool module
- bionetgen.atomizer.biogrid module
- bionetgen.atomizer.bngModel module
ARuleCompartmentFunctionMoleculeObservableParameterRuleSpeciesbngModelbngModel.add_arule()bngModel.add_compartment()bngModel.add_function()bngModel.add_molecule()bngModel.add_observable()bngModel.add_parameter()bngModel.add_rule()bngModel.add_species()bngModel.add_time_rule()bngModel.adjust_concentrations()bngModel.adjust_frate_functions()bngModel.adjust_volume_corrections()bngModel.check_for_time_function()bngModel.consolidate()bngModel.consolidate_arules()bngModel.consolidate_compartments()bngModel.consolidate_molecules()bngModel.consolidate_observables()bngModel.make_arule()bngModel.make_compartment()bngModel.make_function()bngModel.make_molecule()bngModel.make_observable()bngModel.make_parameter()bngModel.make_rule()bngModel.make_species()bngModel.print_obs_map()bngModel.remove_sympy_symbols()bngModel.reorder_functions()
- bionetgen.atomizer.contactMap module
- bionetgen.atomizer.contextAnalyzer module
- bionetgen.atomizer.libsbml2bngl module
AnalysisResultsBNGL2XML()analyzeFile()analyzeHelper()bondPartners()changeDefs()changeNames()changeRates()correctRulesWithParenthesis()detectCustomDefinitions()evaluation()extractAtoms()extractCompartmentCoIncidence()extractCompartmentStatistics()flatStatusVector()getAnnotations()getAnnotationsDict()getFiles()getMoleculeByName()getRelationshipDegree()handler()isActivated()listFiles()loadBioGrid()main()main2()postAnalysisHelper()postAnalyzeFile()postAnalyzeString()processDir()processFile()processFile2()processFile3()processFunctions()readFromString()recursiveSearch()reorderFunctions()reorder_and_replace_arules()resolveDependencies()resource_path()selectReactionDefinitions()unrollFunctions()validateReactionUsage()
- bionetgen.atomizer.parseAnnotation module
- bionetgen.atomizer.sbml2bngl module
SBML2BNGLSBML2BNGL.adjustInitialConditions()SBML2BNGL.analyzeReactionRate()SBML2BNGL.calculate_factor()SBML2BNGL.check_noCompartment()SBML2BNGL.convertToName()SBML2BNGL.convertToStandardUnitString()SBML2BNGL.convertToStandardUnits()SBML2BNGL.extractModelAnnotation()SBML2BNGL.find_all_symbols()SBML2BNGL.gather_terms()SBML2BNGL.getAssignmentRules()SBML2BNGL.getCompartments()SBML2BNGL.getFullAnnotation()SBML2BNGL.getInitialAssignments()SBML2BNGL.getIsTreeNegative()SBML2BNGL.getMetaInformation()SBML2BNGL.getModelAnnotation()SBML2BNGL.getParameters()SBML2BNGL.getPrunnedTree()SBML2BNGL.getRawSpecies()SBML2BNGL.getReactionCenter()SBML2BNGL.getReactions()SBML2BNGL.getSBMLFunctions()SBML2BNGL.getSpecies()SBML2BNGL.getSpeciesAnnotation()SBML2BNGL.getSpeciesInfo()SBML2BNGL.getStandardName()SBML2BNGL.getSymmetryFactors()SBML2BNGL.getUnitDefinitions()SBML2BNGL.isAmount()SBML2BNGL.isSameNameDifferentCompartment()SBML2BNGL.preProcessStoichiometry()SBML2BNGL.reduceComponentSymmetryFactors()SBML2BNGL.removeFactorFromMath()SBML2BNGL.reset()SBML2BNGL.setConversion()SBML2BNGL.static_var()SBML2BNGL.updateComponentCount()SBML2BNGL.updateFunctionReference()SBML2BNGL.writeLog()
comb()factorial()standardizeName()sympyAndsympyGEQsympyGTsympyIFsympyLEQsympyLTsympyNotsympyOrsympyPieceunrollSBMLFunction()
- bionetgen.atomizer.sbml2json module
- bionetgen.atomizer.sbmlTranslator module
- Module contents
- Subpackages
- bionetgen.core package
- bionetgen.modelapi package
- Submodules
- bionetgen.modelapi.blocks module
- bionetgen.modelapi.bngfile module
- bionetgen.modelapi.bngparser module
- bionetgen.modelapi.model module
bngmodelbngmodel.add_action()bngmodel.add_actions_block()bngmodel.add_block()bngmodel.add_compartments_block()bngmodel.add_empty_block()bngmodel.add_energy_patterns_block()bngmodel.add_functions_block()bngmodel.add_molecule_types_block()bngmodel.add_observables_block()bngmodel.add_parameters_block()bngmodel.add_population_maps_block()bngmodel.add_rules_block()bngmodel.add_species_block()bngmodel.changesbngmodel.recompilebngmodel.reset_compilation_tags()bngmodel.setup_simulator()bngmodel.write_model()
- bionetgen.modelapi.pattern module
- bionetgen.modelapi.pattern_reader module
- bionetgen.modelapi.rulemod module
- bionetgen.modelapi.runner module
- bionetgen.modelapi.structs module
- bionetgen.modelapi.xmlparsers module
- Module contents
- bionetgen.network package
- Submodules
- bionetgen.network.blocks module
- bionetgen.network.network module
- bionetgen.network.networkparser module
- bionetgen.network.structs module
- Module contents
- bionetgen.simulator package
Submodules
bionetgen.main module
- class bionetgen.main.BNGBase(*args, **kw)[source]
Bases:
ArgparseControllerBase cement controller for BioNetGen CLI
Used to set meta attributes like program name (label) as well as command line arguments. Each method is a subcommand in the command line with its own command line arguments.
Subcommands
- run
runs a model given by -i in folder given by -o
- notebook
generates and opens a notebook for a model given by -i, optional
- plot
plots a gdat/cdat/scan file given by -i into file supplied by -o
- info
provides version and path information about the BNG installation and dependencies
- visualize
provides various visualization options for BNG models
- class Meta[source]
Bases:
object- arguments = [(['-v', '--version'], {'action': 'version', 'version': 'BioNetGen simple command line interface 0.8.1\nBioNetGen version: BioNetGen-2.9.0\nCement Framework 3.0.8\nPython 3.7.9\nPlatform Linux-5.15.0-1004-aws-x86_64-with-debian-buster-sid\n '}), (['-req', '--require'], {'action': <class 'bionetgen.main.requireAction'>, 'type': <class 'str'>, 'default': None}), (['-ll', '--log-level'], {'help': 'This option allows you to select a logging level, from quietest to loudest options are: "CRITICAL", "ERROR", "WARNING", "INFO", "DEBUG". Default is set to INFO', 'default': None, 'type': <class 'str'>})]
- description = 'A simple CLI to bionetgen <https://bionetgen.org>. Note that you need Perl installed.'
- help = 'bionetgen'
- label = 'bionetgen'
- info()[source]
Information subcommand to provide installation versions and paths.
Currently provides version information for BioNetGen, the BNG CLI, Perl, numpy, pandas, and libroadrunner. Also provides BNG2.pl and pyBNG paths.
- notebook()[source]
Notebook subcommand that boots up a Jupyter notebook using the nbopen library. It uses a BNGNotebook class defined in core/notebook.
The default template can be found under assets and in the future will likely be replaced by a standard templating tool (e.g. Jinja).
The default base template is agnostic to the model and if -i is given the template then will be adjusted to load in the model supplied.
- plot()[source]
Plotting subcommand for very basic plotting using a convenience function defined in core/main.
Currently we support gdat/cdat/scan file plotting, in a very basic manner. This command expects a space separated file where each column is a series. The first column is used for the x-axis and the rest is used as y-axis and every series is plotted.
See bionetgen plot -h for all the allowed options.
- run()[source]
This is the main run functionality of the CLI.
It uses a convenience function defined in core/main to run BNG2.pl using subprocess, given the set of arguments in the command line and the configuraions set by the defaults as well as the end-user.
- visualize()[source]
Subcommand to generate visualizations. Currently only supports visualize action from BioNetGen.
Types of visualizations and their options - Rule pattern visualization: Visualization of each rule as a bipartite graph - Rule operation visualization: Visualization of each rule showing explicit graph operations - Contact map: Visualize the contact map of the model - Regulatory graph: Visualize the regulatory graph of the model, also called atom rule graph
- class bionetgen.main.BioNetGen(label=None, **kw)[source]
Bases:
AppCement app for BioNetGen CLI
Used to set configuration options like config default, exiting on close and setting log handler. Currently set attributes are below.
Attributes
- labelstr
name of the application
- config_defaultsstr
the default set of configuration options, set in BNGDefaults object
- config_handler: str
the name of the config handler, determines the syntax of the config files
- config_file_suffix: str
the suffix to be used for config files
- config_files: list of str
additional list of config files to enable
- exit_on_closeboolean
determine if the app should exit when the key function is ran
- extensionslist of str
extensions to be used with cement framework
- log_handler: str
name of the log handler
- handlers: list of obj
list of objects derived from cement.Controller that handles the actual CLI
- class Meta[source]
Bases:
object- config_defaults = {'bionetgen': {'bngpath': '/home/docs/checkouts/readthedocs.org/user_builds/pybionetgen/checkouts/latest/bionetgen/bng-linux', 'cvode_include': None, 'cvode_lib': None, 'notebook': {'name': 'bng-notebook.ipynb', 'path': '/home/docs/checkouts/readthedocs.org/user_builds/pybionetgen/checkouts/latest/bionetgen/assets/bionetgen.ipynb', 'template': '/home/docs/checkouts/readthedocs.org/user_builds/pybionetgen/checkouts/latest/bionetgen/assets/bionetgen-temp.ipynb'}, 'stderr': 'STDOUT', 'stdout': 'PIPE'}}
- config_file_suffix = '.conf'
- config_files = ['./.bionetgen.conf']
- config_handler = 'configparser'
- exit_on_close = True
- extensions = ['colorlog']
- handlers = [<class 'bionetgen.main.BNGBase'>]
- label = 'bionetgen'
- log_handler = 'colorlog'