code: def test_gpt2():
      spawn(run_dist, 4)
  
file_path: colossalai/tests/test_shardformer/test_with_torch_ddp.py
imports: from contextlib import nullcontext
  import pytest
  import torch
  import torch.distributed
  from torch.nn.parallel import DistributedDataParallel
  import colossalai
  from colossalai.cluster import DistCoordinator
  from colossalai.lazy import LazyInitContext
  from colossalai.logging import disable_existing_loggers
  from colossalai.shardformer import ShardConfig, ShardFormer
  from colossalai.testing import clear_cache_before_run, parameterize, rerun_if_address_is_in_use, spawn
  from tests.kit.model_zoo import model_zoo
label_desc: Use image node_id 3 for calling a global function with example usage: test_gpt2() without return types