We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bf8dffc commit 1d557d8Copy full SHA for 1d557d8
xgboost_bench/gbt.py
@@ -29,7 +29,7 @@ def convert_xgb_predictions(y_pred, objective):
29
if objective == 'multi:softprob':
30
y_pred = convert_probs_to_classes(y_pred)
31
elif objective == 'binary:logistic':
32
- y_pred = y_pred.astype(np.int32)
+ y_pred = (y_pred >= 0.5).astype(np.int32)
33
return y_pred
34
35
0 commit comments