tff.backends.mapreduce.DistributeAggregateForm
Stay organized with collections
Save and categorize content based on your preferences.
Standard representation of logic deployable to a federated learning system.
Inherits From: TypedObject
tff.backends.mapreduce.DistributeAggregateForm(
type_signature: tff.types.FunctionType
,
server_prepare: tff.framework.ConcreteComputation
,
server_to_client_broadcast: tff.framework.ConcreteComputation
,
client_work: tff.framework.ConcreteComputation
,
client_to_server_aggregation: tff.framework.ConcreteComputation
,
server_result: tff.framework.ConcreteComputation
)
This class docstring describes the purpose of DistributeAggregateForm
as a
data structure. For a discussion of how an instance of
DistributeAggregateForm
maps to a single federated round, see the package-
level docstring.
This standardized representation can be used to describe a range of
computations that constitute one round of processing in a federated learning
system such as the one described in the following paper:
"Towards Federated Learning at Scale: System Design"
https://arxiv.org/pdf/1902.01046.pdf
It should be noted that not every computation that proceeds in synchronous
rounds is representable as an instance of this class. In particular, this
representation is not suitable for computations that involve multiple back-
and-forths between the server and clients.
Each of the variable constituents of the form are TFF Lambda Computations
(as defined in computation.proto
). Systems that cannot run TFF directly can
convert these TFF Lambda Computations into TensorFlow code using TFF helper
functions. Generally this class will not be instantiated by a programmer
directly but instead targeted by a sequence of transformations that take a
tff.Computation
and produce the appropriate pieces of logic.
Args |
type_signature
|
The type signature of the corresponding tff.Computation
that is equivalent to the pieces of logic encoded in this data
structure.
|
server_prepare
|
The computation that prepares the input for the clients
and computes intermediate server state that will be needed in later
stages.
|
server_to_client_broadcast
|
The computation that represents broadcasting
data from the server to the clients.
|
client_work
|
The client-side work computation.
|
client_to_server_aggregation
|
The computation that aggregates the client
results at the server, potentially using intermediate state generated by
the server_prepare phase.
|
server_result
|
The computation that combines the aggregated client results
and the intermediate state for the round to produce the new server state
as well as server-side output.
|
Attributes |
client_to_server_aggregation
|
|
client_work
|
|
server_prepare
|
|
server_result
|
|
server_to_client_broadcast
|
|
type_signature
|
Returns the TFF type of the equivalent tff.Computation .
|
Methods
summary
View source
summary(
print_fn: Callable[..., None] = print
) -> None
Prints a string summary of the DistributeAggregateForm
.
Args |
print_fn
|
Print function to use. It will be called on each line of the
summary in order to capture the string summary.
|
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-09-20 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-09-20 UTC."],[],[],null,["# tff.backends.mapreduce.DistributeAggregateForm\n\n\u003cbr /\u003e\n\n|-------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [View source on GitHub](https://github.com/tensorflow/federated/blob/v0.87.0 Version 2.0, January 2004 Licensed under the Apache License, Version 2.0 (the) |\n\nStandard representation of logic deployable to a federated learning system.\n\nInherits From: [`TypedObject`](../../../tff/TypedObject) \n\n tff.backends.mapreduce.DistributeAggregateForm(\n type_signature: ../../../tff/types/FunctionType,\n server_prepare: ../../../tff/framework/ConcreteComputation,\n server_to_client_broadcast: ../../../tff/framework/ConcreteComputation,\n client_work: ../../../tff/framework/ConcreteComputation,\n client_to_server_aggregation: ../../../tff/framework/ConcreteComputation,\n server_result: ../../../tff/framework/ConcreteComputation\n )\n\nThis class docstring describes the purpose of `DistributeAggregateForm` as a\ndata structure. For a discussion of how an instance of\n`DistributeAggregateForm` maps to a single federated round, see the [package-\nlevel docstring](https://www.tensorflow.org/federated/api_docs/python/tff/backends/mapreduce).\n\nThis standardized representation can be used to describe a range of\ncomputations that constitute one round of processing in a federated learning\nsystem such as the one described in the following paper:\n\n\"Towards Federated Learning at Scale: System Design\"\n\u003chttps://arxiv.org/pdf/1902.01046.pdf\u003e\n\nIt should be noted that not every computation that proceeds in synchronous\nrounds is representable as an instance of this class. In particular, this\nrepresentation is not suitable for computations that involve multiple back-\nand-forths between the server and clients.\n\nEach of the variable constituents of the form are TFF Lambda Computations\n(as defined in `computation.proto`). Systems that cannot run TFF directly can\nconvert these TFF Lambda Computations into TensorFlow code using TFF helper\nfunctions. Generally this class will not be instantiated by a programmer\ndirectly but instead targeted by a sequence of transformations that take a\n[`tff.Computation`](../../../tff/Computation) and produce the appropriate pieces of logic.\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Args ---- ||\n|--------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `type_signature` | The type signature of the corresponding [`tff.Computation`](../../../tff/Computation) that is equivalent to the pieces of logic encoded in this data structure. |\n| `server_prepare` | The computation that prepares the input for the clients and computes intermediate server state that will be needed in later stages. |\n| `server_to_client_broadcast` | The computation that represents broadcasting data from the server to the clients. |\n| `client_work` | The client-side work computation. |\n| `client_to_server_aggregation` | The computation that aggregates the client results at the server, potentially using intermediate state generated by the server_prepare phase. |\n| `server_result` | The computation that combines the aggregated client results and the intermediate state for the round to produce the new server state as well as server-side output. |\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Attributes ---------- ||\n|--------------------------------|---------------------------------------------------------------------------------------|\n| `client_to_server_aggregation` | \u003cbr /\u003e \u003cbr /\u003e |\n| `client_work` | \u003cbr /\u003e \u003cbr /\u003e |\n| `server_prepare` | \u003cbr /\u003e \u003cbr /\u003e |\n| `server_result` | \u003cbr /\u003e \u003cbr /\u003e |\n| `server_to_client_broadcast` | \u003cbr /\u003e \u003cbr /\u003e |\n| `type_signature` | Returns the TFF type of the equivalent [`tff.Computation`](../../../tff/Computation). |\n\n\u003cbr /\u003e\n\nMethods\n-------\n\n### `summary`\n\n[View source](https://github.com/tensorflow/federated/blob/v0.87.0\nVersion 2.0, January 2004\nLicensed under the Apache License, Version 2.0 (the) \n\n summary(\n print_fn: Callable[..., None] = print\n ) -\u003e None\n\nPrints a string summary of the `DistributeAggregateForm`.\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Args ||\n|------------|--------------------------------------------------------------------------------------------------------------|\n| `print_fn` | Print function to use. It will be called on each line of the summary in order to capture the string summary. |\n\n\u003cbr /\u003e"]]