code: def _rand_polys(self, num_bboxes, h, w):
      bboxes = self._rand_bboxes(num_bboxes, h, w)
      bboxes = bboxes.tolist()
      polys = [bbox2poly(bbox) for bbox in bboxes]
      return polys
  
file_path: mmocr/tests/test_visualization/test_textspotting_visualizer.py
imports: import os.path
  import tempfile
  import unittest
  import cv2
  import numpy
  import torch
  from mmengine.structures import InstanceData
  from mmocr.structures import TextDetDataSample
  from mmocr.utils import bbox2poly
  from mmocr.visualization import TextSpottingLocalVisualizer
label_desc: Use image node_id 3 for calling the TestTextSpottingLocalVisualizer obj's underlying member method code with example usage: obj._rand_polys(num_bboxes, h, w) and returns: polys