def add_summary(scalars_to_summarize=None,
                histograms_to_summarize=None,
                images_to_summarize=None):
  """Adds summaries to the default summary collection.

  Args:
    scalars_to_summarize: A dictionary of (name, scalar tensor) tuples to
      summarize.
    histograms_to_summarize: A dictionary of (name, histogram tensor) tuples to
      summarize.
    images_to_summarize: A dictionary of (name, image tensor) tuples to
      summarize.
  """
  if scalars_to_summarize:
    for key, value in scalars_to_summarize.items():
      tf.summary.scalar(key, value)

  if histograms_to_summarize:
    for key, value in histograms_to_summarize.items():
      tf.summary.histogram(key, value)

  if images_to_summarize:
    for key, value in images_to_summarize.items():
      tf.summary.image(key, value)