Skip to content

Commit

Permalink
Merge pull request #306 from NeuroML/feat/doc-sbml
Browse files Browse the repository at this point in the history
Document sbml
  • Loading branch information
sanjayankur31 authored Feb 19, 2024
2 parents eb91d94 + 78a042a commit fff20f2
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 4 deletions.
1 change: 1 addition & 0 deletions docs/source/pyneuroml.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,6 @@ The PyNeuroML package includes the following sub-packages:
pyneuroml.povray
pyneuroml.runners
pyneuroml.swc
pyneuroml.sbml
pyneuroml.tune
pyneuroml.utils
7 changes: 7 additions & 0 deletions docs/source/pyneuroml.sbml.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
pyneuroml.sbml module
======================

.. automodule:: pyneuroml.sbml
:members:
:undoc-members:
:show-inheritance:
13 changes: 9 additions & 4 deletions pyneuroml/sbml/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,15 @@


def validate_sbml_files(input_files: List[str], strict_units: bool = False) -> bool:
"""
validate each input file using libsbml.SBMLDocument.checkConsistency
input_files is a list of one or more filepaths
strict_units converts unit consistency warnings into errors
"""Validate input files using libsbml.SBMLDocument.checkConsistency
:param input_files: a list of one or more filepaths
:type input_files: list(str)
:param strict_units: toggle whether unit consistency warnings should be
treated as errors
:type strict_units: bool
:returns: True if all files are valid, else False
:rtype: bool
"""

if not len(input_files) >= 1:
Expand Down

0 comments on commit fff20f2

Please sign in to comment.