Rate this Page

Control Plane#

Created On: May 30, 2024 | Last Updated: Jun 04, 2024

This module contains optional helpers that add extra debug and control handlers into your application.

torch.distributed.elastic.control_plane.worker_main()[source]#

This is a context manager that wraps your main entry function. This combines the existing errors.record logic as well as a new _WorkerServer that exposes handlers via a unix socket specified by Torch_WORKER_SERVER_SOCKET.

Example

@worker_main()
def main():
    pass


if __name__ == "__main__":
    main()
Return type

Generator[None, None, None]