code: def train_graph(iterator_initializers, train_op, accuracy):
      with tf_v1.Session() as sess:
          sess.run(tf_v1.global_variables_initializer())
          sess.run(iterator_initializers)
  
          for i in range(EPOCHS * ITERATIONS):
              sess.run(train_op)
              if i % ITERATIONS == 0:
                  train_accuracy = accuracy.eval()
                  print("Step %d, accuracy: %g" % (i, train_accuracy))
  
          final_accuracy = 0
          for _ in range(ITERATIONS):
              final_accuracy = final_accuracy + accuracy.eval()
          final_accuracy = final_accuracy / ITERATIONS
  
          print("Final accuracy: ", final_accuracy)
          assert final_accuracy > TARGET
  
imports: import nvidia.dali.plugin.tf
  import os
  from nvidia.dali.pipeline import Pipeline
  import nvidia.dali.fn
  import nvidia.dali.types
  from test_utils_tensorflow import num_available_gpus
  from shutil import rmtree
  import tensorflow
  import tensorflow.compat.v1
label_desc: Use image node_id 7 for calling a global function with example usage: train_graph(iterator_initializers, train_op, accuracy) without return types