Http://scikit-learn.org/stable/modules/multiclass.html
In the actual project, we really rarely use those simple models, such as LR, KNN, NB, etc., although classic, but in the project is really not practical.
Today we focus on the relatively large number of multiclass and Multilabel algorithms used in engineering.
Warning:scikit-learn all classifiers can be do multiclass classification Out-of-the-box (can be used directly), so it is not necessary to use this section described in the Sklearn.multiclass Module, here is just a little bit of knowledge.
Below is a summary of the classifiers supported by Scikit-learn grouped by strategy; You don't need the meta-estimators in this class if you ' re using one of the these unless you want custom multiclass behavior:
- Inherently multiclass: Naive Bayes, Sklearn.lda.LDA, decision Trees, Random forests , Nearest neighbors, setting "Multi_class=multinomial" in Sklearn.linear_model. Logisticregression.
- One-vs-one: Sklearn.svm.SVC.
- One-vs-all:all linear models except Sklearn.svm.SVC.
Some estimators also support Multioutput-multiclass classification tasks decision Trees, Random forests , Nearest neighbors.
Three types of questions:
multiclass classification means A classification task with more than two classes; But a sample can only belong to one of the categories (equivalent to a multivariate classification) .
Multilabel Classification assigns to every sample a set of target labels. A sample can belong to more than one category (equivalent to multiple two-tuple categories).
Multioutput-multiclass Classification andmulti-task Classificationmeans a single estimator have to handle several joint classification tasks.(equivalent to multiple classifications: theset of labels can different for each output variable. For instance a sample could is assigned "pear" for the output variable that takes possible values in a finite set of specie s such as "pear", "apple", "orange" and "green" for a second output variable this takes possible values in a finite set of Colors such as "green", "Red", "orange", "yellow" ... ).
Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.
Scikit-learn (Introduction to relatively more models used in engineering): 1.12. Multiclass and Multilabel algorithms