Skip to content

Commit

Permalink
Fix blending decoupled cv (#282)
Browse files Browse the repository at this point in the history
* Update __init__.py

Exposing  ClassifierBaseScoreType so kits can use it.

* Update testing.py
  • Loading branch information
kegl authored Nov 2, 2021
1 parent 212720f commit 7d07521
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions rampwf/utils/testing.py
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,8 @@ def blend_submissions(submissions, ramp_kit_dir='.', ramp_data_dir='.',
foldwise_best_predictions_test_list = []
for fold_i, valid_is in enumerate(valid_is_list):
print_title('CV fold {}'.format(fold_i))
ground_truths_valid = problem.Predictions(y_true=y_train[valid_is])
ground_truths_valid = problem.Predictions(
y_true=y_train, fold_is=valid_is)
predictions_valid_list = []
predictions_test_list = []
for submission in submissions:
Expand All @@ -241,7 +242,7 @@ def blend_submissions(submissions, ramp_kit_dir='.', ramp_data_dir='.',
problem, data_path=ramp_data_dir,
input_path=fold_output_path, suffix='test')
predictions_valid = problem.Predictions(
y_pred=y_pred_train[valid_is])
y_pred=y_pred_train, fold_is=valid_is)
predictions_valid_list.append(predictions_valid)
predictions_test = problem.Predictions(y_pred=y_pred_test)
predictions_test_list.append(predictions_test)
Expand Down

0 comments on commit 7d07521

Please sign in to comment.