# tf.debugging.assert_integer

<br />

|---|---|
| [![](https://www.tensorflow.org/images/tf_logo_32px.png) TensorFlow 2 version](https://www.tensorflow.org/api_docs/python/tf/debugging/assert_integer) | [![](https://www.tensorflow.org/images/GitHub-Mark-32px.png) View source on GitHub](https://github.com/tensorflow/tensorflow/blob/v1.15.0/tensorflow/python/ops/check_ops.py#L1438-L1474) |

Assert that `x` is of integer dtype.

#### View aliases


**Main aliases**

\`tf.assert_integer\`
**Compat aliases for migration**

See
[Migration guide](https://www.tensorflow.org/guide/migrate) for
more details.

[`tf.compat.v1.assert_integer`](https://www.tensorflow.org/api_docs/python/tf/compat/v1/assert_integer), [`tf.compat.v1.debugging.assert_integer`](https://www.tensorflow.org/api_docs/python/tf/compat/v1/assert_integer)

<br />

    tf.debugging.assert_integer(
        x, message=None, name=None
    )

Example of adding a dependency to an operation:

    with tf.control_dependencies([tf.compat.v1.assert_integer(x)]):
      output = tf.reduce_sum(x)

<br />

<br />

<br />

| ## Args ||
|---|---|
| `x` | `Tensor` whose basetype is integer and is not quantized. |
| `message` | A string to prefix to the default message. |
| `name` | A name for this operation (optional). Defaults to "assert_integer". |

<br />

<br />

<br />

<br />

| ## Raises ||
|---|---|
| `TypeError` | If `x.dtype` is anything other than non-quantized integer. |

<br />

<br />

<br />

<br />

| ## Returns ||
|---|---|
| A `no_op` that does nothing. Type can be determined statically. ||

<br />