Skip to content

verify.files

Compare PNG figures and SBML models of two directories, verify png and verify sbml.

png

png(args)

Compare the PNG figures of two directories pixel by pixel.

The directories are searched recursively and the figures are paired by the path relative to the directory; with --sids an old figure is paired with the new figure of the SId of its file name (sbmlsim.experiment.to_sid).

Returns:

Type Description
int

0 if all figures are identical, 1 if some differ or exist on one side

int

only.

Raises:

Type Description
UsageError

if a directory does not exist, no figure was found or two old figures have the same SId.

sbml_elements

sbml_elements(path)

Get the elements of an SBML model which determine its simulation.

Returns:

Type Description
dict[str, object] | None

The elements by kind and id, None if the file has no SBML model (the

dict[str, object] | None

layouts the factories write next to the models are no SBML).

sbml

sbml(args)

Compare SBML models: two files, or the files of the same path in two dirs.

The directories are searched recursively and the files are paired by the path relative to the directory.

Returns:

Type Description
int

0 if the models are equal, 1 if they differ or exist on one side only.

Raises:

Type Description
UsageError

if a directory does not exist or no file was found.