modeci_mdf.mdf

The main object-oriented implementation of the MDF schema, with each core component of the MDF specification implemented as a class. Instances of these objects can be composed to create a representation of an MDF model as Python objects. These models can then be serialized and deserialized to and from JSON or YAML, executed via the execution_engine module, or imported and exported to supported external environments using the interfaces module.

Functions

parsed_structure_factory(cl)

parsed_unstructure_factory(cl)

v(cl)

Classes

Condition([type])

A set of descriptors which specifies conditional execution of Nodes to meet complex execution requirements.

ConditionSet([node_specific, termination, ...])

Specifies the non-default pattern of execution of Nodes

Edge(id, sender, receiver, sender_port, ...)

An Edge is an attribute of a Graph that transmits computational results from a sender's OutputPort to a receiver's InputPort.

Function(id[, function, args, value, metadata])

A single value which is evaluated as a function of values on :class:`InputPort`(s) and other Functions

Graph(id[, nodes, edges, parameters, ...])

A directed graph consisting of :class:`~Node`s (with :class:`~Parameter`s and :class:`~Function`s evaluated internally) connected via :class:`~Edge`s.

InputPort(id[, shape, type, metadata])

The InputPort is an attribute of a Node which allows external information to be input to the Node

Model(id[, graphs, format, ...])

The top level construct in MDF is Model, which may contain multiple Graph objects and model attribute(s)

Node(id[, input_ports, functions, ...])

A self contained unit of evaluation receiving input from other nodes on :class:`InputPort`(s). The values from these are processed via a number of :class:`Function`(s) and one or more final values are calculated on the :class:`OutputPort`(s).

OutputPort(id[, value, shape, type, metadata])

The OutputPort is an attribute of a Node which exports information to another Node connected by an Edge

Parameter(id[, value, ...])

A parameter of the Node, which can be: 1) a specific fixed value (a constant (int/float) or an array) 2) a string expression for the value referencing other named :class:`Parameter`(s).

ParameterCondition(id[, test, value])

A condition to test on a Node's parameters, which if true, sets the value of this Parameter