|View source on GitHub|
The federated executor orchestrates federated computations.
tff.framework.FederatingExecutor( target_executors )
The intrinsics currently implemented include:
This executor is only responsible for handling federated types and federated operators, and a delegation of work to an underlying collection of target executors associated with individual system participants. This executor does not interpret lambda calculus and compositional constructs (blocks, etc.). It understands placements, selected intrinsics (federated operators), it can handle tuples, selections, and calls in a limited way (to the extent that it deals with intrinsics or lambda expressions it can delegate).
The initial implementation of the executor only supports the two basic types of placements (SERVER and CLIENTS), and does not have a built-in concept of intermediate aggregation, partitioning placements, clustering clients, etc.
The initial implementation also does not attempt at performing optimizations
in case when the constituents of this executor are either located on the same
machine (where marshaling/unmarshaling could be avoided), or when they have
all_equal property (and a single value could be shared by them all).
target_executors: A dictionary mapping placements to executors or lists of executors associated with these placements. The keys in this dictionary can be either placement literals, or
Noneto specify the executor for unplaced computations. The values can be either single executors (if there only is a single participant associated with that placement, as would typically be the case with
tff.SERVER) or lists of target executors.
ValueError: If the value is unrecognized (e.g., a nonexistent intrinsic).
Release resources associated with this Executor, if any.
If the executor has one or more target Executors, implementation of this method must close them.
create_call( *fn_args, **fn_kwargs )
create_selection( *fn_args, **fn_kwargs )
create_tuple( *fn_args, **fn_kwargs )
create_value( *fn_args, **fn_kwargs )