code: def get_sys_env():
      """collect environment information"""
      env_info = {}
      env_info["platform"] = platform.platform()
  
      env_info["Python"] = sys.version.replace("\n", "")
  
      # TODO is_compiled_with_cuda() has not been moved
      compiled_with_cuda = paddle.is_compiled_with_cuda()
      env_info["Paddle compiled with cuda"] = compiled_with_cuda
  
      if compiled_with_cuda:
          cuda_home = _find_cuda_home()
          env_info["NVCC"] = _get_nvcc_info(cuda_home)
          # refer to https://github.com/PaddlePaddle/Paddle/blob/release/2.0-rc/paddle/fluid/platform/device_context.cc#L327
          v = paddle.get_cudnn_version()
          v = str(v // 1000) + "." + str(v % 1000 // 100)
          env_info["cudnn"] = v
          if "gpu" in paddle.get_device():
              gpu_nums = paddle.distributed.ParallelEnv().nranks
          else:
              gpu_nums = 0
          env_info["GPUs used"] = gpu_nums
  
          env_info["CUDA_VISIBLE_DEVICES"] = os.environ.get(
              "CUDA_VISIBLE_DEVICES"
          )
          if gpu_nums == 0:
              os.environ["CUDA_VISIBLE_DEVICES"] = ""
          env_info["GPU"] = _get_gpu_info()
  
      try:
          gcc = subprocess.check_output(["gcc", "--version"]).decode()
          gcc = gcc.strip().split("\n")[0]
          env_info["GCC"] = gcc
      except:
          pass
  
      env_info["PaddleSeg"] = paddleseg.__version__
      env_info["PaddlePaddle"] = paddle.__version__
      env_info["OpenCV"] = cv2.__version__
  
      return env_info
  
file_path: PaddleSeg/paddleseg/utils/env/sys_env.py
imports: import glob
  import os
  import platform
  import subprocess
  import sys
  import cv2
  import paddle
  import paddleseg
label_desc: Use image node_id 4 for calling a global function with example usage: get_sys_env() and returns: env_info