docstr: Inits TrainerBase class.
  Args:
      rank (int): worker rank
docstr_tok: ["Inits","TrainerBase","class",".","Args",":","rank","(","int",")",":","worker","rank"]
code: def __init__(self, rank):
      r"""
      Inits TrainerBase class.
      Args:
          rank (int): worker rank
      """
      self.__metrics_logger = MetricsLogger(rank)
  
imports: import functools
  import time
  from abc import ABC, abstractmethod
  import torch
  from metrics.MetricsLogger import MetricsLogger
label_desc: Use image node_id 1 to create a new TrainerBase object from inherited base classes: ABC with example: obj = TrainerBase(rank)