TensorFlow 2.0 Beta is available Learn more


TensorFlow 2.0 version View source on GitHub

Returns True if the elements of tensor are numbers.


  • tf.compat.v1.debugging.is_numeric_tensor
  • tf.compat.v1.is_numeric_tensor
  • tf.compat.v2.debugging.is_numeric_tensor
  • tf.is_numeric_tensor

Specifically, returns True if the dtype of tensor is one of the following:

Returns False if tensor is of a non-numeric type or if tensor is not a tf.Tensor object.