> not to have him waste hours of computation before crashing
Yet this is precisely what the present code does in this issue...
On 4 February 2014 18:32, Gael Varoquaux <gael.varoqu...@normalesup.org>wrote:
> > In the mean time, I wonder why you would even need to do a type checking
> here?
> > As far as I know, Python strongly encourages duck typing. Why not remove
> the
> > type checking altogether and just let the exception "bubble up" when
> the duck
> > cannot quack (i.e., when the score function output cannot be used by the
> > respective caller)?
>
> As Andy said, it is to give helpful error messages to the users, and also
> not to have him waste hours of computation before crashing (you know: "If
> it walks like a duck, and quacks like a duck, it's probably gonna throw
> exceptions at runtime" :} ).
>
> However, obeying with the principle of maximum flexibility which
> underlies duck typing, I agree that the challenge is to find the good
> compromise and not over-specify our requirements in the type checking.
>
> Cheers,
>
> Gaƫl
>
>
> ------------------------------------------------------------------------------
> Managing the Performance of Cloud-Based Applications
> Take advantage of what the Cloud has to offer - Avoid Common Pitfalls.
> Read the Whitepaper.
>
> http://pubads.g.doubleclick.net/gampad/clk?id=121051231&iu=/4140/ostg.clktrk
> _______________________________________________
> Scikit-learn-general mailing list
> Scikit-learn-general@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/scikit-learn-general
>
------------------------------------------------------------------------------
Managing the Performance of Cloud-Based Applications
Take advantage of what the Cloud has to offer - Avoid Common Pitfalls.
Read the Whitepaper.
http://pubads.g.doubleclick.net/gampad/clk?id=121051231&iu=/4140/ostg.clktrk
_______________________________________________
Scikit-learn-general mailing list
Scikit-learn-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/scikit-learn-general