tff.program.MemoryReleaseManager
Stay organized with collections
Save and categorize content based on your preferences.
A tff.program.ReleaseManager
that releases values to memory.
Inherits From: ReleaseManager
tff.program.MemoryReleaseManager()
A tff.program.MemoryReleaseManager
is a utility for releasing values from a
federated program to memory and is used to release values from platform
storage to customer storage in a federated program.
Values are released to memory as Python objects. When the value is released,
if the value is a value reference or a structure containing value references,
each value reference is materialized.
Methods
release
View source
release(
value, key
)
Releases value
from a federated program.
remove_all
View source
remove_all() -> None
Removes all program states.
values
View source
values() -> collections.OrderedDict[Hashable, release_manager.ReleasableStructure]
Returns an collections.OrderedDict
of all keys and released values.
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.
[null,null,["Last updated 2024-09-20 UTC."],[],[],null,["# tff.program.MemoryReleaseManager\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\nA [`tff.program.ReleaseManager`](../../tff/program/ReleaseManager) that releases values to memory.\n\nInherits From: [`ReleaseManager`](../../tff/program/ReleaseManager) \n\n tff.program.MemoryReleaseManager()\n\nA [`tff.program.MemoryReleaseManager`](../../tff/program/MemoryReleaseManager) is a utility for releasing values from a\nfederated program to memory and is used to release values from platform\nstorage to customer storage in a federated program.\n\nValues are released to memory as Python objects. When the value is released,\nif the value is a value reference or a structure containing value references,\neach value reference is materialized.\n\nMethods\n-------\n\n### `release`\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 release(\n value, key\n )\n\nReleases `value` from a federated program.\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Args ||\n|---------|------------------------------------------------------------------------------------------|\n| `value` | A [`tff.program.ReleasableStructure`](../../tff/program#ReleasableStructure) to release. |\n| `key` | A hashable value used to reference the released `value`. |\n\n\u003cbr /\u003e\n\n### `remove_all`\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 remove_all() -\u003e None\n\nRemoves all program states.\n\n### `values`\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 values() -\u003e collections.OrderedDict[Hashable, release_manager.ReleasableStructure]\n\nReturns an `collections.OrderedDict` of all keys and released values."]]