code: def construct_only_rank_zero():
      model = [nn.Linear(10, 10), nn.ReLU()]
      if torch.distributed.get_rank() == 0:
          PipeRPCWrapper(model, [1, 1], worker_map=get_worker_map())
          rpc.shutdown()
      else:
          # Must enter rpc loop to complte PipeRPCWrapper constructor above
          rpc.shutdown()
  
          with pytest.raises(AssertionError):
              PipeRPCWrapper(model, [1, 1], worker_map=get_worker_map())
  
file_path: fairscale/tests/nn/pipe_process/test_rpc.py
imports: import copy
  import os
  import pytest
  import torch
  from torch import nn
  from torch.distributed import rpc
  from fairscale.fair_dev.testing.testing import get_worker_map, torch_spawn
  from fairscale.internal import torch_version
  from fairscale.nn.model_parallel.initialize import get_pipeline_parallel_group
  from fairscale.nn.pipe import PipeRPCWrapper
label_desc: Use image node_id 10 for calling a global function with example usage: construct_only_rank_zero() without return types