code: def test_dist_objects(num_servers, num_clients, hetero, shared_mem):
      if not shared_mem and num_servers > 1:
          pytest.skip(
              f"Backup servers are not supported when shared memory is disabled"
          )
      ip_config = os.environ.get(
          "DIST_DGL_TEST_IP_CONFIG", "ip_config.txt"
      )
  
      ips = utils.get_ips(ip_config)
      num_part = len(ips)
  
      test_bin = os.path.join(
          os.environ.get("DIST_DGL_TEST_PY_BIN_DIR", "."),
          "run_dist_objects.py",
      )
  
      dist_graph_path = os.path.join(
          shared_workspace,
          "hetero_dist_graph" if hetero else "dist_graph",
      )
      if not os.path.isdir(dist_graph_path):
          create_graph(num_part, dist_graph_path, hetero)
  
      base_envs = (
          f"DIST_DGL_TEST_WORKSPACE={shared_workspace} "
          f"DIST_DGL_TEST_NUM_PART={num_part} "
          f"DIST_DGL_TEST_NUM_SERVER={num_servers} "
          f"DIST_DGL_TEST_NUM_CLIENT={num_clients} "
          f"DIST_DGL_TEST_GRAPH_PATH={dist_graph_path} "
          f"DIST_DGL_TEST_IP_CONFIG={ip_config} "
      )
  
      procs = []
      # Start server
      server_id = 0
      for part_id, ip in enumerate(ips):
          for _ in range(num_servers):
              cmd_envs = (
                  base_envs + f"DIST_DGL_TEST_SERVER_ID={server_id} "
                  f"DIST_DGL_TEST_PART_ID={part_id} "
                  f"DIST_DGL_TEST_SHARED_MEM={str(int(shared_mem))} "
                  f"DIST_DGL_TEST_MODE=server "
              )
              procs.append(
                  utils.execute_remote(
                      f"{cmd_envs} python3 {test_bin}", ip
                  )
              )
              server_id += 1
      # Start client processes
      for part_id, ip in enumerate(ips):
          for _ in range(num_clients):
              cmd_envs = (
                  base_envs + f"DIST_DGL_TEST_PART_ID={part_id} "
                  f"DIST_DGL_TEST_OBJECT_TYPE={target} "
                  f"DIST_DGL_TEST_OBJECT_TYPE_BLACKLIST={blacklist} "
                  f"DIST_DGL_TEST_MODE=client "
              )
              procs.append(
                  utils.execute_remote(
                      f"{cmd_envs} python3 {test_bin}", ip
                  )
              )
  
      for p in procs:
          p.join()
          assert p.exitcode == 0
  
file_path: dgl/tests/dist/test_dist_objects.py
imports: import multiprocessing
  import os
  import shutil
  import subprocess
  import unittest
  import dgl
  import dgl.backend
  import numpy
  import pytest
  import utils
  from dgl.distributed import partition_graph
label_desc: Use image node_id 2 for calling a global function with example usage: test_dist_objects(num_servers, num_clients, hetero, shared_mem) without return types