mmengine.dist.is_main_process¶
- mmengine.dist.is_main_process(group=None)[源代码]¶
Whether the current rank of the given process group is equal to 0.
- 参数:
group (ProcessGroup, optional) – The process group to work on. If None, the default process group will be used. Defaults to None.
- 返回:
Return True if the current rank of the given process group is equal to 0, otherwise False.
- 返回类型: