That's a cool trick but I am worried it would render our API too
"frameworky" for my taste.
I think the FunctionTransformer is enough:
http://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.FunctionTransformer.html
___
scikit-learn maili
Hi,
sklearn Pipelines are awesome, I use them all the time for everything.
I've been writing a lot custom transformers lately, and since most of my
transformers require no fitting (e.g. replacing all number with "{NUM}"
token),
I started using transformers as decorators.
See snippet (example usage