tf.raw_ops.UniformQuantizedClipByValue

Perform clip by value on the quantized Tensor operand.

Given quantized operand which was quantized using scales and zero_points, performs clip by value using min and max values. If quantization_axis is -1 (per-tensor quantized), the entire operand is clipped using scalar min, max. Otherwise (per-channel quantized), the clipping is also done per-channel.

operand A Tensor. Must be one of the following types: qint32. Must be a Tensor of T.
min A Tensor. Must have the same type as operand. The min value(s) to clip operand. Must be a Tensor of T. Must be a scalar Tensor if quantization_axis is -1 (per-tensor quantization), otherwise 1D Tensor of size (operand.dim_size(quantization_axis),) (per-axis quantization).
max A Tensor. Must have the same type as operand. The min value(s) to clip operand. Must be a Tensor of T. Must be a scalar Tensor if quantization_axis is -1 (per-tensor quantization), otherwise 1D Tensor of size (operand.dim_size(quantization_axis),) (per-axis quantization).
scales A Tensor of type float32. The float value(s) used as scale(s) when quantizing operand, min and max. Must be a scalar Tensor if quantization_axis is -1 (per-tensor quantization), otherwise 1D Tensor of size (operand.dim_size(quantization_axis),) (per-axis quantization).
zero_points A Tensor of type int32. The int32 value(s) used as zero_point(s) when quantizing operand, min and max. Same shape condition as scales.
quantization_min_val An int. The quantization min value that was used when operand was quantized.
quantization_max_val An int. The quantization max value that was used when operand was quantized.
quantization_axis An optional int. Defaults to -1. Indicates the dimension index of the tensor where per-axis quantization is applied for the slices along that dimension. If set to -1 (default), this indicates per-tensor quantization. Otherwise, it must be set within range [0, operand.dims()).
name A name for the operation (optional).

A Tensor. Has the same type as operand.