code: def test_shape(
      self, in_type, test_data, min_num_points, offset, expected
  ):
      inst_bbox = get_bbox(test_data[None])
      inst_map = test_data[
          inst_bbox[0][0] : inst_bbox[0][1],
          inst_bbox[0][2] : inst_bbox[0][3],
      ]
      test_data = {"image": in_type(inst_map[None]), "offset": offset}
      result = GenerateInstanceContourd(
          keys="image",
          contour_key_postfix="contour",
          offset_key="offset",
          min_num_points=min_num_points,
      )(test_data)
      assert_allclose(
          result["image_contour"], expected, type_test=False
      )
  
file_path: MONAI/tests/test_generate_instance_contourd.py
imports: from __future__ import annotations
  import unittest
  import numpy
  from parameterized import parameterized
  from monai.apps.pathology.transforms.post.dictionary import GenerateInstanceContourd
  from monai.transforms import BoundingRect
  from monai.utils import min_version, optional_import
  from tests.utils import TEST_NDARRAYS, assert_allclose
label_desc: Use image node_id 1 for calling the TestGenerateInstanceContourd obj's underlying member method code with example usage: obj.test_shape(in_type, test_data, min_num_points, offset, expected) without return types