-
-
Notifications
You must be signed in to change notification settings - Fork 26.2k
fix default value for class LinearSVC #16077
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
sorry, mistakenly closed the pull request. reopen it again |
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.
Thank you for the PR @junzhaous !
@@ -26,28 +26,28 @@ class LinearSVC(BaseEstimator, LinearClassifierMixin, | |||
|
|||
Parameters | |||
---------- | |||
penalty : str, 'l1' or 'l2' (default='l2') | |||
penalty : str, 'l1' or 'l2' default='l2' |
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.
penalty : str, 'l1' or 'l2' default='l2' | |
penalty : {'l1', 'l2'}, default='l2' |
Specifies the norm used in the penalization. The 'l2' | ||
penalty is the standard used in SVC. The 'l1' leads to ``coef_`` | ||
vectors that are sparse. | ||
|
||
loss : str, 'hinge' or 'squared_hinge' (default='squared_hinge') | ||
loss : str, 'hinge' or 'squared_hinge', default='squared_hinge' |
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.
loss : str, 'hinge' or 'squared_hinge', default='squared_hinge' | |
loss : {'hinge', 'squared_hinge'}, default='squared_hinge' |
Regularization parameter. The strength of the regularization is | ||
inversely proportional to C. Must be strictly positive. | ||
|
||
multi_class : str, 'ovr' or 'crammer_singer' (default='ovr') | ||
multi_class : str, 'ovr' or 'crammer_singer',default='ovr' |
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.
multi_class : str, 'ovr' or 'crammer_singer',default='ovr' | |
multi_class : {'ovr' or 'crammer_singer'}, default='ovr' |
Enable verbose output. Note that this setting takes advantage of a | ||
per-process runtime setting in liblinear that, if enabled, may not work | ||
properly in a multithreaded context. | ||
|
||
random_state : int, RandomState instance or None, optional (default=None) | ||
random_state : int, RandomState instance or None, default=None |
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.
random_state : int, RandomState instance or None, default=None | |
random_state : int, RandomState instance, default=None |
Already addressed in #16060 which was opened earlier. Closing this PR. |
Reference Issues/PRs
Fix documentation of default values in all classes good first issue help wanted
#15761
What does this implement/fix? Explain your changes.
This is my first contribution. I removed some optional key words and standardized default value as default=. Also I set the default value of class weight to 1 as the specification.
All above changes are made for class LinearSVC
Any other comments?