Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions sklearn/metrics/_scorer.py
Original file line number Diff line number Diff line change
Expand Up @@ -608,6 +608,14 @@ def _check_multimetric_scoring(estimator, scoring):
return scorers


@validate_params(
{
"score_func": [callable],
"greater_is_better": ["boolean"],
"needs_proba": ["boolean"],
"needs_threshold": ["boolean"],
}
)
def make_scorer(
score_func,
*,
Expand Down
1 change: 1 addition & 0 deletions sklearn/tests/test_public_functions.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,7 @@ def _check_function_param_validation(
"sklearn.metrics.jaccard_score",
"sklearn.metrics.label_ranking_loss",
"sklearn.metrics.log_loss",
"sklearn.metrics.make_scorer",
"sklearn.metrics.matthews_corrcoef",
"sklearn.metrics.max_error",
"sklearn.metrics.mean_absolute_error",
Expand Down