diff options
author | Johan Alfven <johan.alfven@arm.com> | 2023-04-03 15:29:13 +0200 |
---|---|---|
committer | Johan Alfven <johan.alfven@arm.com> | 2023-04-04 15:44:15 +0200 |
commit | 347c57bb88c1286bcd1c2775e7c67296410e2e6d (patch) | |
tree | 98c209e597be597b67853bfc0ee50c255dac1370 /ethosu/vela/tflite_graph_optimiser.py | |
parent | 56811e6d3c62ae017f6eb298fb553f7d1e77cc96 (diff) | |
download | ethos-u-vela-347c57bb88c1286bcd1c2775e7c67296410e2e6d.tar.gz |
MLBEDSW-7442: Removed ofm quantization for ArgMax
- Quantization for the OFM was added for the ArgMax operator
as a workaround in order to avoid a crash in the weight compressor.
This quantization is now removed.
- The weight compressor expects that all tensors have a quantization.
Updated code to use scale = 1.0 and zero point = 0 for tensor without
quantization.
Change-Id: I6816dce2db55f7d795d19f88d7fbe7ee419347fc
Signed-off-by: Johan Alfven <johan.alfven@arm.com>
Diffstat (limited to 'ethosu/vela/tflite_graph_optimiser.py')
-rw-r--r-- | ethosu/vela/tflite_graph_optimiser.py | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/ethosu/vela/tflite_graph_optimiser.py b/ethosu/vela/tflite_graph_optimiser.py index e0c7fd2c..5b0e2fb3 100644 --- a/ethosu/vela/tflite_graph_optimiser.py +++ b/ethosu/vela/tflite_graph_optimiser.py @@ -501,8 +501,6 @@ def convert_argmax_to_depthwise_conv_and_max_pool(op, arch, nng): identity_quant = QuantizationParameters() identity_quant.zero_point = 0 identity_quant.scale_f32 = 1.0 - if ofm.quantization is None: - ofm.quantization = identity_quant # Add last dimension to ofm shape ofm.shape += [1] ofm.ops = [] |