code: def node_to_cpus(node):
      
  
      result = set()
  
      if node < 0 or node > get_max_node():
          raise ValueError(node)
  
      mask = bitmask_t()
      mask.maskp = (c_ulong * (NUMA_NUM_NODES/(sizeof(c_ulong)*8)))()
      mask.size = NUMA_NUM_NODES
  
      if libnuma.numa_node_to_cpus(node, byref(mask)) < 0:
          raise RuntimeError(node)
  
      for i in range(0, NUMA_NUM_NODES / (sizeof(c_ulong) *8)):
          for j in range(0, sizeof(c_ulong) * 8):
              if mask.maskp[i] & (1 << j) == (1 << j):
                  result.add(i * sizeof(c_ulong) * 8 + j)
  
      return result
docs: Get CPUs available on C{node}.
  
      @return: set of CPU ids
      @rtype: C{set}