code: def add_to_report(self, report, model, *args, **kwargs):
      if "execute_on_master_only" in kwargs:
          warnings.warn(
              "'execute_on_master_only keyword is deprecated and isn't used anymore",
              DeprecationWarning,
          )
      self._check_current_dataloader()
      for key in self.candidate_fields:
          report = self.reshape_and_gather(report, key)
  
      results = []
  
      if hasattr(self.current_dataset, "format_for_prediction"):
          results = self.current_dataset.format_for_prediction(report)
  
      if hasattr(model, "format_for_prediction"):
          results = model.format_for_prediction(results, report)
      elif hasattr(model.module, "format_for_prediction"):
          results = model.module.format_for_prediction(results, report)
  
      self.report = self.report + results
  
imports: import csv
  import json
  import logging
  import os
  import warnings
  from dataclasses import dataclass, field
  from typing import List
  import pytorch_lightning
  from mmf.common.registry import registry
  from mmf.common.sample import convert_batch_to_sample_list
  from mmf.utils.configuration import get_mmf_env
  from mmf.utils.distributed import gather_tensor, is_main
  from mmf.utils.file_io import PathManager
  from mmf.utils.general import ckpt_name_from_core_args, foldername_from_config_override
  from mmf.utils.logger import log_class_usage
  from mmf.utils.timer import Timer
  from omegaconf import OmegaConf
  from torch.utils.data import Dataset
label_desc: Use image node_id 12 for calling the TestReporter obj's underlying member method code with example usage: obj.add_to_report(report, model) without return types