Skip to content

adding return_centers param#15709

Merged
qinhanmin2014 merged 8 commits into
scikit-learn:masterfrom
venkyyuvy:return_center
Jan 22, 2020
Merged

adding return_centers param#15709
qinhanmin2014 merged 8 commits into
scikit-learn:masterfrom
venkyyuvy:return_center

Conversation

@venkyyuvy
Copy link
Copy Markdown
Contributor

@venkyyuvy venkyyuvy commented Nov 23, 2019

Reference Issues/PRs: Fixes #15684

What does this implement/fix? Explain your changes.

Added a param to return the centers of each cluster in make_blobs and added a test for it

Copy link
Copy Markdown
Member

@NicolasHug NicolasHug left a comment

Choose a reason for hiding this comment

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

Thanks @venkyyuvy , looks good.

This would need a what's new entry (in 0.23). Maybe we can also credit @shivamgargsya's work

Comment thread sklearn/datasets/_samples_generator.py Outdated
Comment thread sklearn/datasets/_samples_generator.py Outdated
Comment thread sklearn/datasets/_samples_generator.py Outdated
Comment thread sklearn/datasets/tests/test_samples_generator.py Outdated
Comment thread sklearn/datasets/_samples_generator.py
Copy link
Copy Markdown
Member

@NicolasHug NicolasHug left a comment

Choose a reason for hiding this comment

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

A few more comments but LGTM when addressed

Please add an entry to the change log at doc/whats_new/v023.rst. Like the other entries there, please reference this pull request with :pr: and credit yourself (and other contributors if applicable) with :user:.

Comment thread sklearn/datasets/_samples_generator.py Outdated
Comment thread sklearn/datasets/_samples_generator.py
Comment thread doc/whats_new/v0.23.rst Outdated
Comment thread sklearn/datasets/_samples_generator.py
Comment thread sklearn/datasets/_samples_generator.py
@NicolasHug
Copy link
Copy Markdown
Member

Anyone for a quick review @jnothman @qinhanmin2014 @thomasjpfan ?

The codecov can be ignored (changes are properly tested)

@qinhanmin2014 qinhanmin2014 merged commit ac9c3e1 into scikit-learn:master Jan 22, 2020
@NicolasHug
Copy link
Copy Markdown
Member

Thanks @venkyyuvy!

thomasjpfan pushed a commit to thomasjpfan/scikit-learn that referenced this pull request Feb 22, 2020
panpiort8 pushed a commit to panpiort8/scikit-learn that referenced this pull request Mar 3, 2020
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.

Add return_centers parameter to make_blobs

4 participants