Skip to content

intercept_scaling should be set explicitly #11715

Open

Description

@jnothman

I think we should warn the user when liblinear is used (in LinearSVC/R or LogisticRegression) and fit_intercept is used, if they do not explicitly set intercept_scaling. This is to improve awareness of liblinear's failure to regularise the intercept.

I would propose:

  • Set the default intercept_scaling to 'warn'
  • Raise a UserWarning if fit_intercept and intercept_scaling == 'warn'

Activity

  1. adrinjalali commented on Aug 6, 2018

    @adrinjalali
    Member

    @jnothman could you please tell me if the change on LogisticRegression as I've done in PR #11763 is what you want? Then I can modify the other classes as well.

    Another question: should the docstring of those classes be modified?

  2. adrinjalali commented on May 28, 2020

    @adrinjalali
    Member

    we need to decide whether we want to warn or not. The PR addressing this didn't get merged due to concerns regarding too many warnings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions