code: def test_predict(self, mock_extract_feat):
      model_cfg = self.model_cfg.copy()
      model_cfg["det_head"]["in_channels"] = 6
      model_cfg["det_head"]["text_region_thr"] = 0.8
      model_cfg["det_head"]["center_region_thr"] = 0.8
      model = MODELS.build(model_cfg)
      imgs, data_samples, _ = self._get_drrg_inputs()
  
      maps = torch.zeros((1, 6, 224, 224), dtype=torch.float)
      maps[:, 0:2, :, :] = -10.0
      maps[:, 0, 60:100, 50:170] = 10.0
      maps[:, 1, 75:85, 60:160] = 10.0
      maps[:, 2, 75:85, 60:160] = 0.0
      maps[:, 3, 75:85, 60:160] = 1.0
      maps[:, 4, 75:85, 60:160] = 10.0
      maps[:, 5, 75:85, 60:160] = 10.0
      mock_extract_feat.return_value = maps
      with torch.no_grad():
          full_pass_weight = torch.zeros((6, 6, 1, 1))
          for i in range(6):
              full_pass_weight[i, i, 0, 0] = 1
          model.det_head.out_conv.weight.data = full_pass_weight
          model.det_head.out_conv.bias.data.fill_(0.0)
          results = model(imgs, data_samples, mode="predict")
      self.assertIn("polygons", results[0].pred_instances)
      self.assertIn("scores", results[0].pred_instances)
      self.assertTrue(
          isinstance(
              results[0].pred_instances["scores"], torch.FloatTensor
          )
      )
  
file_path: mmocr/tests/test_models/test_textdet/test_detectors/test_drrg.py
imports: import copy
  import unittest
  from os.path import dirname, exists, join
  from unittest import mock
  import numpy
  import torch
  from mmengine.config import Config, ConfigDict
  from mmengine.registry import init_default_scope
  from mmocr.registry import MODELS
  from mmocr.testing.data import create_dummy_textdet_inputs
label_desc: Use image node_id 5 for calling the TestDRRG obj's underlying member method code with example usage: obj.test_predict(mock_extract_feat) without return types