TensorFlow 2.0 RC is available Learn more

tf.nest.is_nested

TensorFlow 2.0 version View source on GitHub

Returns true if its input is a collections.Sequence (except strings).

Aliases:

  • tf.compat.v1.nest.is_nested
  • tf.compat.v2.nest.is_nested
  • tf.contrib.framework.nest.is_nested
tf.nest.is_nested(seq)

Args:

  • seq: an input sequence.

Returns:

True if the sequence is a not a string and is a collections.Sequence or a dict.