diff options
Diffstat (limited to 'tensorflow/contrib/lite/toco/graph_transformations/resolve_squeeze_attributes.cc')
-rw-r--r-- | tensorflow/contrib/lite/toco/graph_transformations/resolve_squeeze_attributes.cc | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/tensorflow/contrib/lite/toco/graph_transformations/resolve_squeeze_attributes.cc b/tensorflow/contrib/lite/toco/graph_transformations/resolve_squeeze_attributes.cc index e8bb85704e..c601b0774e 100644 --- a/tensorflow/contrib/lite/toco/graph_transformations/resolve_squeeze_attributes.cc +++ b/tensorflow/contrib/lite/toco/graph_transformations/resolve_squeeze_attributes.cc @@ -25,10 +25,13 @@ limitations under the License. namespace toco { -bool ResolveSqueezeAttributes::Run(Model* model, std::size_t op_index) { +::tensorflow::Status ResolveSqueezeAttributes::Run(Model* model, + std::size_t op_index, + bool* modified) { + *modified = false; auto* squeeze_op = model->operators[op_index].get(); if (squeeze_op->type != OperatorType::kSqueeze) { - return false; + return ::tensorflow::Status::OK(); } DCHECK_EQ(squeeze_op->inputs.size(), 1); DCHECK_EQ(squeeze_op->outputs.size(), 1); @@ -42,10 +45,11 @@ bool ResolveSqueezeAttributes::Run(Model* model, std::size_t op_index) { "Reshape op", LogName(*squeeze_op)); - return RemoveTrivialPassthroughOp(this, model, op_index); + *modified = RemoveTrivialPassthroughOp(this, model, op_index); + return ::tensorflow::Status::OK(); } } - return false; + return ::tensorflow::Status::OK(); } } // namespace toco |