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

Function RewriteBatchNode

tensorflow/core/grappler/optimizers/data/rebatch.cc:586–593  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

584}
585
586Status RewriteBatchNode(const NodeDef& batch_node, int64 num_replicas,
587 FunctionLibraryDefinition* flib,
588 MutableGraphView* graph) {
589 if (ShouldMutateBatchSizeDirectly(batch_node, num_replicas, graph)) {
590 return MutateBatchSize(batch_node, num_replicas, graph);
591 }
592 return AppendFlatMap(batch_node, num_replicas, flib, graph);
593}
594
595Status OptimizeGraph(const GrapplerItem& item, int64 num_replicas,
596 bool use_fallback, GraphDef* output);

Callers 1

RecursivelyHandleOpFunction · 0.85

Calls 3

MutateBatchSizeFunction · 0.85
AppendFlatMapFunction · 0.85

Tested by

no test coverage detected