diff options
author | 2018-02-20 13:57:01 -0800 | |
---|---|---|
committer | 2018-02-20 14:00:54 -0800 | |
commit | 0fad3428f4de84e10524a7ed5ed53b7e4b636edb (patch) | |
tree | 718b5b1fe2133a473493d80b5264827e1057891b /tensorflow/contrib/lite/toco/export_tensorflow.cc | |
parent | fdeab946c0c8146c8040d7e125e5ca9e41b0336a (diff) |
Basic LogSoftmax support
PiperOrigin-RevId: 186357933
Diffstat (limited to 'tensorflow/contrib/lite/toco/export_tensorflow.cc')
-rw-r--r-- | tensorflow/contrib/lite/toco/export_tensorflow.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tensorflow/contrib/lite/toco/export_tensorflow.cc b/tensorflow/contrib/lite/toco/export_tensorflow.cc index 570cc7943b..d54014aaaf 100644 --- a/tensorflow/contrib/lite/toco/export_tensorflow.cc +++ b/tensorflow/contrib/lite/toco/export_tensorflow.cc @@ -720,7 +720,8 @@ void ConvertLogSoftmaxOperator(const Model& model, GraphDef* tensorflow_graph) { string softmax_input; Operator* providing_op = GetOpWithOutput(model, src_op.inputs[0]); - if (providing_op->type == OperatorType::kTensorFlowReshape) { + if (providing_op != nullptr && + providing_op->type == OperatorType::kTensorFlowReshape) { softmax_input = src_op.inputs[0]; } else { // Insert a reshape operator that reduces the dimensions down to the 2 that |