# What is the difference between Multiclass and Multilabel Problem

What is the difference between a multiclass problem and a multilabel problem?

• Both tasks can be accomplished with Vowpal Wabbit software package (command-line, python bindings are available). – Vladislavs Dovgalecs Aug 26 '15 at 20:40
• I learned this concept and build my understanding with this post, they explained multi-label classification in a very elegant way. – user235077 Jan 23 at 14:47

I suspect the difference is that in multi-class problems the classes are mutually exclusive, whereas for multi-label problems each label represents a different classification task, but the tasks are somehow related (so there is a benefit in tackling them together rather than separately). For example, in the famous leptograspus crabs dataset there are examples of males and females of two colour forms of crab. You could approach this as a multi-class problem with four classes (male-blue, female-blue, male-orange, female-orange) or as a multi-label problem, where one label would be male/female and the other blue/orange. Essentially in multi-label problems a pattern can belong to more than one class.

• @Dirkran Thanks for your explanation. Do you know any other source where i can get multilabel dataset other than csie.ntu.edu.tw/~cjlin/libsvmtools/datasets/multilabel.html and mulan.sourceforge.net/datasets.html – Learner Jun 13 '11 at 10:42
• @Learner sorry it isn't something I have worked on much. You might want to have a look at multi-task learning, which has some similarities to multi-label learning. Perhaps some of the datasets used for that might also be useful as benchmarks for mult-label learning. – Dikran Marsupial Jun 13 '11 at 11:10

And one more difference lies in that the multi-label problem requires the model to learn the correlation between the different classes, but in multiclass problems different classes are independent of each other.

To complement the other answers, here are some figures. One row = the expected output for one sample.

## Multiclass

One column = one class (one-hot encoding)

## Multilabel

One column = one class

You see that:

• in the multilabel case, one sample might be assigned more than one class.
• in the multiclass case, there are more than 2 classes in total.

As a side note, nothing prevents you from having a multioutput-multiclass classification problem, e.g.:

Multiclass classification means a classification task with more than two classes; e.g., classify a set of images of fruits which may be oranges, apples, or pears. Multiclass classification makes the assumption that each sample is assigned to one and only one label: a fruit can be either an apple or a pear but not both at the same time.

Multilabel classification assigns to each sample a set of target labels. This can be thought as predicting properties of a data-point that are not mutually exclusive, such as topics that are relevant for a document. A text might be about any of religion, politics, finance or education at the same time or none of these.

A multi-class problem has the assignment of instances to one of a finite, mutually-exclusive collection of classes. As in the example already given of crabs (from @Dikran): male-blue, female-blue, male-orange, female-orange. Each of these is exclusive of the others and taken together they are comprehensive.

One form of a multi-label problem is to divide these into two labels, sex and color; where sex can be male or female, and color can be blue or orange. But note that this is a special case of the multi-label problem as every instance will get every label (that is every crab has both a sex and a color).

Multi-label problems also include other cases that allow for a variable number of labels to be assigned to each instance. For instance, an article in a newspaper or wire service may be assigned to the categories NEWS, POLITICS, SPORTS, MEDICINE, etc. One story about an important sporting event would get an assignment of the label SPORTS; while another, involving political tensions that are revealed by a particular sporting event, might get both the labels SPORTS and POLITICS. Where I am, in the US, the results of the Superbowl are labeled both SPORTS and NEWS given the societal impact of the event.

Note that this form of labeling, with variable numbers of labels, can be recast into a form similar to the example with the crabs; except that every label is treated as LABEL-X or not-LABEL-X. But not all methods require this recasting.