Skip to content

Commit 20840f0

Browse files
committed
Disable per-channel quant in requantize_flatbuffer_test
1 parent 829e11f commit 20840f0

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tensorflow/lite/micro/tools/requantize_flatbuffer_test.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
from tflite_micro.tensorflow.lite.tools import flatbuffer_utils
2525

2626

27-
#TODO(b/248061370): replace the keras model creation process with flatbuffer manipulation to speed up test
27+
# TODO(b/248061370): replace the keras model creation process with flatbuffer manipulation to speed up test
2828
def create_simple_fc_model():
2929
'''Create a simple model with two fully connected(fc) layers'''
3030
model = tf.keras.models.Sequential([
@@ -60,6 +60,8 @@ def convert_tfl_converter(keras_model,
6060
EXPERIMENTAL_TFLITE_BUILTINS_ACTIVATIONS_INT16_WEIGHTS_INT8
6161
]
6262
converter.representative_dataset = representative_dataset_gen
63+
# TODO(b/324385802): Support per-channel quantization for FullyConnected.
64+
converter._experimental_disable_per_channel_quantization_for_dense_layers = True
6365
return converter.convert()
6466

6567

0 commit comments

Comments
 (0)