Skip to content

Commit

Permalink
ap sampling error update
Browse files Browse the repository at this point in the history
  • Loading branch information
nikml committed Mar 7, 2024
1 parent f4fbf7f commit 33f4ad6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions nannyml/sampling_error/binary_classification.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@


# How many experiments to perform when doing resampling to approximate sampling error.
N_EXPERIMENTS = 40
N_EXPERIMENTS = 50
# Max resample size - we don't need full reference if it is too big.
MAX_RESAMPLE_SIZE = 50_000

Expand Down Expand Up @@ -117,7 +117,7 @@ def ap_sampling_error_components(
"""

# we don't need all reference if it's big (save compute)
sample_size = np.minimum(y_true_reference.shape[0], MAX_RESAMPLE_SIZE)
sample_size = np.minimum(y_true_reference.shape[0]//2, MAX_RESAMPLE_SIZE)

y_true_reference = y_true_reference.to_numpy()
y_pred_proba_reference = y_pred_proba_reference.to_numpy()
Expand Down

0 comments on commit 33f4ad6

Please sign in to comment.