Skip to content

Conversation

@chkoar
Copy link
Member

@chkoar chkoar commented Jun 26, 2016

Regarding to #38 and #75, this PR modifies the sklearn.pipeline.Pipeline class in order to adapt the current API of samplers. I have included one example using only samplers in the pipeline and one example using one transformer, two samplers and one classifier in the pipeline object. This PR needs test that I have not included.

@chkoar chkoar changed the title Modify Pipeline object to conform the current API of samplers [WIP]Modify Pipeline object to conform the current API of samplers Jun 26, 2016
@chkoar chkoar changed the title [WIP]Modify Pipeline object to conform the current API of samplers [WIP] Modify Pipeline object to conform the current API of samplers Jun 26, 2016
@dvro
Copy link
Member

dvro commented Jun 26, 2016

Wouldn't it be better that our pipeline inherited from sklearn.pipeline.Pipeline and only overrode the fit/predict/predict_proba methods? This way, our pipeline would always be 'updated' and if sklearn ever support transform(axis=1) we could easily make the api compatible without the need of rewritting the Pipeline class.

@glemaitre , thoughts?

@chkoar
Copy link
Member Author

chkoar commented Jun 26, 2016

@dvro I think that you are right.

@glemaitre
Copy link
Member

Completely agree.

@glemaitre
Copy link
Member

However we will still have some issue with the testing. In fact we should execute the testing from sklearn to be sure that this is going through and our testing.

@glemaitre
Copy link
Member

Actually, every function in the Pipeline is overloaded so we will have anyway to take care about that class.

@glemaitre glemaitre merged commit 47e3507 into scikit-learn-contrib:master Jun 26, 2016
christophe-rannou pushed a commit to christophe-rannou/imbalanced-learn that referenced this pull request Apr 3, 2017
[WIP] Modify Pipeline object to conform the current API of samplers
glemaitre added a commit to glemaitre/imbalanced-learn that referenced this pull request Jun 15, 2017
[WIP] Modify Pipeline object to conform the current API of samplers
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants