tf.keras.ops.float_power

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

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.

x1 The bases.
x2 The exponents.

Output tensor, the bases in x1 raised to the exponents in x2.

Example:

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)