Gilles:
I didn't know that, thanks. That will make a nice (but hopefully temporary)
solution.
Lars,
I opened an issue here:
https://github.com/scikit-learn/scikit-learn/issues/2168
On Thu, Jul 18, 2013 at 10:26 AM, <
[email protected]> wrote:
> Send Scikit-learn-general mailing list submissions to
> [email protected]
>
> To subscribe or unsubscribe via the World Wide Web, visit
> https://lists.sourceforge.net/lists/listinfo/scikit-learn-general
> or, via email, send a message with subject or body 'help' to
> [email protected]
>
> You can reach the person managing the list at
> [email protected]
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Scikit-learn-general digest..."
>
>
> Today's Topics:
>
> 1. Re: Associating a LabelEncoder with a Classifier? (Wifi Gi)
> 2. Re: scikit-learn for Android? (Emanuele Olivetti)
> 3. Re: Associating a LabelEncoder with a Classifier? (Lars Buitinck)
> 4. Re: feature selection documentation : improvements ?
> (Eustache DIEMERT)
> 5. Re: Associating a LabelEncoder with a Classifier? (Gilles Louppe)
> ------------------------------
>
> Message: 3
> Date: Thu, 18 Jul 2013 17:01:15 +0200
> From: Lars Buitinck <[email protected]>
> Subject: Re: [Scikit-learn-general] Associating a LabelEncoder with a
> Classifier?
> To: [email protected]
> Message-ID:
> <CAKz-xUe39yJv=
> [email protected]>
> Content-Type: text/plain; charset=UTF-8
>
> 2013/7/18 Wifi Gi <[email protected]>:
> > Lars,
> > Well, I'm confused now, sklearn.__version__ says "0.14-git". Did I
> download
> > the development branch?
>
> Yes.
>
> > Your code works, so you're right, they do take string classifiers. My
> > problem appears to arise when trying to use the scorers:
> > If I try:
> > metrics.classification_report(ytest, ypred)
> > My error is:
> > File
> > "/usr/local/lib64/python2.7/site-packages/sklearn/metrics/metrics.py",
> line
> > 2083, in classification_report
> > target_names = ['%d' % l for l in labels]
> > TypeError: %d format: a number is required, not numpy.string_
> >
> > Can I not use just the scorers with string classes?
>
> That's a bug. Could you open an issue for it at
> https://github.com/scikit-learn/scikit-learn/issues?
>
> --
> Lars Buitinck
> Scientific programmer, ILPS
> University of Amsterdam
>
>
> ------------------------------
>
> Message: 5
> Date: Thu, 18 Jul 2013 18:26:01 +0200
> From: Gilles Louppe <[email protected]>
> Subject: Re: [Scikit-learn-general] Associating a LabelEncoder with a
> Classifier?
> To: "[email protected]"
> <[email protected]>
> Message-ID:
> <
> cah3bukhhzegbvouv2st-d79zfaamguhj7jnrbbqtrd-kane...@mail.gmail.com>
> Content-Type: text/plain; charset="iso-8859-1"
>
> Hi,
>
>
> > I'm well aware I can pickle it, but I would like to avoid having to write
> > 2 files - otherwise I would just write the classes to a text file.
> >
>
> You pickle several Python objects using the same file handler.
>
> Gilles
>
> End of Scikit-learn-general Digest, Vol 42, Issue 63
> ****************************************************
>
------------------------------------------------------------------------------
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
_______________________________________________
Scikit-learn-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/scikit-learn-general