Skip to content
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

fbeta_score does not accept beta=0 #13224

Closed
wdevazelhes opened this issue Feb 22, 2019 · 3 comments · Fixed by #13231
Closed

fbeta_score does not accept beta=0 #13224

wdevazelhes opened this issue Feb 22, 2019 · 3 comments · Fixed by #13231
Labels
Easy Well-defined and straightforward way to resolve good first issue Easy with clear instructions to resolve help wanted Sprint

Comments

@wdevazelhes
Copy link
Contributor

fbeta_score does not accept beta=0. In this case I agree that we could use precision_score which is the same, but is there a reason why this fbeta_score(... beta=0) would be forbidden ? If not I'd be happy to provide a PR. These are the lines that I would delete (plus I would provide a test):

if beta <= 0:
raise ValueError("beta should be >0 in the F-beta score")

What is more, this case is even mentioned in the documentation ("beta -> 0 considers only precision, beta -> inf only recall)"), so we would reasonably expect it to work ? https://scikit-learn.org/stable/modules/generated/sklearn.metrics.fbeta_score.html

@qinhanmin2014
Copy link
Member

Seems reasonable from my side.

@qinhanmin2014 qinhanmin2014 added Easy Well-defined and straightforward way to resolve good first issue Easy with clear instructions to resolve help wanted labels Feb 22, 2019
@corona10
Copy link
Contributor

corona10 commented Feb 23, 2019

@qinhanmin2014 Can I take a look at this issue?

@qinhanmin2014
Copy link
Member

@qinhanmin2014 Can I take a look at this issue?

Welcome to contribute.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Easy Well-defined and straightforward way to resolve good first issue Easy with clear instructions to resolve help wanted Sprint
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants