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