code: def check_rpc_bipartite_sampling_shuffle(tmpdir, num_server):
      """sample on bipartite via sample_neighbors() which yields non-empty sample results"""
      generate_ip_config("rpc_ip_config.txt", num_server, num_server)
  
      g = create_random_bipartite()
      num_parts = num_server
      num_hops = 1
  
      orig_nid_map, orig_eid_map = partition_graph(
          g,
          "test_sampling",
          num_parts,
          tmpdir,
          num_hops=num_hops,
          part_method="metis",
          return_mapping=True,
      )
  
      pserver_list = []
      ctx = mp.get_context("spawn")
      for i in range(num_server):
          p = ctx.Process(
              target=start_server,
              args=(i, tmpdir, num_server > 1, "test_sampling"),
          )
          p.start()
          time.sleep(1)
          pserver_list.append(p)
  
      deg = get_degrees(g, orig_nid_map["game"], "game")
      nids = F.nonzero_1d(deg > 0)
      block, gpb = start_bipartite_sample_client(
          0, tmpdir, num_server > 1, nodes={"game": nids, "user": [0]}
      )
      print("Done sampling")
      for p in pserver_list:
          p.join()
          assert p.exitcode == 0
  
      for c_etype in block.canonical_etypes:
          src_type, etype, dst_type = c_etype
          src, dst = block.edges(etype=etype)
          # These are global Ids after shuffling.
          shuffled_src = F.gather_row(
              block.srcnodes[src_type].data[dgl.NID], src
          )
          shuffled_dst = F.gather_row(
              block.dstnodes[dst_type].data[dgl.NID], dst
          )
          shuffled_eid = block.edges[etype].data[dgl.EID]
  
          orig_src = F.asnumpy(
              F.gather_row(orig_nid_map[src_type], shuffled_src)
          )
          orig_dst = F.asnumpy(
              F.gather_row(orig_nid_map[dst_type], shuffled_dst)
          )
          orig_eid = F.asnumpy(
              F.gather_row(orig_eid_map[c_etype], shuffled_eid)
          )
  
          # Check the node Ids and edge Ids.
          orig_src1, orig_dst1 = g.find_edges(orig_eid, etype=etype)
          assert np.all(F.asnumpy(orig_src1) == orig_src)
          assert np.all(F.asnumpy(orig_dst1) == orig_dst)
  
imports: import multiprocessing
  import os
  import random
  import sys
  import time
  import traceback
  import unittest
  from pathlib import Path
  import backend
  import dgl
  import numpy
  import pytest
  from dgl.data import CitationGraphDataset, WN18Dataset
  from dgl.distributed import DistGraph, DistGraphServer, load_partition, load_partition_book, partition_graph, sample_etype_neighbors, sample_neighbors
  from scipy import sparse
  from utils import generate_ip_config, reset_envs
label_desc: Use image node_id 26 for calling a global function with example usage: check_rpc_bipartite_sampling_shuffle(tmpdir, num_server) without return types