aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/contrib/lite/toco/graph_transformations/resolve_strided_slice_attributes.cc
diff options
context:
space:
mode:
authorGravatar A. Unique TensorFlower <gardener@tensorflow.org>2017-12-08 10:40:45 -0800
committerGravatar TensorFlower Gardener <gardener@tensorflow.org>2017-12-08 10:46:24 -0800
commit29e72226e76b8221800e6bc7154007181d3edef7 (patch)
treeb6496f26e93666cd85e08f975bb52ef328d33b95 /tensorflow/contrib/lite/toco/graph_transformations/resolve_strided_slice_attributes.cc
parentf186c481cfdf145a517bfbc396bc992618ed9ec5 (diff)
Misc improvements required for some internal model:
- handle StopGradient as an Identity node. So far we had refrained from supporting it as a smoking gun for a graph being a training not inference graph, but the resulting friction is proving not worth it at the moment. - Relax a couple of conditions that we were fatal-erroring on early (during graph transformations) even as they only were necessary preconditions for much later code (some internal export formats). Erroring early is nice, but the existence of multiple output formats with very diverse requirements makies it unnecessary friction to error early. Here, when the output format is GRAPHVIZ_DOT, we do want to continue in these cases. - add some verbose logging in propagate_fixed_sizes. PiperOrigin-RevId: 178395479
Diffstat (limited to 'tensorflow/contrib/lite/toco/graph_transformations/resolve_strided_slice_attributes.cc')
-rw-r--r--tensorflow/contrib/lite/toco/graph_transformations/resolve_strided_slice_attributes.cc5
1 files changed, 0 insertions, 5 deletions
diff --git a/tensorflow/contrib/lite/toco/graph_transformations/resolve_strided_slice_attributes.cc b/tensorflow/contrib/lite/toco/graph_transformations/resolve_strided_slice_attributes.cc
index 5fc3b25bc1..851511268d 100644
--- a/tensorflow/contrib/lite/toco/graph_transformations/resolve_strided_slice_attributes.cc
+++ b/tensorflow/contrib/lite/toco/graph_transformations/resolve_strided_slice_attributes.cc
@@ -50,11 +50,6 @@ bool ResolveStridedSliceAttributes::Run(Model* model, std::size_t op_index) {
op->stop_indices = stop_array.GetBuffer<ArrayDataType::kInt32>().data;
op->strides = stride_array.GetBuffer<ArrayDataType::kInt32>().data;
- // Only 4D arrays are supported for now.
- CHECK_EQ(op->start_indices.size(), 4);
- CHECK_EQ(op->stop_indices.size(), 4);
- CHECK_EQ(op->strides.size(), 4);
-
// TODO(dkalenichenko): Delete the extra inputs?
return true;