class_docstr: Wrap `model` in `DistributedDataParallel` and `dls` in `DistributedDL`
class_docstr_tok: ["Wrap","`","model","`","in","`","DistributedDataParallel","`","and","`","dls","`","in","`","DistributedDL","`"]
code: def __init__(
      self,
      sync_bn=True,  # Whether to replace all batch norm with `nn.SyncBatchNorm`
      **kwargs,
  ):
      store_attr()
      self.accelerator = Accelerator(**kwargs)
  
imports: from __future__ import annotations
  from .basics import *
  from .callback.progress import ProgressCallback
  from torch.nn.parallel import DistributedDataParallel, DataParallel
  from .data.load import _FakeLoader, _loaders
  from .optimizer import OptimWrapper
label_desc: Use image node_id 1 to create a new DistributedTrainer object from inherited base classes: Callback with example: obj = DistributedTrainer(sync_bn)