Pipelines are useful for creating composite estimators that can be plugged
in elsewhere. At the moment we have nowhere you can plug in a neighborhood
calculator, although we would like to (see
https://github.com/scikit-learn/scikit-learn/pull/8999 for the latest
attempt). If there are then compelling use-cases for allowing that
pluggable neighbors estimator to be a pipeline, we might follow that path.
But as you implied, we don't want to confuse users if such use-cases are
far fetched.

What do you intend to use it for?

On 15 September 2017 at 02:47, Ryan Conway <ryanmackenziecon...@gmail.com>
wrote:

> Thank you, Andreas. Indeed this becomes cumbersome when we don't know the
> prototype of the terminating function.
>
> > it's pretty easy to implement this by creating your own Pipeline
> subclass, isn't it?
>
> Good idea, that's probably the route I will take. That said, as a
> newcomer to sklearn, a benefit of utility classes such as Pipeline is that
> their interface helps me understand the library developers' intent and how
> its components should fit together. Prior to this conversation I lacked
> confidence that Pipeline was suitable for my use case.
>
> Ryan
>
> On Wed, Sep 13, 2017 at 2:14 PM, Joel Nothman <joel.noth...@gmail.com>
> wrote:
>
>> it's pretty easy to implement this by creating your own Pipeline
>> subclass, isn't it?
>>
>> On 14 Sep 2017 4:55 am, "Gael Varoquaux" <gael.varoqu...@normalesup.org>
>> wrote:
>>
>>> On Wed, Sep 13, 2017 at 02:45:41PM -0400, Andreas Mueller wrote:
>>> > We could add a way to call non-standard methods, but I'm not sure that
>>> is the
>>> > right way to go.
>>> > (like pipeline.custom_method(X, method="kneighbors")). But that
>>> assumes that
>>> > the method signature is X or (X, y).
>>> > So I'm not sure if this is generally useful.
>>>
>>> I don't see either why it's useful. We shouldn't add a method for
>>> everything that can be easily coded with a few lines of Python. The nice
>>> thing of Python is that it is such an expressive language.
>>>
>>> Gaƫl
>>> _______________________________________________
>>> scikit-learn mailing list
>>> scikit-learn@python.org
>>> https://mail.python.org/mailman/listinfo/scikit-learn
>>>
>>
>> _______________________________________________
>> scikit-learn mailing list
>> scikit-learn@python.org
>> https://mail.python.org/mailman/listinfo/scikit-learn
>>
>>
>
> _______________________________________________
> scikit-learn mailing list
> scikit-learn@python.org
> https://mail.python.org/mailman/listinfo/scikit-learn
>
>
_______________________________________________
scikit-learn mailing list
scikit-learn@python.org
https://mail.python.org/mailman/listinfo/scikit-learn

Reply via email to