code: def __init__(self, logging_dir, prefix=None):
      self.prefix = prefix
      try:
          from mxboard import SummaryWriter
  
          self.summary_writer = SummaryWriter(logging_dir)
      except ImportError:
          logging.error(
              "You can install mxboard via `pip install mxboard`."
          )
  
imports: import logging
label_desc: Use image node_id 1 to create a new LogMetricsCallback object from inherited base classes: object with example: obj = LogMetricsCallback(logging_dir, prefix)