aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/core/util/equal_graph_def.h
diff options
context:
space:
mode:
authorGravatar Skye Wanderman-Milne <skyewm@google.com>2017-04-04 16:53:37 -0800
committerGravatar TensorFlower Gardener <gardener@tensorflow.org>2017-04-04 18:05:56 -0700
commit39c74da44a8fe40e83d3b0ec24904bc9ce303581 (patch)
tree59bef5ce34c9b068137b30ce8ed759dbd2adc44c /tensorflow/core/util/equal_graph_def.h
parentc354ba3470a56e271cff63e037509d9fbb253110 (diff)
Make ImportGraphDef() work with functions.
In addition to modify graph_constructor.cc, this patch adds some other functionality to enable importing fucntions: * Ability to add FunctionDefLibraries to Graphs and FunctionLibraryDefinitions (in addition to existing functions) * FunctionDefsEqual() utility function Change: 152205258
Diffstat (limited to 'tensorflow/core/util/equal_graph_def.h')
-rw-r--r--tensorflow/core/util/equal_graph_def.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/tensorflow/core/util/equal_graph_def.h b/tensorflow/core/util/equal_graph_def.h
index 82f8bd0713..1ce6181c2e 100644
--- a/tensorflow/core/util/equal_graph_def.h
+++ b/tensorflow/core/util/equal_graph_def.h
@@ -18,6 +18,7 @@ limitations under the License.
#include "tensorflow/core/framework/graph.pb.h"
#include "tensorflow/core/framework/graph_def_util.h"
+#include "tensorflow/core/platform/protobuf.h"
#include "tensorflow/core/platform/types.h"
namespace tensorflow {
@@ -44,6 +45,14 @@ bool EqualGraphDef(const GraphDef& actual, const GraphDef& expected,
bool EqualNodeDef(const NodeDef& actual, const NodeDef& expected, string* diff,
const EqualGraphDefOptions& options = {});
+// Determines if actual and expected are equal, ignoring ordering. If they're
+// different and diff != nullptr, *diff is set to an explanation of the
+// difference.
+bool EqualRepeatedNodeDef(const protobuf::RepeatedPtrField<NodeDef>& actual,
+ const protobuf::RepeatedPtrField<NodeDef>& expected,
+ string* diff,
+ const EqualGraphDefOptions& options = {});
+
#define TF_EXPECT_GRAPH_EQ(expected, actual) \
do { \
string diff; \