<br />

|---|
| [![](https://www.tensorflow.org/images/GitHub-Mark-32px.png) View source on GitHub](https://github.com/keras-team/keras/tree/v3.15.1/keras/src/ops/numpy.py#L4407-L4425) |

Test element-wise for real numbers.

#### View aliases


**Main aliases**

[`tf.keras.ops.numpy.isreal`](https://www.tensorflow.org/api_docs/python/tf/keras/ops/isreal)

<br />

    tf.keras.ops.isreal(
        x
    )

<br />

<br />

<br />

| ## Args ||
|---|---|
| `x` | Input tensor. |

<br />

<br />

<br />

<br />

| ## Returns ||
|---|---|
| Output boolean tensor. ||

<br />

#### Example:

    from keras import ops
    x = ops.array([1+1j, 1+0j, 4.5, 3, 2, 2j], dtype="complex64")
    ops.isreal(x)
    array([False,  True,  True,  True,  True, False])