Thanks to visit codestin.com
Credit goes to github.com

Skip to content

MAINT Parameters validation for metrics.roc_curve #25108

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

eagle-owly
Copy link
Contributor

@eagle-owly eagle-owly commented Dec 4, 2022

Reference Issues/PRs

Towards #24862

What does this implement/fix? Explain your changes.

Includes parameter validation for metrics.roc_curve

Any other comments?

Test passes pytest -vl sklearn/tests/test_public_functions.py

@eagle-owly eagle-owly changed the title MAINT Parameters validation for metrics.roc_curve MAINT Parameters validation for metrics.roc_curve Dec 4, 2022
@betatim
Copy link
Member

betatim commented Dec 5, 2022

Thanks for working on this. The change looks reasonable to me.

The linting tests that check the formatting of the code are failing. Take a look at step 9 of https://scikit-learn.org/stable/developers/contributing.html#how-to-contribute or the section after that for the tools you need to run to have the formatting fixed automatically. The easiest way is to use pre-commit.

@jeremiedbb jeremiedbb added the Validation related to input validation label Dec 5, 2022
@eagle-owly
Copy link
Contributor Author

Thanks @betatim, I think I solved it.
Only one is failing now, so I believe that "No Changelog Needed".

Copy link
Member

@betatim betatim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Ready for a second reviewer

@betatim betatim added the Waiting for Second Reviewer First reviewer is done, need a second one! label Dec 6, 2022
Copy link
Member

@jeremiedbb jeremiedbb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR @miningknowledge. It's true that array-likes are valid, not just ndarrays as the docstring says. Could you update the parameter description of y_true and y_score ?

@eagle-owly
Copy link
Contributor Author

Thanks for the PR @miningknowledge. It's true that array-likes are valid, not just ndarrays as the docstring says. Could you update the parameter description of y_true and y_score ?

@jeremiedbb good point, done

Copy link
Member

@jeremiedbb jeremiedbb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks @miningknowledge

@jeremiedbb jeremiedbb enabled auto-merge (squash) December 6, 2022 22:27
@jeremiedbb jeremiedbb merged commit 6643c2c into scikit-learn:main Dec 6, 2022
@glemaitre
Copy link
Member

Interestingly we broke the documentation CI :)

jjerphan pushed a commit to jjerphan/scikit-learn that referenced this pull request Jan 20, 2023
jjerphan pushed a commit to jjerphan/scikit-learn that referenced this pull request Jan 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
module:metrics No Changelog Needed Validation related to input validation Waiting for Second Reviewer First reviewer is done, need a second one!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants