code: def build_cluster(num_cpu_nodes, num_gpu_nodes):
      cluster = ray.cluster_utils.Cluster()
      gpu_ids = [
          cluster.add_node(num_cpus=2, num_gpus=1).unique_id
          for _ in range(num_gpu_nodes)
      ]
      cpu_ids = [
          cluster.add_node(num_cpus=1).unique_id
          for _ in range(num_cpu_nodes)
      ]
      cluster.wait_for_nodes()
      return cluster, cpu_ids, gpu_ids
  
imports: import collections
  import logging
  import platform
  import subprocess
  import sys
  import time
  import unittest
  import numpy
  import pytest
  import ray
  import ray.cluster_utils
  import ray.util.accelerators
  from ray._private.internal_api import memory_summary
  from ray.util.scheduling_strategies import PlacementGroupSchedulingStrategy
  from ray._private.test_utils import Semaphore, SignalActor, object_memory_usage, get_metric_check_condition, wait_for_condition, MetricSamplePattern
label_desc: Use image node_id 15 for calling a global function with example usage: build_cluster(num_cpu_nodes, num_gpu_nodes) and returns: cluster,  cpu_ids,  gpu_ids