code: def _build_notificator_call(
      logs, experiment_name=None, mode: str = "training"
  ) -> List:
      experiment_name_text = (
          f" for {experiment_name}"
          if experiment_name is not None
          else ""
      )
      call_list = []
      call_list.append(
          call.send_notification(
              "", subject=f"Start of the {mode}{experiment_name_text}."
          )
      )
  
      if mode == "training":
          for batch_log in logs:
              formatted_log_data = " ".join(
                  [
                      f"{key}: {value}\n"
                      for key, value in batch_log.items()
                  ]
              )
              call_list.append(
                  call.send_notification(
                      f"Here the epoch metrics: \n{formatted_log_data}",
                      subject=f"Epoch {batch_log['epoch']} is done{experiment_name_text}.",
                  )
              )
              message = ""
      elif mode == "testing":
          formatted_log_data = " ".join(
              [f"{key}: {value}\n" for key, value in logs.items()]
          )
          message = f"Here the test metrics: \n{formatted_log_data}"
  
      call_list.append(
          call.send_notification(
              message,
              subject=f"End of the {mode}{experiment_name_text}.",
          )
      )
      return call_list
  
file_path: poutyne/tests/framework/callbacks/test_notification.py
imports: from typing import List
  from unittest import TestCase
  from unittest.mock import MagicMock, call
  import torch
  from torch import nn
  from poutyne import Model
  from poutyne.framework.callbacks.notification import NotificationCallback
  from tests.framework.tools import SomeConstantMetric, repeat_batch_metric, repeat_batch_metric_value, some_batch_metric_1, some_batch_metric_2, some_constant_metric_value, some_data_tensor_generator, some_metric_1_value, some_metric_2_value
label_desc: Use image node_id 7 for calling the NotificationCallbackTest obj's underlying member method code with example usage: obj._build_notificator_call(logs, experiment_name, mode) and returns: call_list