SingleDeviceStrategy¶
- class lightning.pytorch.strategies.SingleDeviceStrategy(device='cpu', accelerator=None, checkpoint_io=None, precision_plugin=None)[소스]¶
기반 클래스:
lightning.pytorch.strategies.strategy.Strategy
Strategy that handles communication on a single device.
- barrier(*args, **kwargs)[소스]¶
Synchronizes all processes which blocks processes until the whole group enters this function.
- reduce(tensor, *args, **kwargs)[소스]¶
Reduces a tensor from several distributed processes to one aggregated tensor. As this plugin only operates with a single device, the reduction is simply the identity.
- property is_global_zero: bool¶
Whether the current process is the rank zero process not only on the local node, but for all nodes.
- 반환 형식
- property root_device: torch.device¶
Returns the root device.
- 반환 형식