Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

ENH Add sample_indices for SMOTE class#843

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
tianlinhe wants to merge2 commits intoscikit-learn-contrib:master
base:master
Choose a base branch
Loading
fromtianlinhe:sample_indices

Conversation

tianlinhe
Copy link

Reference issue#772

What does this implement/fix? Explain your changes.

To add the sample indices of the generating samples that do not belong to the original dataset.

  • sample_indices() exposes the index of the original samples in a list
  • argget_which_neighbors=True reveals from which random neighbor the sample was generated. For original data it returns 0, which means itself

Any other comments?

-[x] Changes pass PEP8 (no issue on the changed lines)

It is only implemented in SMOTE. If needed I am happy to include it in ADASYN.

@pep8speaks
Copy link

Hello@tianlinhe! Thanks for opening this PR. We checked the lines you've touched forPEP 8 issues, and found:

Line 303:35:E226 missing whitespace around arithmetic operator
Line 330:1:W293 blank line contains whitespace

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

2 participants
@tianlinhe@pep8speaks

[8]ページ先頭

©2009-2025 Movatter.jp