code: def _write_to_accumulators(nested_acc, nested_tensor, index):
      if isinstance(nested_tensor, tf.Tensor):
          return nested_acc.write(index, nested_tensor)
      return [
          _write_to_accumulators(acc, t, index)
          for acc, t in zip(nested_acc, nested_tensor)
      ]
  
file_path: tf-quant-finance/tf_quant_finance/math/custom_loops.py
imports: import tensorflow.compat.v2
  from tf_quant_finance import utils
label_desc: Use image node_id 12 for calling a global function with example usage: _write_to_accumulators(nested_acc, nested_tensor, index) and returns: unknown, nested_acc