class_docstr: Logger for WandB (Weights & Biases). This logger is designed to be used in the same way as TrainLogger
  and supports handling nested dictionaries as well.
  
  Arguments
  ---------
  initializer: callable
      A callable function that initializes the WandB run.
      For more information on the parameters that can be passed to the initializer, refer to
      the documentation: https://docs.wandb.ai/ref/python/init
  *args: tuple
      Positional arguments to be passed to the initializer function.
  **kwargs: dict
      Keyword arguments to be passed to the initializer function.
  
  Example
  -------
  To initialize the logger, use the following pattern in hparams.yaml:
  
  ```
  train_logger: !new:speechbrain.utils.train_logger.WandBLogger
      initializer: !name:wandb.init
          entity: speechbrain
          project: sb_project
          name: sb_run
          reinit: True
          resume: False
          dir: !ref <output_folder>/wandb
  ```
  
  NOTE
  ----
  If there is an issue with the WandB Logger initialization, it raises an exception.
code: def __init__(self, initializer, *args, **kwargs):
      try:
          self.run = None
          if if_main_process():
              self.run = initializer(*args, **kwargs)
      except Exception as e:
          raise e(
              "There was an issue with the WandB Logger initialization"
          )
  
imports: import logging
  import torch
  import os
  from speechbrain.utils.distributed import main_process_only, if_main_process
label_desc: Use image node_id 1 to create a new WandBLogger object from inherited base classes: TrainLogger with example: obj = WandBLogger(initializer)