Skip to content

Commit

Permalink
make double-checking optional
Browse files Browse the repository at this point in the history
  • Loading branch information
Roman Andriushchenko committed Dec 8, 2023
1 parent 5e58cc6 commit 951e73d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion paynt/synthesizer/policy_tree.py
Original file line number Diff line number Diff line change
Expand Up @@ -364,6 +364,8 @@ class SynthesizerPolicyTree(paynt.synthesizer.synthesizer.Synthesizer):

# if True, then the game scheduler will be used for splitting (incompatible with randomized abstraction)
use_optimistic_splitting = True
# if True, tree leaves will be double-checked after synthesis
double_check_policy_tree_leaves = False

@property
def method_name(self):
Expand Down Expand Up @@ -785,7 +787,8 @@ def synthesize_policy_tree(self, family):
policy_tree_node.split(result.splitter,suboptions,subfamilies)
policy_tree_leaves = policy_tree_leaves + policy_tree_node.child_nodes

policy_tree.double_check(self.quotient, prop)
if SynthesizerPolicyTree.double_check_policy_tree_leaves:
policy_tree.double_check(self.quotient, prop)
policy_tree.print_stats()
policy_tree.postprocess(self.quotient, prop)
return policy_tree
Expand Down

0 comments on commit 951e73d

Please sign in to comment.