code: def get_loss(self):
      if self.config.train.loss == 2:
          criterion = Maploss_v2()
      elif self.config.train.loss == 3:
          criterion = Maploss_v3()
      else:
          raise Exception("Undefined loss")
      return criterion
  
imports: import argparse
  import os
  import shutil
  import time
  import multiprocessing
  import yaml
  import numpy
  import torch
  import torch.nn
  import torch.optim
  import wandb
  from config.load_config import load_yaml, DotDict
  from data.dataset import SynthTextDataSet, CustomDataset
  from loss.mseloss import Maploss_v2, Maploss_v3
  from model.craft import CRAFT
  from eval import main_eval
  from metrics.eval_det_iou import DetectionIoUEvaluator
  from utils.util import copyStateDict, save_parser
label_desc: Use image node_id 6 for calling the Trainer obj's underlying member method code with example usage: obj.get_loss() and returns: criterion