code: def init_and_run_process(
      rank,
      world_size,
      filename,
      fn,
      input,
      q,
      wait_event,
      backend="gloo",
  ):
      torch.distributed.init_process_group(
          backend,
          init_method=f"file://{filename}",
          rank=rank,
          world_size=world_size,
      )
      r = fn(*input)
      q.put(r)
  
      wait_event.wait()
      return
  
file_path: ClassyVision/test/generic_distributed_util_test.py
imports: import tempfile
  import unittest
  from itertools import product
  from typing import Any, Dict, List
  import torch
  from classy_vision.generic.distributed_util import _PRIMARY_RANK, broadcast_object
  from torch.multiprocessing import Event, Process, Queue
label_desc: Use image node_id 1 for calling a global function with example usage: init_and_run_process(rank, world_size, filename, fn, input, q, wait_event, backend) without return types