Machine Learning Explained

KTech Bytes
KTech Bytes
Published in
8 min readJan 23, 2020

By: Michael Ng

Source: Towards Data Science

Some of the biggest buzzwords in tech these days have been around Artificial Intelligence and Machine Learning. Stanford estimates total AI-related funding in 2019 was over $70 billion, with over $37 billion going to startups. Mckinsey’s 2019 Global Survey of businesses showed a 25% year-over-year increase in AI-related adoption in business practices. Large tech companies are increasingly scrambling to gobble up new AI and ML startups and the engineering talent they bring. But what exactly is AI and ML, and where do companies use it? Where is it helpful, and where is it just hype? In this post, I’ll focus on just a few of the most common sub-fields of Machine Learning: Supervised Learning, Unsupervised Learning, and Reinforcement Learning and see how they’re being applied both in research and in the business world.

Overview

The applications and definitions of Machine Learning and AI can be quite broad. While AI is more vague, Machine Learning has more of a focused set of applications. ML inherently focuses on statistical processes to extract insights from large bodies of data, using algorithms to do everything from making predictions about the future to identifying types of consumer behavior. It involves taking some body of training data, applying an algorithm to it to learn about the data, and either making future predictions on new data or extracting information from the current data. Many of the applications of Machine Learning were actually identified decades ago. For example, one of the more popular methods in ML today, Neural Networks, was actually proposed way back in the 1940s. However, thanks to Moore’s Law the speed of modern computers has progressed to a level such that data scientists and engineers can train these models on huge bodies of data at a much larger scale than ever before.

Supervised Learning

Supervised learning is a subset of machine learning that involves making out of sample predictions using some form of ML algorithm trained on data with labeled response variables. For example, training an image recognition algorithm of millions of pictures of dogs and cats where the training data has identified (or labeled) whether a photo is a dog or a cat.

Elon Musk’s tweet of dogs and muffins is a canonical example of a basic ML problem. With a dataset identifying which photo is a dog and which is a muffin, a supervised ML algorithm can ‘learn’ the difference and identify each in the future. Source: Twitter

Supervised Learning can also be further split into problems involving either regression or classification. Classification problems usually involve identifying or predicting a binary outcome with some probability. Is this a dog? If not, is this a muffin? In many ways, these problems are the same as those solved with traditional logit/probit regression models. However, many ML algorithms will add additional layers of complexity. As in the dog and muffin example, one of the more popular applications of classification problems in supervised learning is image recognition. For example, in 2015 Yelp used supervised learning techniques to group photos of food into different categories on their platform. Similarly, Facebook has used public images and hashtags to train supervised learning algorithms to recognize images at scale. In yet another example, in the field of medicine, researchers from Northwestern, Google and two British Medical Centers used deep learning (more on deep learning later) to increase the accuracy of breast cancer diagnosis in mammograms.

Another subset of supervised learning problems is regression. You’re probably familiar with the concept of regression from statistics; in a nutshell it’s the average relationship between some continuous variable and a series of independent variables. Ordinary Least Squares (or OLS) is the most common method of regression and involves estimating the average outcome of a response variable given some set of observed values of other independent variables based on a strictly linear relationship. For example, given that 5 new products were released by your company this year, the unemployment rate was 3%, and you’ve implemented a $5 million marketing campaign last quarter, what would you predict your sales to be this quarter? Or which of these variables causally determined what drove up sales in this quarter? These are examples of regression problems. As with classification problems, ML algorithms applied to regression add additional layers of complexity such as nonlinearities and interactions between variables. For example, Google’s Cloud offerings provide ML-based tools to predict customer lifetime value (CLTV) using more advanced methods than OLS. In another example, some researchers used a form of supervised learning to predict delinquency rates on credit card payments, and found the process was more accurate than traditional regression models.

Supervised learning is very powerful when trying to make predictions about specific scenarios where the outcome is known. In areas where the structure of the data is less certain though, we need unsupervised learning.

Unsupervised Learning

Unsupervised learning is a form of machine learning that extracts insights from data without any pre-determined labels or finite outcomes in the training data. This form of ML involves algorithms that can unearth the latent structure of the underlying data without being told what that structure is in advance; think about an algorithm that can identify pictures of dogs without being explicitly told what a dog is or which images in the training data are dogs. Instead, it groups together pictures that are similar based on the underlying structure (think pixels) of the image. Facebook, for example, has used methods in unsupervised learning for image classification in circumstances where it doesn’t have labeled training data available to use supervised learning.[1] In another example, Wayfair has utilized an unsupervised ML method called clustering in order to algorithmically group together similar furniture items that might seem different at first glance but have similar features at a broader level (for example, a sofa and a loveseat). This method helped Wayfair increase the number of items they were able to classify through image recognition, which is used later in downstream applications in their supply chain and on their web site.

[1] This is especially important for a firm like Facebook that has to have very accurate image classification but is limited by the amount of available training data with labeled responses (it takes a really long time and a lot of money to get humans to manually label a dataset of millions of images of dogs and muffins).

Wayfair uses unsupervised machine learning methods to group together furniture items and improve image recognition and tagging. Source: Wayfair

Some methods in unsupervised learning are sometimes classified as ‘deep learning,’ or forms of machine learning that algorithmically build on one another to create multiple layers of abstraction when interpreting data that perform additional calculations and transformations to output a better result. Neural Networks, deep learning algorithms that mimic the structure of the human brain, are one of the most commons methods in deep learning.

In the field of marketing, applications of unsupervised learning might involve market segmentation of consumer groups. By looking at purchase patterns and demographic data on consumers, data scientists ‘cluster’ consumer groups into types that allow marketers to target them in a more comprehensive manner. Hubspot, for example, has pioneered new applications in machine learning applied to consumer clustering.

Simpler methods of unsupervised learning might include dimension reduction; methods that reduce many variables into just a few representative ones (for example Principal Component Analysis or Exploratory Factor Analysis). In the field of economics for example, researchers have used these methods to understand broad conceptual drivers of recessions. We don’t have actual measures of abstract concepts in economics like bank runs or financial disruption. However, by looking at many different measures of the economy and financial markets and using dimension reduction, we can boil these concepts down into actual quantitative metrics that describe common features in the data (similar to how clustering groups together similar customer profiles based on many different variables).

Reinforcement Learning

Reinforcement learning differs a bit from the cases of supervised and unsupervised learning and can sometimes be more complex. It usually involves large scale simulations of a specific environment in which some ‘agent’ is trying to achieve a goal. Agents in the environment receive some reward for taking certain actions over time, and the algorithm trains these agents to optimize outcomes based on this reward system. Reinforcement learning simulates this environment over and over again to achieve an ideal outcome or rule of action for the agent to take (sometimes referred to as a policy rule). For those with some statistics background, most reinforcement learning problems follow a Markov Decision Process, where agents decide whether to transition from one state to another based on their current state.

One of the most popular applications of reinforcement learning is in games. DeepMind’s AlphaGo program famously used reinforcement learning to beat human Go champion Lee Sedol in 2016. The basic way AlphaGo worked was to train a neural net on a dataset of millions of moves made in previous games by expert Go players that was then used to predict what move the program should make in a given scenario. It then used another neural net to predict who would win the game at each point in time based on the positioning of the board. The program then played itself thousands of times to learn how to make better moves and optimize its decision-making process to win the game: an application of reinforcement learning. In other words, the program practiced…a lot.

Google’s Deepmind engineered AlphaGo to use reinforcement learning as well as other forms of machine learning to beat world Go champion Lee Sedol in 2016. Source: Fortune.

Applications of reinforcement learning are often used when a repeated task or set of tasks need to be optimized within a given workflow. For example, one of the many functions of Salesforce’ AI service, Einstein, is to summarize large bodies of text into concise briefs for users. Salesforce engineers used reinforcement learning techniques to generate better text summaries by scoring the output provided by an ML model and having it learn over time to come up with more flexible and useful methods of summarization.[2] The model repeated the process to create an optimal policy, learning over time as it performed the task over and over.

Another application of reinforcement learning can actually be used to choose what other machine learning algorithms engineers should use in a process called AutoML. In the area of autonomous vehicles, latency (or the compute time for performing a task) is extremely important; if a car is a bit too slow in computing whether or not the tree in front of it is indeed a tree, it will crash. Waymo therefore used reinforcement learning to actually decide which machine learning algorithm it should use to decrease latency, testing many different ML algorithms and learning over time which ones were the fastest in different situations.

These applications of machine learning are just a few of the many being used in the field right now. There are many additional applications, many of which combine existing forms of machine learning together or define new subfields entirely. New research has also pushed the frontier as to how fast and scalable ML algorithms are, as well as how machine learning might work in different applied use cases. For more content on machine learning and artificial intelligence, be sure to check out upcoming events from KTech as well as the Kellogg Data Analytics Club.

[2] Note that Salesforce used a Recurrent Neural Net or an RNN to generate the text in the first place and then trained its model on how to best use and apply the RNN using reinforcement learning. More sophisticated applications of ML often combine different ML techniques.

--

--