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

03_preprocessing -- sparse is sparse_output for newer versions of sklearn's OneHotEncoder #69

Open
jellomoat opened this issue Oct 16, 2024 · 1 comment

Comments

@jellomoat
Copy link
Member

ISSUE: sparse is sparse_output for newer versions of sklearn's OneHotEncoder

LOCATION:

PROPOSED SOLUTION:
Replace sparse with sparse_output on this line =>

dummy_e = OneHotEncoder(categories='auto', drop='first', sparse=False)

Or, add a comment noting this potential change for newer sklearn versions. This error came up during a consulting session debugging issues a consultee encountered running the preprocessing notebook (https://github.com/dlab-consulting/requests/issues/2876).

RELATED REFERENCE: https://scikit-learn.org/dev/modules/generated/sklearn.preprocessing.OneHotEncoder.html

@jellomoat
Copy link
Member Author

jellomoat commented Oct 16, 2024

@tomvannuenen / @pssachdeva -- LMK if you'd like me to submit a PR for this! And if so, how you'd prefer it handled (either of the two proposed solutions, or something else entirely)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant