Skip to content
Snippets Groups Projects
Commit cb772cc2 authored by chsieh16's avatar chsieh16
Browse files

Remove spurious cex validation

parent 52c8e4ec
No related branches found
No related tags found
No related merge requests found
......@@ -91,7 +91,7 @@ def synth_dtree(learner: Learner, teacher: Teacher, num_max_iterations: int = 10
assert len(negative_examples) > 0
print(f"negative examples: {negative_examples}")
assert validate_cexs(teacher.state_dim, teacher.perc_dim, candidate, negative_examples)
# assert validate_cexs(teacher.state_dim, teacher.perc_dim, candidate, negative_examples)
learner.add_negative_examples(*negative_examples)
continue
......
......@@ -72,7 +72,7 @@ class DTreeGEMStanleyGurobiTeacher(GEMStanleyGurobiTeacher):
else: # !(lhs <= rhs) <=> (lhs > rhs) => lhs >= rhs + ð
cons = (lhs >= rhs + self.PRECISION)
else:
raise RuntimeError(f"Unsupprted atomic predicate expression {pred}")
raise RuntimeError(f"Unsupported atomic predicate expression {pred}")
gp_cons = self._gp_model.addConstr(cons)
self._prev_candidate_constr.append(gp_cons)
......@@ -138,7 +138,8 @@ class DTreeGEMStanleyGurobiTeacher(GEMStanleyGurobiTeacher):
if filtered_cex_list:
self._cexs.extend(filtered_cex_list)
else:
raise RuntimeError(f"Only found spurious cexs {cex_list} for the conjuct {conjunct}.")
# raise RuntimeError(f"Only found spurious cexs {cex_list} for the conjuct {conjunct}.")
pass
elif self._gp_model.status == gp.GRB.INFEASIBLE:
continue
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment