code: def __init__(self, triples, args, mode, random_sampling, entity_dict):
      self.len = len(triples["head"])
      self.triples = triples
      self.nentity = args.nentity
      self.nrelation = args.nrelation
      self.mode = mode
      self.random_sampling = random_sampling
      if random_sampling:
          self.neg_size = args.neg_size_eval_train
      self.entity_dict = entity_dict
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import numpy
  import torch
  from torch.utils.data import Dataset
label_desc: Use image node_id 1 to create a new TestDataset object from inherited base classes: Dataset with example: obj = TestDataset(triples, args, mode, random_sampling, entity_dict)