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

Method DumpGraphWithCondState

tensorflow/compiler/tf2xla/functionalize_cond.cc:1523–1535  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1521}
1522
1523void FunctionalizeCond::DumpGraphWithCondState(const string& name) {
1524 const char* const kCondGroupDebugAttr = "_XlaFunctionalizeCondGroup";
1525
1526 for (Node* n : graph_->nodes()) {
1527 n->ClearAttr(kCondGroupDebugAttr);
1528 n->AddAttr(kCondGroupDebugAttr,
1529 absl::StrCat(state_map_.CondStateToString(n), "_",
1530 state_map_.AncestorStateToString(n)));
1531 }
1532 LOG(INFO) << "FunctionalizeControlFlow (" << name << "): "
1533 << DumpGraphToFile(absl::StrCat("functionalize_cond_", name),
1534 *graph_, library_);
1535}
1536
1537void FunctionalizeCond::AddSwitchId(int switch_id) {
1538 switch_ids_.push_back(switch_id);

Callers

nothing calls this directly

Calls 7

DumpGraphToFileFunction · 0.85
ClearAttrMethod · 0.80
AddAttrMethod · 0.80
CondStateToStringMethod · 0.80
AncestorStateToStringMethod · 0.80
StrCatFunction · 0.50
nodesMethod · 0.45

Tested by

no test coverage detected