code: def avg_norm(tensor):
      """
      Return an average of the L2 normalization of the batch
  
      :param tensor: (TensorFlow Tensor) The input tensor
      :return: (TensorFlow Tensor) Average L2 normalization of the batch
      """
      return tf.reduce_mean(
          tf.sqrt(tf.reduce_sum(tf.square(tensor), axis=-1))
      )
  
imports: import os
  import collections
  import functools
  import multiprocessing
  from typing import Set
  import numpy
  import tensorflow
label_desc: Use image node_id 9 for calling a global function with example usage: avg_norm(tensor) and returns: tf