code: def __init__(self, config, graph, mode, **kwargs):
      self.config = config
      self.graph = graph
      self.mode = mode
      self.kwargs = kwargs
  
      self.batch_node_size = self.config.batch_node_size
      self.rank = kwargs.get("rank", 0)
      self.nrank = kwargs.get("nrank", 1)
  
file_path: PGL/examples/metapath2vec/datasets/node.py
imports: import os
  import sys
  import time
  import warnings
  import numpy
  from collections import defaultdict
  from pgl.utils.logger import log
  from pgl.distributed import DistGraphClient, DistGraphServer
  from utils.config import prepare_config
label_desc: Use image node_id 1 to create a new NodeGenerator object from inherited base classes: object with example: obj = NodeGenerator(config, graph, mode)