code: def clip_box(xyxy, ori_image_shape):
      H, W = ori_image_shape
      xyxy[:, 0::2] = np.clip(xyxy[:, 0::2], a_min=0, a_max=W)
      xyxy[:, 1::2] = np.clip(xyxy[:, 1::2], a_min=0, a_max=H)
      w = xyxy[:, 2:3] - xyxy[:, 0:1]
      h = xyxy[:, 3:4] - xyxy[:, 1:2]
      mask = np.logical_and(h > 0, w > 0)
      keep_idx = np.nonzero(mask)
      return xyxy[keep_idx[0]], keep_idx
  
imports: import os
  import cv2
  import time
  import numpy
  import collections
  import math
label_desc: Use image node_id 4 for calling a global function with example usage: clip_box(xyxy, ori_image_shape) and returns: xyxy,  keep_idx