-
Notifications
You must be signed in to change notification settings - Fork 1.3k
[MRG] EHN: split and factorize SMOTE classes #440
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
[MRG] EHN: split and factorize SMOTE classes #440
Conversation
Hello @glemaitre! Thanks for updating the PR. Cheers ! There are no PEP8 issues in this Pull Request. 🍻 Comment last updated on July 27, 2018 at 20:17 Hours UTC |
Codecov Report
@@ Coverage Diff @@
## master #440 +/- ##
==========================================
+ Coverage 98.71% 98.75% +0.04%
==========================================
Files 70 70
Lines 4188 4270 +82
==========================================
+ Hits 4134 4217 +83
+ Misses 54 53 -1
Continue to review full report at Codecov.
|
@chkoar @StephanHeijl Could you have a look to this PR. |
assert_allclose(X_resampled, X_gt, rtol=R_TOL) | ||
assert_array_equal(y_resampled, y_gt) | ||
|
||
|
||
@pytest.mark.filterwarnings('ignore:"kind" is deprecated in 0.4 and will be') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like all these filter warnings require some extra text.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a regular expression. Only the beginning is useful (mainly the name of the parameter)
[1.07844561, -0.19435291], [1.44015515, -1.30621303]]) | ||
y_gt = np.array( | ||
[0, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 0, 1, 0, 0, 0, 0]) | ||
X_gt = np.array([[0.11622591, -0.0317206], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not extremely important, but it might be good to pick a single format for X* arrays here; 10x2 or 20x1.
Just looked this over, the code was moved around properly (as evidenced by the succeeding tests), so I only found small remarks. Aside from those it looks good to me, I'll be happy to adjust the KMeans code to conform to this format. |
Split the SMOTE class into several classes.
TODO:
SVMSMOTE
andBorderlineSMOTE
Related to #435