-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'pytorch:main' into bucketized_avg_localSGD
- Loading branch information
Showing
14 changed files
with
841 additions
and
186 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
.. automodule:: torchft.coordination | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,6 +21,7 @@ the entire training job. | |
data | ||
checkpointing | ||
parameter_server | ||
coordination | ||
|
||
|
||
License | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
""" | ||
Coordination (Low Level API) | ||
============================ | ||
.. warning:: | ||
As torchft is still in development, the APIs in this module are subject to change. | ||
This module exposes low level coordination APIs to allow you to build your own | ||
custom fault tolerance algorithms on top of torchft. | ||
If you're looking for a more complete solution, please use the other modules in | ||
torchft. | ||
This provides direct access to the Lighthouse and Manager servers and clients. | ||
""" | ||
|
||
from torchft._torchft import LighthouseServer, ManagerClient, ManagerServer | ||
|
||
__all__ = [ | ||
"LighthouseServer", | ||
"ManagerServer", | ||
"ManagerClient", | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import inspect | ||
from unittest import TestCase | ||
|
||
from torchft.coordination import LighthouseServer, ManagerClient, ManagerServer | ||
|
||
|
||
class TestCoordination(TestCase): | ||
def test_coordination_docs(self) -> None: | ||
classes = [ | ||
ManagerClient, | ||
ManagerServer, | ||
LighthouseServer, | ||
] | ||
for cls in classes: | ||
self.assertIn("Args:", str(cls.__doc__), cls) | ||
for name, method in inspect.getmembers(cls, predicate=inspect.ismethod): | ||
if name.startswith("_"): | ||
continue | ||
self.assertIn("Args:", str(cls.__doc__), cls) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.