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

Increase precision

parent 26cd30b8
Branches rounding
No related tags found
No related merge requests found
......@@ -135,7 +135,7 @@ class DTreeLearner(LearnerBase):
@staticmethod
def _rounding_feature_vectors(feature_vec_list):
ROUND_TO = 2**10 # 1024
ROUND_TO = 2**15 # 32768
# Rounding to reduce hypothesis spaces
feature_vec_arr = np.array(feature_vec_list)
feature_vec_arr = np.round(feature_vec_arr * ROUND_TO) / ROUND_TO
......
......@@ -7,7 +7,7 @@ from teacher_base import GurobiTeacherBase
class DTreeGurobiTeacherBase(GurobiTeacherBase):
PRECISION = 10**-3
PRECISION = 2**-20
Z3_VAR_RE = re.compile(r"(?P<var>\w+)_(?P<idx>\d+)")
def _build_affine_expr(self, z3_expr: z3.ExprRef):
......
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