Skip to content

Commit

Permalink
improve test stability
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisMRuss committed Jun 20, 2024
1 parent 657cddc commit b90830e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/unittests/test_callable.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@ def square_align(array):
def test_runs(use_fast=True):
fpred = oxonfair.FairPredictor(sigmoid, val_dict, val_groups, inferred_groups=square_align,
use_fast=use_fast)
fpred.fit(gm.accuracy, gm.equal_opportunity, 0.002)
fpred.fit(gm.accuracy, gm.equal_opportunity, 0.005)
tmp = np.asarray(fpred.evaluate(metrics={'eo': gm.equal_opportunity}))[0, 1]
assert tmp < 0.002
assert tmp < 0.005
fpred.plot_frontier()
fpred.plot_frontier(test_dict)
fpred.evaluate()
Expand All @@ -50,9 +50,9 @@ def test_runs_hybrid():

def test_fairdeep(use_fast=True, use_true_groups=False):
fpred = oxonfair.DeepFairPredictor(val_target, val, val_groups, use_fast=use_fast, use_actual_groups=use_true_groups)
fpred.fit(gm.accuracy, gm.equal_opportunity, 0.002)
fpred.fit(gm.accuracy, gm.equal_opportunity, 0.005)
tmp = np.asarray(fpred.evaluate(metrics={'eo': gm.equal_opportunity}))[0, 1]
assert tmp < 0.002
assert tmp < 0.005
fpred.plot_frontier()
fpred.plot_frontier(test_dict)
fpred.evaluate()
Expand Down

0 comments on commit b90830e

Please sign in to comment.