aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/core/protobuf
diff options
context:
space:
mode:
authorGravatar Jingyue Wu <jingyue@google.com>2017-10-13 12:54:33 -0700
committerGravatar TensorFlower Gardener <gardener@tensorflow.org>2017-10-13 12:58:20 -0700
commitd871fdce70acc165e652c66638943b40ffcda7a3 (patch)
treed95362911a5e695dd808bcea56a50776a516fa06 /tensorflow/core/protobuf
parent3f82236798b02ddb0b00b25c23e7443b6dbf5c01 (diff)
[Grappler] Remove reshapes whose source shape and destination shape are equal.
Also makes ArithmeticOptimizer::Optimize run shape inference at the beginning, and clear _output_shapes at the end. PiperOrigin-RevId: 172133948
Diffstat (limited to 'tensorflow/core/protobuf')
-rw-r--r--tensorflow/core/protobuf/rewriter_config.proto4
1 files changed, 4 insertions, 0 deletions
diff --git a/tensorflow/core/protobuf/rewriter_config.proto b/tensorflow/core/protobuf/rewriter_config.proto
index 8a8dd3c7d5..d67088311b 100644
--- a/tensorflow/core/protobuf/rewriter_config.proto
+++ b/tensorflow/core/protobuf/rewriter_config.proto
@@ -23,6 +23,10 @@ message RewriterConfig {
DEFAULT = 0;
ON = 1;
OFF = 2;
+ // Enable some aggressive optimizations that use assumptions that TF graphs
+ // may break. For example, assume the shape of a placeholder matches its
+ // actual feed.
+ AGGRESSIVE = 3;
}
// Optimize tensor layouts