Skip to content

Commit

Permalink
Keras int input error fix (#2815)
Browse files Browse the repository at this point in the history
* Fixed error facing, when input to Keras model is Int type

Signed-off-by: Rishabh Kumar Jain <quic_rij@quicinc.com>
  • Loading branch information
quic-rij authored and Thakur, Rishabh committed Mar 8, 2024
1 parent ed6645e commit e068c40
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ def _initialize_input_quantizers(layer: layers.Layer, quant_settings: QuantizerS
quant_settings.is_symmetric,
quant_settings.use_strict_symmetric,
quant_settings.use_unsigned_symmetric,
enabled and layer.output.dtype in QUANT_ALLOWED_DTYPES)
enabled and (layer.input[i].dtype if num_inputs > 1 else layer.input.dtype) in QUANT_ALLOWED_DTYPES)
input_quantizers.append(activation_tensor_quantizer)
return input_quantizers

Expand Down

0 comments on commit e068c40

Please sign in to comment.