Hello, here is my code:
for epsilon in np.arange(min(p_val), max(p_val), step_size):
### START CODE HERE ###
# moderator edit: code removed
### END CODE HERE ###
After run the test code, I got the error as following:
Best epsilon found using cross-validation: 8.990853e-05
Best F1 on Cross Validation Set: 0.056962
AssertionError Traceback (most recent call last)
in
6
7 # UNIT TEST
----> 8 select_threshold_test(select_threshold)
~/work/public_tests.py in select_threshold_test(target)
7
8 best_epsilon, best_F1 = target(y_val, p_val)
----> 9 assert np.isclose(best_epsilon, 0.04, atol=0.3 / 1000), f"Wrong best_epsilon. Expected: {0.04} got: {best_epsilon}"
10 assert best_F1 == 1, f"Wrong best_F1. Expected: 1 got: {best_F1}"
11
AssertionError: Wrong best_epsilon. Expected: 0.04 got: 0.00029
What is the problem? Thanks!