code: def create_bounding_box(target_landmarks, expansion_factor=0.0):
      """
      gets a batch of landmarks and calculates a bounding box that includes all the landmarks per set of landmarks in
      the batch
      :param target_landmarks: batch of landmarks of dim (n x 68 x 2). Where n is the batch size
      :param expansion_factor: expands the bounding box by this factor. For example, a `expansion_factor` of 0.2 leads
      to 20% increase in width and height of the boxes
      :return: a batch of bounding boxes of dim (n x 4) where the second dim is (x1,y1,x2,y2)
      """
      # Calc bounding box
      x_y_min, _ = target_landmarks.reshape(-1, 68, 2).min(dim=1)
      x_y_max, _ = target_landmarks.reshape(-1, 68, 2).max(dim=1)
      # expanding the bounding box
      expansion_factor /= 2
      bb_expansion_x = (
          x_y_max[:, 0] - x_y_min[:, 0]
      ) * expansion_factor
      bb_expansion_y = (
          x_y_max[:, 1] - x_y_min[:, 1]
      ) * expansion_factor
      x_y_min[:, 0] -= bb_expansion_x
      x_y_max[:, 0] += bb_expansion_x
      x_y_min[:, 1] -= bb_expansion_y
      x_y_max[:, 1] += bb_expansion_y
      return torch.cat([x_y_min, x_y_max], dim=1)
  
imports: import os
  import sys
  import errno
  import torch
  import math
  import numpy
  import cv2
  from skimage import io
  from skimage import color
  from numba import jit
  from urllib.parse import urlparse
  from torch.hub import download_url_to_file, HASH_REGEX
label_desc: Use image node_id 9 for calling a global function with example usage: create_bounding_box(target_landmarks, expansion_factor) and returns: torch