class_docstr: A runner for simple training without training tricks.
  Applying training tricks such as ensemble of template or verbalizer,
  or self-training can use other runner class.
  This class is specially implemented for generation.
  
  Args:
      model (:obj:`PromptForGeneration`): One ``PromptForGeneration`` object.
      train_dataloader (:obj:`PromptDataloader`, optional): The dataloader to bachify and process the training data.
      valid_dataloader (:obj:`PromptDataloader`, optionla): The dataloader to bachify and process the val data.
      test_dataloader (:obj:`PromptDataloader`, optional): The dataloader to bachify and process the test data.
      config (:obj:`CfgNode`): A configuration object.
code: def inference_epoch_end(self, split, outputs):
      preds = []
      targets = []
      for pred, target in outputs:
          preds.extend(pred)
          targets.extend(target)
  
      self.save_results(split, {"preds": preds, "targets": targets})
  
      metrics = OrderedDict()
      for metric_name in self.config.generation.metric:
          metric = generation_metric(preds, targets, metric_name)
          metrics[metric_name] = metric
      return metrics
  
imports: import os, shutil
  import sys
  import torch
  from torch import nn
  from torch.nn.parallel.data_parallel import DataParallel
  from openprompt.utils.cuda import model_to_device
  from tensorboardX import SummaryWriter
  from tqdm import tqdm
  import dill
  import warnings
  from typing import Callable, Union, Dict
  from openprompt.pipeline_base import PromptForClassification, PromptForGeneration
  from openprompt import PromptDataLoader
  from openprompt.prompts import *
  from openprompt.utils.logging import logger
  from openprompt.utils.metrics import classification_metrics, generation_metric
  from transformers import AdamW, get_linear_schedule_with_warmup
  from transformers.optimization import Adafactor, AdafactorSchedule
label_desc: Use image node_id 3 for calling the GenerationRunner obj's underlying member method code with example usage: obj.inference_epoch_end(split, outputs) and returns: metrics