class_docstr: A generic multi-modal dataset.
      Args:
          `meta_processor`: a meta processor,
              handling loading meta data and return video_id and text_id.
          `video_processor`: a video processor,
              handling e.g., decoding, loading .np files.
          `text_processor`: a text processor,
              handling e.g., tokenization.
          `aligner`: combine the video and text feature
              as one training example.
code: def print_example(self, output):
      print("[one example]", output["video_id"])
      if (
          hasattr(self.align_processor, "subsampling")
          and self.align_processor.subsampling is not None
          and self.align_processor.subsampling > 1
      ):
          for key in output:
              if torch.is_tensor(output[key]):
                  output[key] = output[key][0]
  
      # search tokenizer to translate ids back.
      tokenizer = None
      if hasattr(self.text_processor, "tokenizer"):
          tokenizer = self.text_processor.tokenizer
      elif hasattr(self.align_processor, "tokenizer"):
          tokenizer = self.align_processor.tokenizer
      if tokenizer is not None:
          caps = output["caps"].tolist()
          if isinstance(caps[0], list):
              caps = caps[0]
          print("caps", tokenizer.decode(caps))
          print("caps", tokenizer.convert_ids_to_tokens(caps))
  
      for key, value in output.items():
          if torch.is_tensor(value):
              if len(value.size()) >= 3:  # attention_mask.
                  print(key, value.size())
                  print(key, "first", value[0, :, :])
                  print(key, "last", value[-1, :, :])
              else:
                  print(key, value)
      print("[end of one example]")
  
file_path: fairseq/examples/MMPT/mmpt/datasets/mmdataset.py
imports: import torch
  from collections import OrderedDict
  from torch.utils.data import Dataset
  from torch.utils.data.dataloader import default_collate
  from ..utils import set_seed
label_desc: Use image node_id 5 for calling the MMDataset obj's underlying member method code with example usage: obj.print_example(output) without return types