code: def ray_start_2_cpus_and_gpus():
      address_info = ray.init(num_cpus=2, num_gpus=2)
      yield address_info
      # The code after the yield will run as teardown code.
      ray.shutdown()
  
imports: import time
  from collections import defaultdict
  import pytest
  import ray
  import ray._private.ray_constants
  from ray.train._internal.worker_group import Worker, WorkerGroup, WorkerMetadata
label_desc: Use image node_id 2 for calling a global function with example usage: ray_start_2_cpus_and_gpus() without return types