code: def transformBox(pt, ul, br, inpH, inpW, resH, resW):
      center = np.zeros(2)
      center[0] = (br[0] - 1 - ul[0]) / 2
      center[1] = (br[1] - 1 - ul[1]) / 2
  
      lenH = max(br[1] - ul[1], (br[0] - ul[0]) * inpH / inpW)
      lenW = lenH * inpW / inpH
  
      _pt = np.zeros(2)
      _pt[0] = pt[0] - ul[0]
      _pt[1] = pt[1] - ul[1]
      # Move to center
      _pt[0] = _pt[0] + max(0, (lenW - 1) / 2 - center[0])
      _pt[1] = _pt[1] + max(0, (lenH - 1) / 2 - center[1])
      pt = (_pt * resH) / lenH
      pt[0] = round(float(pt[0]))
      pt[1] = round(float(pt[1]))
      return pt
  
imports: from __future__ import absolute_import
  from __future__ import division
  import math
  import random
  import numpy
  import mxnet
  from mxnet import nd, image
  from mxnet.gluon.data.vision import transforms
  from ...utils.filesystem import try_import_cv2
label_desc: Use image node_id 22 for calling a global function with example usage: transformBox(pt, ul, br, inpH, inpW, resH, resW) and returns: pt