# How Machine Learning Algorithms Works : An Overview

Tabla de contenidos

BY V SHARMA ON OCTOBER 29, 2018 • ( 2 COMMENTS )

* Algorithms *put logic, science and reasoning behind computer machines. Finding the best algorithm to use in a specific case is called experience, knowledge and need. You can call it as another algorithm. You can refer to the post “

*The Exciting Evolution of Machine Learning“*for more details on timelines & history on machine learning.

#### Algorithms in Machine Learning

Algorithms in Machine Learning (ML) borrows principles from computer science. There are many algorithms as no one algorithm works best for every problem,

- How does youtube suggest you videos?
- Which face has what name; How facebook knows?
- How google map is able to find the best & fastest route between office and home?

All the above question has one common answer “Algorithms”. The different problem will have a different algorithm (solution). Google map uses its own routing algorithm which is again set of many small sub-algorithms.

Machine learning is a subset of Artificial Intelligence and field of study which harnesses principles of computer science & statistics. AILabPage members intuitively call statistics as a graphical branch of mathematics. AILabPage defines machine learning in one simple line as below.

A focal point where business, data, experience meets emerging technology and decides to work together.

#### Machine Learning – Background

Even though Machine Learning term got coined in the 1950s, It remained largely confined to academia. Only recently machine learning came to limelight but disappointingly it is becoming rocket science kind of complex subject and more accessible to developers as their tool. Tools like TensorFlow an open-source machine learning framework is bringing machine learning to everyone though.

Different types of machine learning problems need different algorithms to solve them. Problems like below needs get easy answers with such tools

- Implementation of different types of classification algorithms
- Organising a predictive model project
- What all the different elements of data need to be used in predictive modelling.
- How deep convolutional neural networks leverage to convey images with high accuracy.
- How to scan audio in video messages by making use of natural language processing techniques along with make use of open source tools API’s

Open source machine learning tools hold the capability to solve a wider range of problems. These tools do have strength and capabilities to build deep neural networks and run them across thousands of computers in data centres.

Machine learning has evolved from Artificial Intelligence’s subset to Its own domain. It has reached an inflexion point – at least in terms of messaging. I remember in my school days as part of statistics class we were told something about AI and ML and we laughed then in the 1990s.

The need of today is a simple & easily accessible machine learning cloud service i.e. “*Machine Learning as a Service” – MLaaS *for everyone at low cost.

#### Machine Learning Process Flow

ML instructs an algorithm to learn for itself by analysing data. Algorithms here learn a mapping of input to output, detection of patterns or by reward. The more data it processes, the smarter the algorithm gets.

In other words, *Machine learning algorithms *“learn” from the observations. When exposed to more observations, the algorithm improves its predictive performance.

AILabPage Machine Learning Series – Machine Learning Process

In the above diagram of-course, there are a lot of iterations between step 5 to 4 & 3 and 5 to 3 & 2, which are not shown in the above diagram to keep it simple. Machine Learning is classified into three categories at a high level depending on the nature of the learning and learning system.

**Supervised learning:**Machine gets labelled inputs and their desired outputs. The goal is to learn a general rule to map inputs to the output.**Unsupervised learning:**Machine gets inputs without desired outputs, the goal is to find structure in inputs.**Reinforcement learning:**In this algorithm interacts with a dynamic environment, and it must perform a certain goal without a guide or teacher.

#### How Machine Learning Algorithms Work?

In one line answer is “*In machine learning algorithm works by learning strategy to map input to output”*.

Machine learning is pure mathematics or number game only. Algorithms work by understanding this game that underlines all algorithms. There are no flavours or taste in algorithms but simply different methods to do the same job. All the time it starts with learning a target function.

AILabPage Machine Learning Series – Algorithms Behind Machine Learning

Target function (f) that best maps input variables to an output variable. For example for our input variables “a” we need to predict the value of “y”. In this case our function becomes y=f(a).

Can you predict value of the house (“Y”) in a location “LOCATION” with input variables like dimensions of the land in square feet, construction cost per square feet, annual rate of growth in price change etc.

After the function has learnt so in future it becomes easy to predict the value of “y” for every new value of “a”. It does not get over here; there is always a need to keep the error margin or so-called algorithm performance indicator (b). As its independent of the input variable “a”. So our function looks like y = f(a) + b.

#### Why Learning a Function is Important

Learning a function has one sole reason and that to make correct possible predictions. Predictive modelling is mapping y = f(a) i.e predicting Y for every new value of “a”.

Functions are unknown for the model and as mentioned above their taste, flavour, shape or colours are really of no use/importance as long as it gives possible accurate predictions. Because functions are unknown before algorithms learn hence the importance. Otherwise, there would be no use to waste time and learn anything.

AILabPage Machine Learning Series – Machine Learning Flow

In Supervised learning, algorithm jobs are to take some data with a known relationship. From the above example for predicting house value where the price of land etc are known and to create a model of those relationships is easy.

This is a regression problem as output will be numerical but if we were to find expensive or not expensive then this would have fallen in the category of the classification problem.

#### Learning a Function – Approach

When to use which algorithm is a complex one to answer. It entirely depends upon on the problem and data in hand to solve. Better to apply least 3-5 algorithms to find the best results or answer.

It is so important to try 3-5 some time even more different algorithms (This is not a law or any rule) on a given problem. Otherwise to know the best outcome beforehand is impossible.

Remember its all about estimations, possibilities, prediction and forecasting so it is always best to make use of machine learning algorithm suites for approximations.

Different depictions of methods used make different assumptions about the function that is about to learn or being learned. So whether it is linear or nonlinear we need to be careful.

**Algorithm Performance Measure**

Different machine learning types have different reasons and method so the algorithms. How well your algorithm has performed it can be measured with error margins. For example.

AILabPage Machine Learning Series – Machine Learning Algorithms Performance Dashboard

- In case of supervised learning problems you can measure
- Classification Error for classification problems – how many errors are made
- Prediction error for regression problems – How far from real value

- In the case of unsupervised learning problems you can measure
- Clustering – How loose or tight
- Association – Confidence level of associations

For algorithms maximum efficiency, it should minimize resource usage. However, different resources such as time, computing power, accuracy and space complexity cannot be compared directly. In order to reach a conclusion on which algorithms can consider as more efficient entirely depends on the type of data, goal and which measure of efficiency is considered most important.

#### Books & Other Material Referred

- Open Internet & AILabPage (a group of self-taught engineers) members hands-on lab work.

**Points to Note:**

When to use which algorithm is a complex one to answer. It entirely depends upon on the problem in hand to solve. Better to apply at least 3 to find the best results and to have the best answer. All credits if any remains on the original contributor only. In the next upcoming post will talk about Recurrent Neural Networks in detail.

#### Feedback & Further Question

Do you have any questions about Deep Learning or Machine Learning? Leave a comment or ask your question via email. Will try my best to answer it.

**Conclusion** – We have seen in the post above that in machine learning algorithms is all about learning the target function. It works to estimate the mapping function (f) of output variables (y) given input variables (a), or Y=f(a). Google, Match.com, and Facebook matching algorithms are examined to see more clearly how they work mathematically.

We have also learned in the post that different machine learning algorithms make different assumptions. When to use which algorithm is a complex one to answer. So it is always best to make use of machine learning algorithm suites for approximations.

**============================ About the Author =======================**

Read about Author at** : ***About Me*

*Thank you all, for spending your time reading this post. Please share your opinion / comments / critics / agreements or disagreement. Remark for more details about posts, subjects and relevance please read the ***disclaimer****.**

**FacebookPage**** ContactMe ***Twitter*

Source: Vinodsblog