code: def format_step(step):
      """
      Define prefix for different prefix message for dllogger.
      Args:
          step(str|tuple): Dllogger step format.
      Returns:
          s(str): String to print in log.
      """
      if isinstance(step, str):
          return step
      s = ""
      if len(step) > 0:
          s += f"Epoch: {step[0]} "
      if len(step) > 1:
          s += f"Iteration: {step[1]} "
      if len(step) > 2:
          s += f"Validation Iteration: {step[2]} "
      if len(step) == 0:
          s = "Summary:"
      return s
  
imports: import logging
  import paddle.distributed
  import dllogger
label_desc: Use image node_id 1 for calling a global function with example usage: format_step(step) and returns: s, step