Thursday, November 21, 2024

Machine Learning Demystified

Recent Articles

robot looking at a wall of red squares

By Pratibha Jain, member of the Artificial Intelligence Society at King’s College London

Artificial Intelligence (AI) has brought about a revolution in the world of technology, and some form of AI is applied in all walks of this digital era. AI is concerned with building machines to solve tasks that could typically only be solved by humans.

Now, how can machines possibly be trained to think like humans? How often do we see such examples around us?

Artificial Intelligence and Machine Learning (ML) are often used interchangeably, but ML is a subset of AI. It is the method of training algorithms so that they can make informed and rational decisions on their own, without human intervention. 

Machines are trained with data. Data is the new oil, and it is fuelling this vast acceleration of Artificial Intelligence.

ML algorithms can be broadly classified into 3 types:

  1. Supervised Learning
  2. Unsupervised Learning
  3. Reinforcement Learning

Supervised Learning

In this technique, the program is ‘trained’ on a given set of data, and it learns to reach conclusions by using that data. It is called supervised learning as the data is guiding or ‘supervising’ the knowledge the AI learns.

This can be further broken into:

i. Classification

The program is given labelled data as training data, and it uses this data to sort items into specific classes or categories. Classification can be used to differentiate spam mails from the important ones in your inbox, predict customer behaviour, classify images into categories, detect credit card fraud, and much more.

Each class has certain properties and the items belonging to a particular class exhibit those properties. As the model is trained on this data, it can accurately predict the class that a new item belongs to.  An example of this is how images in your phone gallery can make albums of your friends and family.

ii. Regression

The program is given a dataset with input variables and the output variable. Learning from the data by establishing correlation between the variables, the model can predict the output value for a new set of input variables. This means that for a new situation, the program can predict the outcome.

Let’s say we have two sets of variables for houses, first is the property of the house (size, location, space) and the second is the price of the house. The regression model can establish relationships between the property and the price of the house by reading different values. At a later stage, if it is given a new value for the property, it can accurately predict the price of the house for that particular property.

                                pastedGraphic.pngSource: https://www.holehouse.org/mlclass/01_02_Introduction_regression_analysis_and_gr_files/Image.png

Regression also has a very important role in making business decisions – they can use regression models to understand the relationship between sales and advertising costs and then make adjustments accordingly. 

 

Unsupervised Learning

In this technique, the program is given unlabelled data, and it must discover patterns and relationships between them. We don’t ‘supervise’ the model, but let it learn by itself. 

One way this can be done is with clustering. The model can establish patterns between the data and segregate it into various clusters depending upon the properties of each cluster. 

This is also similar to how humans think. Picture a child – let’s say you give him a banana and an apple. Next, you give him another banana. Now, the child has recognised that this looks similar to the banana given earlier due to its shape, size and colour, so he will put this banana with the first banana. Again, if you give him an apple, he puts it with the first apple. What has the child done? Created two clusters of two apples and two bananas, each. 

A ML model will also do the same thing, and this can be used effectively in businesses for customer segmentation. By studying the behaviours of users, the model can create cohorts of users and then create personalised solutions for each cohort. 

For example, if there is a group of customers that is more active in the evening, then personalised ads will be shown to them in the evening. Likewise, if there is a cohort of customers that is less likely to spend a lot, then organisations could roll out discount campaigns to increase sales to help rope in new customers. 

Reinforcement Learning 

This technique draws inspiration from real life, where the future is not certain and we learn as we go along the way. In real life, our actions have consequences, good and bad.  We learn from those experiences and adjust our future actions based on what we learnt. The program also learns from the consequences of its actions (rewards and punishments), and makes decisions based on its past experience. Let’s say we want our program to work in a certain way. Now, if the agent acts in the desired way, it is rewarded. However, if it does not, then it is punished. Learning from this experience, now the agent will not want to be punished. Hence, it will tend towards acting in the desired way, thereby increasing the accuracy of the model. 

A real-life example of this is autonomous driving.  It heavily relies on reinforcement learning algorithms for trajectory optimisation, lane changing, maintaining speed limits, recognising drivable zones, preventing accidents and much more. 

With applications in diverse areas, from autonomous driving to biological advancements in healthcare, Artificial Intelligence, and more specifically Machine Learning will soon become a part and parcel of life, so it is of the upmost importance to understand how it works.

LEAVE A REPLY

Please enter your comment!
Please enter your name here