Skip to content

sbmlreport

SBML report using a local sbml4humans instance.

start_server

start_server(path, port=5115)

Start a webserver on the loopback interface which serves only the file path.

The server runs in a daemon thread and is stopped with shutdown().

Parameters:

Name Type Description Default
path Path

the one file which is served.

required
port int

port of the server, 0 selects a free port (see server_address).

5115

Returns:

Type Description
ThreadingHTTPServer

the running server.

create_online_report

create_online_report(
    sbml_path,
    server="http://localhost:3456",
    fileserver_duration=10,
    fileserver_port=5115,
)

Create sbml4humans report.

The SBML file can be validated during report generation. Local parameters can be promoted during report generation.

:param sbml_path: path to SBML file :param server: server to use for report, an sbml4humans instance running on the same machine, with scheme and port :param fileserver_duration: duration of file server in seconds :param fileserver_port: port of file server

The model is served on the loopback address (127.0.0.1) and fetched from there by the report server, so this works with an sbml4humans running on the same machine (the server parameter). A remote server cannot reach the model.

:return: None