8000 Apparent mismatch between possible arguments for `average` in the base stochastic gradient class · Issue #28389 · scikit-learn/scikit-learn · GitHub
[go: up one dir, main page]

Skip to content
Apparent mismatch between possible arguments for average in the base stochastic gradient class #28389
Closed
@bmgdc

Description

@bmgdc

Describe the bug

Raised in #28373 (comment).

The average parameter in BaseSGD (which propagates to SGDRegressor, SGDClassifier and SGDOneClassSVM) is constrained to non-negative integers or boolean values: "average": [Interval(Integral, 0, None, closed="left"), bool, np.bool_].

This seems to be at odds with average=0 seemingly meaning average=True which contradicts the typical truth-evaluation of 0.

Steps/Code to Reproduce

Expected Results

Actual Results

Versions

This is in the main branch right now.

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugValidationrelated to input validation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0