Skip to content

Conversation

samtalki
Copy link

@samtalki samtalki commented Jan 30, 2021

Numpy requires the use of masking for all boolean array indexing on non 1 or 0-d arrays. Therefore the following line breaks all estimators when using the conventional Nx1 sklearn data format for regression, which this library also requires.

pred[ind] = p

More details: https://stackoverflow.com/questions/60079094/python-error-numpy-boolean-array-indexing-assignment-requires-a-0-or-1-dimensi

This commit uses a mask to fix this.

Numpy requires the use of masking for all boolean array indexing on non 1 or 0-d arrays. Therefore the following line breaks all estimators when using the conventional Nx1 sklearn data format for regression, which this library also requires.

pred[ind] = p

This commit uses a mask to fix this.
@samtalki samtalki marked this pull request as draft February 1, 2021 16:03
@sdpython
Copy link
Owner

I'll close this PR as the changes have been merged.

@sdpython sdpython closed this Sep 27, 2021
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

Successfully merging this pull request may close these issues.

2 participants