model.model_resources¶
The source of a model, a file or the SBML itself.
Source
dataclass
¶
Class for keeping track of the resolved sources.
to_dict
¶
Convert to dict.
Used for serialization. The content of a source with a file is the
SBML of the file as it was loaded, see
sbmlsim.model.model_sbml.description, which the path refers to.
from_source
classmethod
¶
Resolve the source string.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
source
|
Source | str | Path
|
path of the model or the SBML itself. |
required |
base_dir
|
Path | None
|
directory a relative path is resolved against, the current working directory by default. |
None
|
Returns:
| Type | Description |
|---|---|
Source
|
The resolved source. |
Raises:
| Type | Description |
|---|---|
OSError
|
if the path of the source does not exist. |