class_docstr: Implementation of Dataset class
  
  This is a simple implementation of loading and processing dataset for GATNE model.
  
  Args:
      config: dict, some configure parameters.
class_docstr_tok: ["Implementation","of","Dataset","class","This","is","a","simple","implementation","of","loading","and","processing","dataset","for","GATNE","model",".","Args",":","config",":","dict",",","some","configure","parameters","."]
code: def __init__(self, config):
      self.train_edges_file = config["data_path"] + "train.txt"
      self.valid_edges_file = config["data_path"] + "valid.txt"
      self.test_edges_file = config["data_path"] + "test.txt"
      self.nodes_file = config["data_path"] + "nodes.txt"
  
      self.config = config
  
      self.word2index = self.load_word2index()
  
      self.build_graph()
  
      self.valid_data = self.load_test_data(self.valid_edges_file)
      self.test_data = self.load_test_data(self.test_edges_file)
  
file_path: PGL/legacy/examples/GATNE/Dataset.py
imports: import sys
  import os
  import tqdm
  import numpy
  import logging
  import random
  from pgl import heter_graph
  import pickle
label_desc: Use image node_id 1 to create a new Dataset object from inherited base classes: object with example: obj = Dataset(config)