Browse Source

!14614 fix tflite model parser

From: @zhaodezan
Reviewed-by: @zhang_xue_tong,@zhanghaibo5
Signed-off-by: @zhang_xue_tong
pull/14614/MERGE
mindspore-ci-bot Gitee 4 years ago
parent
commit
1353aa94a6
1 changed files with 1 additions and 3 deletions
  1. +1
    -3
      mindspore/lite/tools/converter/parser/tflite/tflite_model_parser.cc

+ 1
- 3
mindspore/lite/tools/converter/parser/tflite/tflite_model_parser.cc View File

@@ -370,9 +370,7 @@ STATUS TfliteModelParser::ConvertConstTensor(const tflite::TensorT *tensor, cons

const auto &data = tflite_model_buffers.at(tensor->buffer)->data;
std::string shape_str;
if (data.empty()) {
shape_vector = {};
} else if (type_id == kObjectTypeString) {
if (type_id == kObjectTypeString) {
shape_str += std::to_string(tensor->shape.size()) + ",";
for (auto &dim : tensor->shape) {
shape_str += std::to_string(dim) + ",";


Loading…
Cancel
Save