code: def read_trigraph(data_path, data_name, use_dict, kv_mode):
      """Load datasets from files."""
      if data_name == "wikikg90m":
          dataset = WikiKG90MDataset(data_path)
      elif data_name == "wikikg2":
          dataset = WikiKG2Dataset(data_path)
      elif data_name in ["FB15k-237", "WN18RR", "FB15k", "wn18"]:
          dataset = TripletDataset(
              data_path,
              data_name,
              map_to_id=True,
              load_dict=use_dict,
              kv_mode=kv_mode,
          )
      else:
          raise NotImplementedError(
              "Please add %s to read_trigraph function "
              "in dataset/reader.py to load this dataset" % data_name
          )
  
      graph_data = TriGraph(
          dataset.triplets,
          dataset.num_ents,
          dataset.num_rels,
          dataset.ent_feat,
          dataset.rel_feat,
      )
  
      return graph_data
  
imports: import os
  import time
  import numpy
  import paddle.distributed
  from dataset.trigraph import TriGraph
  from utils import timer_wrapper
label_desc: Use image node_id 1 for calling a global function with example usage: read_trigraph(data_path, data_name, use_dict, kv_mode) and returns: graph_data