code: def change_gpu(val):
      """
      Args:
          val: an integer, the index of the GPU or -1 to disable GPU.
  
      Returns:
          a context where ``CUDA_VISIBLE_DEVICES=val``.
      """
      val = str(val)
      if val == "-1":
          val = ""
      return change_env("CUDA_VISIBLE_DEVICES", val)
  
imports: import os
  from .None import logger
  from .concurrency import subproc_call
  from .nvml import NVMLContext
  from .utils import change_env
label_desc: Use image node_id 1 for calling a global function with example usage: change_gpu(val) and returns: change_env