<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/quantizers/quantizers.py#L69-L120) |

Quantizes the input tensor using the absolute maximum quantization scheme.

    tf.keras.quantizers.abs_max_quantize(
        inputs,
        axis,
        value_range=(-127, 127),
        dtype='int8',
        epsilon=backend.epsilon(),
        to_numpy=False
    )

<br />

<br />

<br />

| ## Args ||
|---|---|
| `inputs` | Input tensor to quantize. |
| `axis` | Axis along which to compute the quantization range. |
| `value_range` | Tuple of the minimum and maximum values of the quantization range. |
| `dtype` | Data type of the quantized output. |
| `epsilon` | Small value to avoid division by zero. |
| `to_numpy` | Whether to perform the quantization in numpy. This performs the computation on the host CPU and can be useful for saving memory on the device. If False, the computation is performed on the device. |

<br />

<br />

<br />

<br />

| ## Returns ||
|---|---|
| A tuple of the quantized tensor and the scale. ||

<br />