Supervised, unsupervised and deep learning

Machine learning is became, or is just be, an important branch of artificial intelligence and specifically of computer science, so data scientist is a profile that is very requested. Today everyone could take some machine learning tools, like TensorFlow or others, and start to write code and say “Ehy I wrote my bla bla with a machine learning features… ”, but without know how those algorithms work, is very simple to make a huge mistakes. So is very important to understand be basics of machine learning and then built up the other skills.

This intro is firstly to remember to me this.

Let’s start with be basics: one of the first concepts in machine learning is the difference between supervised, unsupervised and deep learning.

Supervised learning

Supervised learning is the most common form of machine learning. With supervised learning, a set of examples, the training set, is submitted as input to the system during the training phase. Each input is labeled with a desired output value, in this way the system knows how is the output when input is come. For example consider some experimental observations that can be classified into N different classes. So we have a training set (a sequence of pairs) {(x1,y1),(x2,y2)….. (xn,yn)} where xi is the input and yi is the class of corresponding output. The training is performed by the minimization of a particular cost function which represent the bind from input xi and the desired output yi.

Supervised learning schema

A typical example of supervised machine learning application is the mail spam detector, this algorithm was trained with some spam, not spam emails and which group they belong. This training process continue when you mark a mail as “spam” or when you mark an email as “not spam” from the spam folder.

Unsupervised learning

Unsupervised learning, on the other hand, the training examples provide by the system are not labelled with the belonging class. So the system develops and organizes the data, searching common characteristics among them, and changing based on internal knowledge.

Unsupervised learning schema

An example of unsupervised learning is clustering classification: algorithm try to put similar things in a cluster and dissimilar in a different cluster, and the concept of similarity depends on a similarity measure.

Deep learning

Deep learning (DL) techniques represents a huge step forward for machine learning. DL is based on the way the human brain process information and learns. It consist in a machine learning model composed by a several levels of representation, in which every level use the informations from the previous level to learn deeply. Each level correspond, in this model, to a different area of the cerebral cortex, and every level abstract more the information in the same way of the human brain.

Deep learning schema


  • Machine learning in action — Peter Harrington
  • Getting started with TensorFlow — Giancarlo Zaccone