modeci_mdf.execution_engine.EvaluableNode

class modeci_mdf.execution_engine.EvaluableNode(node: Node, verbose: Optional[bool] = False)[source]

Bases: object

Evaluates a Node during MDF graph execution.

Parameters:
  • node – A self contained unit of evaluation receiving input from other Node(s) on InputPort(s).

  • verbose – If set to True Provides in-depth information else verbose message is not displayed

Methods

evaluate([time_increment, array_format])

Evaluate the Node for one time-step

get_output([id])

Get value at output port for given output port's id

evaluate(time_increment: Optional[Union[int, float]] = None, array_format: str = 'numpy')[source]

Evaluate the Node for one time-step

Parameters:
  • time_increment – The time-increment to use for this evaluation.

  • array_format – The format to use for arrays.

get_output(id: Optional[str] = None) Union[int, ndarray, Tuple][source]

Get value at output port for given output port’s id

Parameters:

id – Unique identifier of the output port. If None, return a tuple for all output ports.

Returns:

value at the output port. If id is None, return all outputs as a tuple. If there is only one output, return just its value.