Hey.
You can use
gridsearch.best_estimator_.steps[0] for the first step, applying the other steps currently need a manual loop over the steps / hardcoding. There is a PR that will make this much easier: https://github.com/scikit-learn/scikit-learn/pull/2568

Cheers,
Andy


On 02/17/2015 08:45 PM, Pagliari, Roberto wrote:

When using the predict function

clf.predict(x_test)

where clf is obtained by gridsearchcv with a pipeline, is it possible to print intermediate results for debugging purposes?

For example, if the pipeline is [scaling, transformer1, transformer2, classificatory]

I would like to see the output of each step.

I could put a print statement inside the estimators of the pipeline, but I only need to check the prediction after grid search has completed, and grid search may generate too much output.

Thanks,



------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=190641631&iu=/4140/ostg.clktrk


_______________________________________________
Scikit-learn-general mailing list
Scikit-learn-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/scikit-learn-general

------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=190641631&iu=/4140/ostg.clktrk
_______________________________________________
Scikit-learn-general mailing list
Scikit-learn-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/scikit-learn-general

Reply via email to