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

Method new_cond_branch

tensorflow/python/autograph/pyct/cfg.py:524–536  ·  view source on GitHub ↗

Begins a new branch in a cond section.

(self, section_id)

Source from the content-addressed store, hash-verified

522 self.cond_leaves[section_id] = []
523
524 def new_cond_branch(self, section_id):
525 """Begins a new branch in a cond section."""
526 assert section_id in self.cond_leaves
527
528 if section_id in self.cond_entry:
529 # Subsequent splits move back to the split point, and memorize the
530 # current leaves.
531 self.cond_leaves[section_id].append(self.leaves)
532 self.leaves = self.cond_entry[section_id]
533 else:
534 # If this is the first time we split a section, just remember the split
535 # point.
536 self.cond_entry[section_id] = self.leaves
537
538 def exit_cond_section(self, section_id):
539 """Exits a conditional section."""

Callers 2

visit_IfMethod · 0.80
visit_TryMethod · 0.80

Calls 1

appendMethod · 0.45

Tested by

no test coverage detected