class_docstr: Wrapper model implementing the full NCP clustering algorithm.
  
  This class wraps an instantiated NCP model and performs the full NCP
  clustering algorithm, which sequentially assigns cluster labels to N input
  data points by N forward passes through the NCP model.
  
  Attributes:
    ncp_model: A `NCPBase` model instance.
    sampler: A sampler class with a `sample(logits)` function for posterior
      sampling of cluster labels at inference time, or set to `None` for
      training. The `sample(logits)` function should take as input a float
      tensor of shape `[batch_size, num_clusters]` and return an int tensor of
      shape `[batch_size]` representing the sampled cluster IDs.
code: def __init__(self, ncp_model, sampler=None):
      super(NCPWrapper, self).__init__()
      self.ncp_model = ncp_model
      self.sampler = sampler
  
file_path: neural-structured-learning/research/neural_clustering/models/ncp_wrapper.py
imports: from neural_clustering.utils.data_utils import batch_remap_label_ids
  import tensorflow
label_desc: Use image node_id 1 to create a new NCPWrapper object from inherited base classes: tf.keras with example: obj = NCPWrapper(ncp_model, sampler)