diff options
author | Dwight Lidman <dwight.lidman@arm.com> | 2021-09-29 17:23:03 +0200 |
---|---|---|
committer | Fredrik Svedberg <fredrik.svedberg@arm.com> | 2021-10-12 15:00:28 +0000 |
commit | f54c18dff589f43abcfc57a119d2c1f87a5231ba (patch) | |
tree | b6406c52ed3023124d9860499989b87ec76f64f3 /ethosu/vela | |
parent | 1bf0f1976ae9d9ae8ef1e2c94af885a62276af43 (diff) | |
download | ethos-u-vela-f54c18dff589f43abcfc57a119d2c1f87a5231ba.tar.gz |
MLBEDSW-5284 - MLCE: MEAN batch size constraint
Adds a constraint on batch size for the MEAN
operator. Due to the restrictions imposed by the
NHCWB16 format, some operators do not allow batch
sizes larger than 1. The MEAN operator uses the
operators in its implementation, but the
constraint was missing and thus the operator was
being wrongly placed on the NPU.
Signed-off-by: Dwight Lidman <dwight.lidman@arm.com>
Change-Id: I95e07a9151a6a131c337caa3114da1154be39e49
Diffstat (limited to 'ethosu/vela')
-rw-r--r-- | ethosu/vela/tflite_supported_operators.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/ethosu/vela/tflite_supported_operators.py b/ethosu/vela/tflite_supported_operators.py index 933302f5..d590054f 100644 --- a/ethosu/vela/tflite_supported_operators.py +++ b/ethosu/vela/tflite_supported_operators.py @@ -204,6 +204,7 @@ class TFLiteSupportedOperators: self.specific_constraints[Op.Pad].append(TFLiteSupportedOperators.constraint_pad_type) # Mean specific checks: + self.specific_constraints[Op.Mean].append(TFLiteSupportedOperators.constraint_batch_size) self.specific_constraints[Op.Mean].append(TFLiteSupportedOperators.constraint_mean_height_width_product_avgpool) self.specific_constraints[Op.Mean].append(TFLiteSupportedOperators.constraint_mean_height_width_product) self.specific_constraints[Op.Mean].append(TFLiteSupportedOperators.constraint_mean_height_width_product_int8) |