tf.summary.write

Writes a generic summary to the default SummaryWriter if one exists.

This exists primarily to support the definition of type-specific summary ops like scalar() and image(), and is not intended for direct use unless defining a new type-specific summary op.

tagstring tag used to identify the summary (e.g. in TensorBoard), usually generated with tf.summary.summary_scope
tensorthe Tensor holding the summary data to write or a callable that returns this Tensor. If a callable is passed, it will only be called when a default SummaryWriter exists and the recording condition specified by record_if() is met.
stepExplicit int64-castable monotonic step value for this summary. If omitted, this defaults to tf.summary.experimental.get_step(), which must not be None.
metadataOptional SummaryMetadata, as a proto or serialized bytes
nameOptional string name for this op.

True on success, or false if no summary was written because no default summary writer was available.

ValueErrorif a default writer exists, but no step was provided and tf.summary.experimental.get_step() is None.