from __future__ import annotations

from typing import Any

from .helper import MPIHelper as MPIHelper

class PaddlePSInstance:
    dh: Any = ...
    def __init__(self, server_worker_mode: int = ..., proc_per_node: int = ...) -> None: ...
    def get_worker_id(self): ...
    def get_server_id(self): ...
    def is_worker(self): ...
    def is_server(self): ...
    def is_first_worker(self): ...
    def set_ip(self, ip: Any) -> None: ...
    def gather_ips(self): ...
    def get_node_cnt(self): ...
    def get_worker_num(self): ...
    def get_server_num(self): ...
    def barrier_all(self) -> None: ...
    def barrier_worker(self) -> None: ...
    def finalize(self) -> None: ...
