-
-
Notifications
You must be signed in to change notification settings - Fork 26.4k
[MRG+1] DOC clarify OneClassSVM decision_function docstring #9048
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
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
sklearn/svm/classes.py
Outdated
| def decision_function(self, X): | ||
| """Distance of the samples X to the separating hyperplane. | ||
| """Signed distance to the separating hyperplane: positive if inlier, | ||
| negative if outlier. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
following https://www.python.org/dev/peps/pep-0257/ the first line should be short without line break.
I would write:
"""Signed distance to the separating hyperplane
Signed distance is positive for an inlier and negative for out outlier.
...
|
Thanks @agramfort |
|
thanks @albertcthomas |
…earn#9048) * clarify ocsvm decision_function docstring * take into account agramfort comment
…earn#9048) * clarify ocsvm decision_function docstring * take into account agramfort comment
…earn#9048) * clarify ocsvm decision_function docstring * take into account agramfort comment
…earn#9048) * clarify ocsvm decision_function docstring * take into account agramfort comment
…earn#9048) * clarify ocsvm decision_function docstring * take into account agramfort comment
…earn#9048) * clarify ocsvm decision_function docstring * take into account agramfort comment
…earn#9048) * clarify ocsvm decision_function docstring * take into account agramfort comment
…earn#9048) * clarify ocsvm decision_function docstring * take into account agramfort comment
Reference Issue
This finishes PR #7788 and addresses issue #7713.
What does this implement/fix? Explain your changes.
Clarifies the docstring of the decision function of the
OneClassSVMsaying that positive means inlier and negative means outlier.