使用布里尔分数报错

350 阅读1分钟
brier_score_loss(y_true,y_prob = svc_prob[:,1],pos_label=1)

报错信息:ValueError: Only binary classification is supported. The type of the target is multiclass.

新版sklearn中布里尔分数只能计算二分类了!!!

我们可以将sklearn的版本更新成:0.20.1 ,这个版本不会报错