class_docstr: Callback that records events into a `History` object.
  This callback is automatically applied to
  every SuperModule.
  
  Parameters
  ---------
  trainer : DeepRecoModel
      Model class to train
  verbose : int
      Print results every verbose iteration
class_docstr_tok: ["Callback","that","records","events","into","a","`","History","`","object",".","This","callback","is","automatically","applied","to","every","SuperModule",".","Parameters","--","--","--","--","-","trainer",":","DeepRecoModel","Model","class","to","train","verbose",":","int","Print","results","every","verbose","iteration"]
code: def on_epoch_end(self, epoch, logs=None):
      self.epoch_metrics["loss"] = self.epoch_loss
      for metric_name, metric_value in self.epoch_metrics.items():
          self.history[metric_name].append(metric_value)
      if self.verbose == 0:
          return
      if epoch % self.verbose != 0:
          return
      msg = f"epoch {epoch:<3}"
      for metric_name, metric_value in self.epoch_metrics.items():
          if metric_name != "lr":
              msg += (
                  f"| {metric_name:<3}: {np.round(metric_value, 5):<8}"
              )
      self.total_time = int(time.time() - self.start_time)
      msg += f"|  {str(datetime.timedelta(seconds=self.total_time)) + 's':<6}"
      print(msg)
  
imports: import time
  import datetime
  import copy
  import numpy
  from dataclasses import dataclass, field
  from typing import List, Any
  import warnings
label_desc: Use image node_id 4 for calling the History obj's underlying member method code with example usage: obj.on_epoch_end(epoch, logs) without return types