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

Function CollectiveReduceNode

tensorflow/core/graph/collective_order_test.cc:79–95  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

77}
78
79Node* CollectiveReduceNode(GraphDefBuilder* builder, Node* input,
80 const string& name, const string& device,
81 int instance_key) {
82 Node* collective_node =
83 ops::UnaryOp("CollectiveReduce", input,
84 builder->opts()
85 .WithName(name)
86 .WithDevice(device)
87 .WithAttr("T", DT_FLOAT)
88 .WithAttr("group_size", 2)
89 .WithAttr("group_key", 1)
90 .WithAttr("instance_key", instance_key)
91 .WithAttr("merge_op", "Add")
92 .WithAttr("final_op", "Id")
93 .WithAttr("subdiv_offsets", {1}));
94 return collective_node;
95}
96
97// Initialize the following graph:
98//

Callers 3

InitGraphFunction · 0.85
InitGraph2Function · 0.85
InitGraphForPruningFunction · 0.85

Calls 4

WithAttrMethod · 0.80
UnaryOpFunction · 0.70
WithDeviceMethod · 0.45
WithNameMethod · 0.45

Tested by

no test coverage detected