From 5a95c76c8e0c8eb6e84707c484341cac14e989c9 Mon Sep 17 00:00:00 2001 From: "A. Unique TensorFlower" Date: Fri, 17 Mar 2017 08:54:03 -0800 Subject: Set producer version in the graph used by shape refiner to run constant folding. Change: 150450219 --- tensorflow/core/common_runtime/shape_refiner.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tensorflow/core/common_runtime/shape_refiner.cc b/tensorflow/core/common_runtime/shape_refiner.cc index 7288ecb143..2f65abde0a 100644 --- a/tensorflow/core/common_runtime/shape_refiner.cc +++ b/tensorflow/core/common_runtime/shape_refiner.cc @@ -203,6 +203,9 @@ Status ShapeRefiner::EvaluateConstantTensorForEdge(const Node* node, bool is_constant_graph = false; Graph subgraph(ops_registry_); + auto versions = subgraph.versions(); + versions.set_producer(graph_def_version_); + subgraph.set_versions(versions); // We identify the possibly constant subgraph to evaluate by // recursively iterating backwards through the inputs to 'node' -- cgit v1.2.3