code: def configure_cuda():
      write_action_env("TF_NEED_CUDA", "1")
      write_action_env(
          "CUDA_TOOLKIT_PATH",
          os.getenv("CUDA_TOOLKIT_PATH", "/usr/local/cuda"),
      )
      write_action_env(
          "CUDNN_INSTALL_PATH",
          os.getenv("CUDNN_INSTALL_PATH", "/usr/lib/x86_64-linux-gnu"),
      )
      write_action_env(
          "TF_CUDA_VERSION", os.getenv("TF_CUDA_VERSION", "12.2")
      )
      write_action_env(
          "TF_CUDNN_VERSION", os.getenv("TF_CUDNN_VERSION", "8")
      )
  
      write("test --config=cuda")
      write("build --config=cuda")
      write(
          "build:cuda --define=using_cuda=true --define=using_cuda_nvcc=true"
      )
      write(
          "build:cuda --crosstool_top=@ubuntu20.04-gcc9_manylinux2014-cuda11.8-cudnn8.6-tensorrt8.4_config_cuda//crosstool:toolchain"
      )
  
imports: import os
  import pathlib
  import platform
  import logging
  import tensorflow
  from packaging.version import Version
label_desc: Use image node_id 17 for calling a global function with example usage: configure_cuda() without return types