code: def start_node_dataloader(
      rank,
      ip_config,
      part_config,
      num_server,
      num_workers,
      orig_nid,
      orig_eid,
      groundtruth_g,
  ):
      dgl.distributed.initialize(ip_config)
      gpb = None
      disable_shared_mem = num_server > 1
      if disable_shared_mem:
          _, _, _, gpb, _, _, _ = load_partition(part_config, rank)
      num_nodes_to_sample = 202
      batch_size = 32
      dist_graph = DistGraph(
          "test_mp", gpb=gpb, part_config=part_config
      )
      assert len(dist_graph.ntypes) == len(groundtruth_g.ntypes)
      assert len(dist_graph.etypes) == len(groundtruth_g.etypes)
      if len(dist_graph.etypes) == 1:
          train_nid = th.arange(num_nodes_to_sample)
      else:
          train_nid = {"n3": th.arange(num_nodes_to_sample)}
  
      for i in range(num_server):
          part, _, _, _, _, _, _ = load_partition(part_config, i)
  
      # Create sampler
      sampler = dgl.dataloading.MultiLayerNeighborSampler(
          [
              # test dict for hetero
              {etype: 5 for etype in dist_graph.etypes}
              if len(dist_graph.etypes) > 1
              else 5,
              10,
          ]
      )  # test int for hetero
  
      # We need to test creating DistDataLoader multiple times.
      for i in range(2):
          # Create DataLoader for constructing blocks
          dataloader = dgl.dataloading.DistNodeDataLoader(
              dist_graph,
              train_nid,
              sampler,
              batch_size=batch_size,
              shuffle=True,
              drop_last=False,
              num_workers=num_workers,
          )
  
          for epoch in range(2):
              for idx, (_, _, blocks) in zip(
                  range(0, num_nodes_to_sample, batch_size), dataloader
              ):
                  block = blocks[-1]
                  for (
                      src_type,
                      etype,
                      dst_type,
                  ) in block.canonical_etypes:
                      o_src, o_dst = block.edges(etype=etype)
                      src_nodes_id = block.srcnodes[src_type].data[
                          dgl.NID
                      ][o_src]
                      dst_nodes_id = block.dstnodes[dst_type].data[
                          dgl.NID
                      ][o_dst]
                      src_nodes_id = orig_nid[src_type][src_nodes_id]
                      dst_nodes_id = orig_nid[dst_type][dst_nodes_id]
                      has_edges = groundtruth_g.has_edges_between(
                          src_nodes_id, dst_nodes_id, etype=etype
                      )
                      assert np.all(F.asnumpy(has_edges))
      del dataloader
      # this is needed since there's two test here in one process
      dgl.distributed.exit_client()
  
imports: import multiprocessing
  import os
  import tempfile
  import time
  import unittest
  import backend
  import dgl
  import numpy
  import pytest
  import torch
  from dgl.data import CitationGraphDataset
  from dgl.distributed import DistDataLoader, DistGraph, DistGraphServer, load_partition, partition_graph
  from scipy import sparse
  from utils import generate_ip_config, reset_envs
label_desc: Use image node_id 7 for calling a global function with example usage: start_node_dataloader(rank, ip_config, part_config, num_server, num_workers, orig_nid, orig_eid, groundtruth_g) without return types