code: def _summary(tag, hparams_plugin_data):
    
    summary = tf.compat.v1.Summary()
    summary.value.add(
        tag=tag,
        metadata=metadata.create_summary_metadata(hparams_plugin_data))
    return summary
docs: Returns a summary holding the given HParamsPluginData message.
  
    Helper function.
  
    Args:
      tag: string. The tag to use.
      hparams_plugin_data: The HParamsPluginData message to use.