From 95eb69d68aff1aaa4fb19095c6d082aa873ad16f Mon Sep 17 00:00:00 2001 From: yeyunpeng2020 Date: Mon, 16 May 2022 15:28:22 +0800 Subject: [PATCH] fix min_quant_weight_size_ bug --- mindspore/lite/tools/converter/quantizer/quant_strategy.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mindspore/lite/tools/converter/quantizer/quant_strategy.cc b/mindspore/lite/tools/converter/quantizer/quant_strategy.cc index ee5150764c7..2ed1de9cded 100644 --- a/mindspore/lite/tools/converter/quantizer/quant_strategy.cc +++ b/mindspore/lite/tools/converter/quantizer/quant_strategy.cc @@ -62,7 +62,7 @@ bool QuantStrategy::CanTensorQuantized(const CNodePtr &cnode, const AnfNodePtr & MS_LOG(ERROR) << "Get element num from shape failed."; return ret; } - if (total_shape_size < 0 || static_cast(total_shape_size) < min_quant_weight_size_) { + if (total_shape_size < 0 || static_cast(total_shape_size) <= min_quant_weight_size_) { MS_LOG(INFO) << "shape_size " << total_shape_size << " less min_quant_weight_size_ " << min_quant_weight_size_; return false; }