code: def _trans_pos_chips2annotations(
      self, im_file, gt_bbox, is_crowd, gt_class
  ):
      chip_records = []
      for chip, boxes_idx in self._cur_im_pos_chips:
          chip_bbox, final_boxes_idx = transform_chip_box(
              gt_bbox, boxes_idx, chip
          )
          x1, y1, x2, y2 = chip
          chip_h = y2 - y1
          chip_w = x2 - x1
          rec = {
              "im_file": im_file,
              "im_id": np.array([self._global_chip_id]),
              "h": chip_h,
              "w": chip_w,
              "gt_bbox": chip_bbox,
              "is_crowd": is_crowd[final_boxes_idx].copy(),
              "gt_class": gt_class[final_boxes_idx].copy(),
              # 'gt_poly': [None] * len(final_boxes_idx),
              "chip": chip,
          }
          self._global_chip_id += 1
          chip_records.append(rec)
      return chip_records
  
imports: import copy
  import math
  import random
  import numpy
  from copy import deepcopy
  from typing import List, Tuple
  from collections import defaultdict
  from .chip_box_utils import nms, transform_chip_boxes2image_boxes
  from .chip_box_utils import find_chips_to_cover_overlaped_boxes
  from .chip_box_utils import transform_chip_box
  from .chip_box_utils import intersection_over_box
label_desc: Use image node_id 5 for calling the AnnoCropper obj's underlying member method code with example usage: obj._trans_pos_chips2annotations(im_file, gt_bbox, is_crowd, gt_class) and returns: chip_records