未验证 提交 25c40a78 编写于 作者: 走神的阿圆's avatar 走神的阿圆 提交者: GitHub

fix list not support add_pr_curve (#810)

上级 66b1f9b9
......@@ -262,6 +262,10 @@ def compute_curve(labels, predictions, num_thresholds=None, weights=None):
num_thresholds (int): Number of thresholds used to draw the curve.
weights (float): Multiple of data to display on the curve.
"""
if isinstance(labels, list):
labels = np.array(labels)
if isinstance(predictions, list):
predictions = np.array(predictions)
_MINIMUM_COUNT = 1e-7
if weights is None:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册