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

MAINT: Remove redundant copying of input data during resampling. #7

Closed
zoj613 opened this issue Jul 13, 2021 · 0 comments
Closed

MAINT: Remove redundant copying of input data during resampling. #7

zoj613 opened this issue Jul 13, 2021 · 0 comments
Labels
good first issue Good for newcomers

Comments

@zoj613
Copy link
Owner

zoj613 commented Jul 13, 2021

input data is unnecessarily copied twice in the _fit_resample method. First here:

pyloras/pyloras/_loras.py

Lines 144 to 145 in b896367

X_res = X.copy()
y_res = y.copy()

and then again here:

pyloras/pyloras/_loras.py

Lines 161 to 162 in b896367

X_res = [X_res.copy()]
y_res = [y_res.copy()]

It only needs to be done once. The second copy is not needed.

@zoj613 zoj613 added the good first issue Good for newcomers label Jul 13, 2021
@zoj613 zoj613 changed the title MAINT: Remove reduntant copying of input data during resampling. MAINT: Remove redundant copying of input data during resampling. Jul 13, 2021
@zoj613 zoj613 mentioned this issue Jul 22, 2021
@zoj613 zoj613 closed this as completed Jul 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant