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

OPTIM use pairwise_distances_argmin in NearestCentroid.predict #24645

Merged

Conversation

ogrisel
Copy link
Member

@ogrisel ogrisel commented Oct 12, 2022

Small optim to reduce memory usage when both X.shape[0] and centroids_.shape[0] are large.

@ogrisel ogrisel added the Quick Review For PRs that are quick to review label Oct 12, 2022
Copy link
Member

@thomasjpfan thomasjpfan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Member

@jjerphan jjerphan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks for having spotted this!

doc/whats_new/v1.2.rst Outdated Show resolved Hide resolved
Co-authored-by: Julien Jerphanion <[email protected]>
@ogrisel ogrisel merged commit e01035d into scikit-learn:main Oct 13, 2022
@ogrisel ogrisel deleted the nearest-centroid-pairwise_distances_argmin branch October 13, 2022 15:58
glemaitre pushed a commit to glemaitre/scikit-learn that referenced this pull request Oct 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
module:neighbors Performance Quick Review For PRs that are quick to review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants