code: def intersection(boxlist1, boxlist2, scope=None):
      """Compute pairwise intersection areas between boxes.
  
      Args:
        boxlist1: BoxList holding N boxes
        boxlist2: BoxList holding M boxes
        scope: name scope.
  
      Returns:
        a tensor with shape [N, M] representing pairwise intersections
      """
      with tf.name_scope(scope, "Intersection"):
          y_min1, x_min1, y_max1, x_max1 = tf.split(
              value=boxlist1.get(), num_or_size_splits=4, axis=1
          )
          y_min2, x_min2, y_max2, x_max2 = tf.split(
              value=boxlist2.get(), num_or_size_splits=4, axis=1
          )
          all_pairs_min_ymax = tf.minimum(y_max1, tf.transpose(y_max2))
          all_pairs_max_ymin = tf.maximum(y_min1, tf.transpose(y_min2))
          intersect_heights = tf.maximum(
              0.0, all_pairs_min_ymax - all_pairs_max_ymin
          )
          all_pairs_min_xmax = tf.minimum(x_max1, tf.transpose(x_max2))
          all_pairs_max_xmin = tf.maximum(x_min1, tf.transpose(x_min2))
          intersect_widths = tf.maximum(
              0.0, all_pairs_min_xmax - all_pairs_max_xmin
          )
          return intersect_heights * intersect_widths
  
file_path: DALI/docs/examples/use_cases/tensorflow/efficientdet/pipeline/anchors_utils/region_similarity_calculator.py
imports: from abc import ABCMeta
  from abc import abstractmethod
  import tensorflow.compat.v1
label_desc: Use image node_id 2 for calling a global function with example usage: intersection(boxlist1, boxlist2, scope) and returns: unknown