In this article we will see an efficient mnemonic to always remember what is a class and a label in classification.
In Machine Learning there are different types of approaches to solve a problem.
Among them, classification problems form a large part of the spectrum.
Unfortunately, some classification concepts are confused or misunderstood by some people.
Let’s see now how to remember these different concepts :
- Class and Label
- Binary classification
- Multi-class – multi-label classification
What is a class?
Let’s take an example.
We need to predict the weather in Paris for all days of the week.

Here we only want to predict how the weather will be.
For this example, we have three options: sunny, rainy, snowy.
Each day must be classified in each of these options.
Therefore it’s a classification problem.
Note that if we were to predict the temperature in °C or °F, it would no longer be a classification problem but a regression problem.
These three options (sunny, rainy, snowy) are in fact our classes.
They are the three in which we have to classify our data (the days of the week).

Mnemonic : A class is a category in which to classify our data.
A binary classification is a classification with only two classes.
A multi-class classification is a classification with more than two classes.
What is a label?
Let’s continue our example.
Now we don’t just have to predict the weather for Paris but also for Miami and Moscow.
THE PANE METHOD FOR DEEP LEARNING!
Get your 7 DAYS FREE TRAINING to learn how to create your first ARTIFICIAL INTELLIGENCE!
For the next 7 days I will show you how to use Neural Networks.
You will learn what Deep Learning is with concrete examples that will stick in your head.
BEWARE, this email series is not for everyone. If you are the kind of person who likes theoretical and academic courses, you can skip it.
But if you want to learn the PANE method to do Deep Learning, click here :

Here we always want to predict how the weather will be.
BUT for the same day, we have 3 different locations. And therefore 3 possible results.
These cities are in fact our labels.
These labels allow us to differentiate our days of the week according to the city.
The classification problem is still the same but we’ll have to repeat the operation for each label.

Mnemonic : A label is a category that allows us to differentiate (label) our data.
A multi-class multi-label classification is a classification with more than two classes and more than one label.
Note that different labels for data do not necessarily imply the same classes.
We can imagine that in New York we have 3 classes (sunny, rainy, snowy) while in London only 2 (rainy, cloudy).
Class, label and then?
In Deep Learning, you have to adapt your neural network to each of these types of classification.
Indeed, for a binary classification problem, the output layer will not be the same as in a multiclass classification problem.
An output layer implies a different activation function !
In this article, we present the type of activation function to use in each classification. A table is waiting for you at the end of the article with the summary of this knowledge.
source :
- Photo – Unsplash, Malgorzata Bujalska
THE PANE METHOD FOR DEEP LEARNING!
Get your 7 DAYS FREE TRAINING to learn how to create your first ARTIFICIAL INTELLIGENCE!
For the next 7 days I will show you how to use Neural Networks.
You will learn what Deep Learning is with concrete examples that will stick in your head.
BEWARE, this email series is not for everyone. If you are the kind of person who likes theoretical and academic courses, you can skip it.
But if you want to learn the PANE method to do Deep Learning, click here :