Attend the Women in ML Symposium on December 7 Register now

tfr.keras.utils.pow_minus_1

Stay organized with collections Save and categorize content based on your preferences.

Computes 2**x - 1 element-wise for each label.

Can be used to define gain_fn for tfr.keras.metrics.NDCGMetric.

label A Tensor or anything that can be converted to a tensor using tf.convert_to_tensor.

A Tensor that has each input element transformed as x to 2**x - 1.