code: def display_progress_bar(iteration, total, out):
      """Displays progress bar according to python interface.
  
      Parameters
      ----------
      iteration: int
          current iteration
      total: int
          total iterations
      out: progress bar notebook output
  
      """
  
      if (
          (get_ipython().__class__.__name__ == "ZMQInteractiveShell")
          or (get_ipython().__class__.__name__ == "Shell")
          and out is not None
      ):
          out.update(progress_bar_notebook(iteration + 1, total))
      else:
          progress_bar_terminal(
              iteration + 1,
              total,
              prefix="Progress:",
              suffix="Complete",
              length=50,
          )
      return
  
imports: from IPython.display import HTML
  from IPython import get_ipython
label_desc: Use image node_id 3 for calling a global function with example usage: display_progress_bar(iteration, total, out) without return types