code: def print_epoch_metrics(metrics, val_metrics=None, e=0):
      if val_metrics is not None and len(val_metrics) > 0:
          val = OrderedDict(
              {
                  f"{key}_val": value
                  for key, value in val_metrics.items()
              }
          )
          metrics = {**metrics, **val}
      metrics_df = pd.DataFrame(
          {
              **metrics,
          },
          index=[e + 1],
      )
      metrics_string = metrics_df.to_string(
          float_format=lambda x: f"{x:6.3f}"
      )
      return metrics_string
  
imports: from __future__ import annotations
  import logging
  import math
  import os
  import sys
  from collections import OrderedDict
  from typing import TYPE_CHECKING, Iterable, Optional, Union
  import numpy
  import pandas
  import pytorch_lightning
  import torch
  from neuralprophet import utils_torch
  from neuralprophet.hdays_utils import get_country_holidays
  from neuralprophet.logger import ProgressBar
label_desc: Use image node_id 18 for calling a global function with example usage: print_epoch_metrics(metrics, val_metrics, e) and returns: metrics_string