code: def __init__(self, monitor_config):
      super().__init__(monitor_config)
      self.tb_monitor = None
      self.wandb_monitor = None
      self.csv_monitor = None
      self.enabled = (
          monitor_config.tensorboard_enabled
          or monitor_config.csv_monitor_enabled
          or monitor_config.wandb_enabled
      )
  
      if dist.get_rank() == 0:
          if monitor_config.tensorboard_enabled:
              self.tb_monitor = TensorBoardMonitor(monitor_config)
          if monitor_config.wandb_enabled:
              self.wandb_monitor = WandbMonitor(monitor_config)
          if monitor_config.csv_monitor_enabled:
              self.csv_monitor = csvMonitor(monitor_config)
  
file_path: H2O/h2o_flexgen/benchmark/third_party/DeepSpeed/deepspeed/monitor/monitor.py
imports: from abc import ABC, abstractmethod
  import deepspeed.comm
  from .wandb import WandbMonitor
  from .tensorboard import TensorBoardMonitor
  from .csv_monitor import csvMonitor
label_desc: Use image node_id 1 to create a new MonitorMaster object from inherited base classes: Monitor with example: obj = MonitorMaster(monitor_config)