7.2.8.20.1. __init__

SubDispatchFunction.__init__(dsp, function_id=None, inputs=None, outputs=None, inputs_dist=None, shrink=True, wildcard=True, output_type=None, output_type_kw=None, first_arg_as_kw=False)[source]

Initializes the Sub-dispatch Function.

Parameters:
  • dsp (schedula.Dispatcher | schedula.utils.blue.BlueDispatcher) – A dispatcher that identifies the model adopted.

  • function_id (str, optional) – Function name.

  • inputs (list[str], iterable, optional) – Input data nodes.

  • outputs (list[str], iterable, optional) – Ending data nodes.

  • inputs_dist (dict[str, int | float], optional) – Initial distances of input data nodes.

  • shrink (bool, optional) – If True the dispatcher is shrink before the dispatch.

  • wildcard (bool, optional) – If True, when the data node is used as input and target in the ArciDispatch algorithm, the input value will be used as input for the connected functions, but not as output.

  • output_type (str, optional) –

    Type of function output:

    • ’all’: a dictionary with all dispatch outputs.

    • ’list’: a list with all outputs listed in outputs.

    • ’dict’: a dictionary with any outputs listed in outputs.

  • output_type_kw (bool) – Extra kwargs to pass to the selector function.

  • first_arg_as_kw – Uses the first argument of the __call__ method as kwargs.