MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / GraphConstructorOptions

Class GraphConstructorOptions

tensorflow/core/graph/graph_constructor.h:33–45  ·  view source on GitHub ↗

Construct a Graph *g out of a GraphDef gdef. Returns non-OK on error, in which case *g is left in an incomplete state. g is expected to be an empty graph (with no more than a source and sink nodes) when provided to ConvertGraphDefToGraph. To enhance an existing Graph, see ImportGraphDef.

Source from the content-addressed store, hash-verified

31// nodes) when provided to ConvertGraphDefToGraph. To enhance an existing Graph,
32// see ImportGraphDef.
33struct GraphConstructorOptions {
34 GraphConstructorOptions() {}
35
36 // If true, allows internal ops in the GraphDef.
37 bool allow_internal_ops = false;
38
39 // If true, the graph def is expected to have fully specified
40 // devices for all nodes. A node in the resulting graph "g" has the
41 // device name set accordingly.
42 //
43 // TODO(zhifengc): if possible, consider removing this option.
44 bool expect_device_spec = false;
45};
46extern Status ConvertGraphDefToGraph(const GraphConstructorOptions& opts,
47 const GraphDef& gdef, Graph* g);
48extern Status ConvertGraphDefToGraph(const GraphConstructorOptions& opts,

Callers 5

AnalyzeAndVerifyFunction · 0.85
InitGraphFunction · 0.85
ConvertAfterShapesFunction · 0.85
OptimizeGraphFunction · 0.85

Calls

no outgoing calls

Tested by 1

AnalyzeAndVerifyFunction · 0.68