In Tensorflow version > 2.1.0, there is a bug induced in Tensorflow, where if we try to use Quantized PadV2 with constant value input, it fails to covert to TFLite because of mismatch in output quant params & the constant value quant params.
Pseudo code:
quant_output = pad_v2(quant_data, padding, mode="CONSTANT", quant_constant_values)
Error:
RuntimeError: tensorflow/lite/kernels/pad.cc:205 op_context.output->params.zero_point != op_context.constant_values->params.zero_point (128 != 0)
For test case, please refer
This is a tracker until bug is fixed in Tensorflow.