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

Function BM_GraphViewGetFanouts

tensorflow/core/grappler/graph_view_test.cc:439–452  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

437RUN_FANIN_FANOUT_BENCHMARK(BM_GraphViewGetRegularFanin);
438
439static void BM_GraphViewGetFanouts(int iters, int num_fanins, int num_fanouts) {
440 testing::StopTiming();
441 const GraphDef graph_def = test::CreateFaninFanoutNodeGraph(
442 num_fanins, num_fanouts, num_fanins, num_fanouts,
443 /*fanout_unique_index=*/true);
444 GraphView graph_view(&graph_def);
445
446 testing::StartTiming();
447 for (int i = 0; i < iters; ++i) {
448 const NodeDef* node = graph_view.GetNode("node");
449 graph_view.GetFanouts(*node, /*include_controlled_nodes=*/false);
450 }
451 testing::StopTiming();
452}
453
454RUN_FANIN_FANOUT_BENCHMARK(BM_GraphViewGetFanouts);
455

Callers

nothing calls this directly

Calls 5

StopTimingFunction · 0.85
StartTimingFunction · 0.85
GetFanoutsMethod · 0.80
GetNodeMethod · 0.45

Tested by

no test coverage detected