<br />

> [!NOTE]
> **Note:** This API is new and only available via `pip install tf-nightly`.

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

First tensor elements raised to powers from second tensor, in floats.

#### View aliases


**Main aliases**

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

<br />

```python
tf.keras.ops.float_power(
    x1, x2
)
```

This is `power` with the operands promoted to a float dtype first, so a
negative exponent has a well defined result for integer inputs, where
`power` either raises an error or returns an integer.

<br />

<br />

<br />

| ## Args ||
|---|---|
| `x1` | The bases. |
| `x2` | The exponents. |

<br />

<br />

<br />

<br />

| ## Returns ||
|---|---|
| Output tensor, the bases in `x1` raised to the exponents in `x2`. ||

<br />

#### Example:

```python
x1 = keras.ops.convert_to_tensor([2, 3, 4])
x2 = keras.ops.convert_to_tensor([-1, -2, 2])
keras.ops.float_power(x1, x2)
array([ 0.5       ,  0.11111111, 16.        ], dtype=float32)
```