class_docstr: convert gt_poly to np.array for rotated bboxes
      
class_docstr_tok: ["convert","gt_poly","to","np.array","for","rotated","bboxes"]
code: def apply(self, sample, context=None):
      if "gt_poly" in sample:
          sample["gt_poly"] = np.array(
              sample["gt_poly"], dtype=np.float32
          ).reshape((-1, 8))
  
      return sample
  
imports: from __future__ import absolute_import
  from __future__ import print_function
  from __future__ import division
  from numbers import Number, Integral
  import cv2
  import numpy
  import math
  import copy
  from .operators import register_op, BaseOperator
  from ppdet.modeling.rbox_utils import poly2rbox_le135_np, poly2rbox_oc_np, rbox2poly_np
  from ppdet.utils.logger import setup_logger
  from ppdet.utils.compact import imagedraw_textsize_c
label_desc: Use image node_id 2 for calling the Poly2Array obj's underlying member method code with example usage: obj.apply(sample, context) and returns: sample