nvflare.collab.api.facade module

class Facade[source]

Bases: object

call_info
callee
caller
child_clients
clients
context
final()
fl_ctx
static get_app_prop(name: str, default=None)[source]

Get a specified property from the site’s app (usually for configuration properties).

Parameters:
  • name – name of the property.

  • default – default value if the property does not exist.

Returns: value of the specified app property, or default value if the property does not exist

classmethod get_clients(names: list[str])[source]

Get proxies for specified site names.

Parameters:

names – names of the sites for which to get proxies.

Returns:

static get_prop(name: str, default=None)[source]

Get a specified property from the call context. Usually for sharing information during collab function processing.

Parameters:
  • name – name of the property.

  • default – default value if the property does not exist.

Returns:

static get_result(default=None)[source]

Get the last main execution result from the call context.

Parameters:

default – the default value if the result does not exist in the call context.

Returns: the last main execution result from the call context

has_children
init()
is_aborted
leaf_clients
main()
other_clients
publish()
server
static set_app_prop(name: str, value)[source]

Set a specified property into the site’s app. Properties in app are permanent during the job/experiment execution.

Parameters:
  • name – name of the property.

  • value – value of the property.

Returns:

static set_prop(name: str, value)[source]

Set a specified property into the call context. Usually for sharing information during collab function processing.

Parameters:
  • name – name of the property.

  • value – value of the property.

Returns:

site_name
workspace
get_call_context()[source]

Return the active Collab context with a clear lifecycle error.