class_docstr: Dictionary-based wrapper of :py:class:`monai.apps.pathology.transforms.post.array.GenerateInstanceCentroid`.
  Generate instance centroid using `skimage.measure.centroid`.
  
  Args:
      keys: keys of the corresponding items to be transformed.
      centroid_key_postfix: the output centroid coordinates will be written to the value of
          `{key}_{centroid_key_postfix}`.
      offset_key: keys of offset used in `GenerateInstanceCentroid`.
      dtype: the data type of output centroid.
      allow_missing_keys: don't raise exception if key is missing.
code: def __init__(
      self,
      keys: KeysCollection,
      centroid_key_postfix: str = "centroid",
      offset_key: str | None = None,
      dtype: DtypeLike | None = int,
      allow_missing_keys: bool = False,
  ) -> None:
      super().__init__(keys, allow_missing_keys)
      self.converter = GenerateInstanceCentroid(dtype=dtype)
      self.centroid_key_postfix = centroid_key_postfix
      self.offset_key = offset_key
  
imports: from __future__ import annotations
  from collections.abc import Callable, Hashable, Mapping
  import numpy
  import torch
  from monai.apps.pathology.transforms.post.array import GenerateDistanceMap, GenerateInstanceBorder, GenerateInstanceCentroid, GenerateInstanceContour, GenerateInstanceType, GenerateSuccinctContour, GenerateWatershedMarkers, GenerateWatershedMask, HoVerNetInstanceMapPostProcessing, HoVerNetNuclearTypePostProcessing, Watershed
  from monai.config.type_definitions import DtypeLike, KeysCollection, NdarrayOrTensor
  from monai.transforms.transform import MapTransform, Transform
  from monai.utils import optional_import
  from monai.utils.enums import HoVerNetBranch
label_desc: Use image node_id 1 to create a new GenerateInstanceCentroidd object from inherited base classes: MapTransform with example: obj = GenerateInstanceCentroidd(keys, centroid_key_postfix, offset_key, dtype, allow_missing_keys)