class_docstr: Implementation of Region Proposal Network.
class_docstr_tok: ["Implementation","of","Region","Proposal","Network","."]
docstr: Show RPN proposals on the image.
  
  Although we assume batch size is 1, this method supports arbitrary
  batch size.
docstr_tok: ["Show","RPN","proposals","on","the","image",".","Although","we","assume","batch","size","is","1",",","this","method","supports","arbitrary","batch","size","."]
code: def show_result(self, data, result, dataset=None, top_k=20):
      """Show RPN proposals on the image.
  
      Although we assume batch size is 1, this method supports arbitrary
      batch size.
      """
      img_tensor = data["img"][0]
      img_metas = data["img_metas"][0].data[0]
      imgs = tensor2imgs(img_tensor, **img_metas[0]["img_norm_cfg"])
      assert len(imgs) == len(img_metas)
      for img, img_meta in zip(imgs, img_metas):
          h, w, _ = img_meta["img_shape"]
          img_show = img[:h, :w, :]
          mmcv.imshow_bboxes(img_show, result, top_k=top_k)
  
file_path: insightface/detection/scrfd/mmdet/models/detectors/rpn.py
imports: import mmcv
  from mmcv.image import tensor2imgs
  from mmdet.core import bbox_mapping
  from ..builder import DETECTORS, build_backbone, build_head, build_neck
  from .base import BaseDetector
label_desc: Use image node_id 8 for calling the RPN obj's underlying member method code with example usage: obj.show_result(data, result, dataset, top_k) without return types