code: def build_heter_graph(data_path, num_nodes):
      edges = {}
      idx = 0
      for filename in glob.glob(os.path.join(data_path, "*")):
          try:
              e = pd.read_csv(filename, header=None, sep="\t").values
              edges["etype%s" % idx] = e
              idx += 1
          except Exception as e:
              log.info(e)
              continue
  
      node_types = [(i, "n") for i in range(num_nodes)]
  
      hg = pgl.HeterGraph(edges=edges, node_types=node_types)
  
      return hg
  
file_path: PGL/examples/rgcn/train.py
imports: import os
  import sys
  import glob
  import numpy
  import pandas
  import argparse
  import time
  import paddle
  import pgl
  from pgl.utils.logger import log
  from model import RGCN
label_desc: Use image node_id 1 for calling a global function with example usage: build_heter_graph(data_path, num_nodes) and returns: hg