Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Documentation of label-binarizer and multi-label format #4639

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
amueller opened this issue Apr 27, 2015 · 17 comments · Fixed by #7519
Closed

Documentation of label-binarizer and multi-label format #4639

amueller opened this issue Apr 27, 2015 · 17 comments · Fixed by #7519
Labels
Documentation Easy Well-defined and straightforward way to resolve

Comments

@amueller
Copy link
Member

From the docs I feel it is not entirely clear that using label indicators means doing multi-label classification.
I think this should be better documented in the multi-class narratives, the OneVsRestClassifier and the LabelBinarizer.
Applying a label-binarizer to your y will result in quite different results, which is obvious if you know that this will switch the problem to a multi-label problem, but is somewhat unintuitive for the uninitiated.

@amueller amueller added Easy Well-defined and straightforward way to resolve Documentation labels Apr 27, 2015
@dotsdl
Copy link
Contributor

dotsdl commented Jul 12, 2015

Working on this one now.

@dotsdl
Copy link
Contributor

dotsdl commented Jul 22, 2015

Releasing this one for someone else. Not working on it now.

@pieteradejong
Copy link
Contributor

Is there till a need for someone to take this on? If so, it seems like a great way to get started with scikit-learn - any pointers?

@amueller
Copy link
Member Author

amueller commented Sep 8, 2015

@pieteradejong feel free to get started on this. Start by reading the multi-class and multi-label documentation and make sure to understand the differences between multi-class and multi-label.

@andylamb
Copy link

@pieteradejong, are you still working on this?

@pieteradejong
Copy link
Contributor

@andylamb yes, am working on it.

have run some searches for 'multi-class' and 'multi-label' in the source, would be happy to hear about any specific locations I should look at.

@pieteradejong
Copy link
Contributor

currently proceeding by looking at this file:
https://github.com/scikit-learn/scikit-learn/blob/master/doc/modules/multiclass.rst

@amueller is this the right place to look?

@pieteradejong
Copy link
Contributor

@amueller there is a broken image in the URL mentioned in my previous comment;
https://github.com/scikit-learn/scikit-learn/blob/master/doc/auto_examples/plot_multilabel.html

I'd be happy to reproduce it and add it back in via PR; could you provide any instructions as to how that image was produced?

@amueller
Copy link
Member Author

multiclass.rst is the right place to look.
Can you link to where the image is broken on the website?

@amueller
Copy link
Member Author

You mean the bottom right here:
http://scikit-learn.org/dev/auto_examples/plot_multilabel.html
?
There is already an issue for that: #4643

@pieteradejong
Copy link
Contributor

@amueller Yes, I think that's the one. Glad to see there's an existing issue.
Will propose some changes to multiclass.rst.

@pieteradejong
Copy link
Contributor

working on this now

@pieteradejong
Copy link
Contributor

@amueller does MultiLabelBinarizer also convert the other way, that is, from a binary matrix to a list of tuples? for example, from:
array([[0, 0, 1, 1, 1],
[0, 0, 1, 0, 0],
[1, 1, 0, 1, 0],
[1, 1, 1, 1, 1],
[1, 1, 1, 0, 0]])

to:
y = [[2, 3, 4], [2], [0, 1, 3], [0, 1, 2, 3, 4], [0, 1, 2]]

@pieteradejong
Copy link
Contributor

@amueller are you looking for any comments to be added specifically to 1.12.1, 1.12.2 or both? It seems pretty clear in the former, that you're doing multi label classification since that is the title of the section?

On the other hand, the multilabel section in OneVsRest could use some more comments perhaps?

@devashishd12
Copy link
Contributor

@pieteradejong are you still working on this? If you've already raised a pr can you please pin this issue? Thanks!

@pieteradejong
Copy link
Contributor

yes I am working on this

@devashishd12
Copy link
Contributor

@pieteradejong alright awesome! Waiting for a pr :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Documentation Easy Well-defined and straightforward way to resolve
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants