code: def split_grad_list(grad_list):
      """
      Args:
          grad_list: K x N x 2
  
      Returns:
          K x N: gradients
          K x N: variables
      """
      g = []
      v = []
      for tower in grad_list:
          g.append([x[0] for x in tower])
          v.append([x[1] for x in tower])
      return g, v
  
imports: import operator
  from contextlib import contextmanager
  import tensorflow
  import threading
  from ..compat import tfv1
  from ..tfutils.common import get_tf_version_tuple
  from ..tfutils.scope_utils import cached_name_scope, under_name_scope
  from ..tfutils.varreplace import custom_getter_scope
  from ..utils import logger
  from ..utils.argtools import call_only_once
label_desc: Use image node_id 4 for calling a global function with example usage: split_grad_list(grad_list) and returns: g,  v