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

Method WhileContext

tensorflow/core/graph/while_context.cc:20–36  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

18namespace tensorflow {
19
20WhileContext::WhileContext(StringPiece frame_name,
21 std::vector<Node*> enter_nodes,
22 std::vector<Node*> exit_nodes,
23 OutputTensor cond_output,
24 std::vector<OutputTensor> body_inputs,
25 std::vector<OutputTensor> body_outputs)
26 : frame_name_(frame_name),
27 enter_nodes_(std::move(enter_nodes)),
28 exit_nodes_(std::move(exit_nodes)),
29 cond_output_(cond_output),
30 body_inputs_(std::move(body_inputs)),
31 body_outputs_(std::move(body_outputs)) {
32 const size_t num_loop_vars = enter_nodes_.size();
33 DCHECK_EQ(exit_nodes_.size(), num_loop_vars);
34 DCHECK_EQ(body_inputs_.size(), num_loop_vars);
35 DCHECK_EQ(body_outputs_.size(), num_loop_vars);
36}
37
38} // namespace tensorflow

Callers 1

__init__Method · 0.80

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected