Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit a6d1fa3

Browse files
authoredNov 14, 2018
Create LabelBinarizer.md
1 parent f621414 commit a6d1fa3

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed
 

‎LabelBinarizer.md

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
Binarize labels in a one-vs-all fashion
2+
3+
Several regression and binary classification algorithms are available in the scikit. A simple way to extend these algorithms to the multi-class classification case is to use the so-called one-vs-all scheme.
4+
At learning time, this simply consists in learning one regressor or binary classifier per class.
5+
6+
In doing so, one needs to convert multi-class labels to binary labels (belong or does not belong to the class).
7+
8+
LabelBinarizer makes this process easy with the transform method.
9+
At prediction time, one assigns the class for which the corresponding model gave the greatest confidence.
10+
11+
LabelBinarizer makes this easy with the inverse_transform method.

0 commit comments

Comments
 (0)
Please sign in to comment.