What is machine learning (ML)?

Machine learning is a subfield of artificial intelligence (AI) that gives computers the ability to learn and improve their performance without being explicitly programmed for every single task.

67%

of companies are using machine learning, according to a recent survey

According to a 2021 report by Fortune Business Insights, the global machine learning market size was $26.03 billion in 2023 and is projected to grow to $225.91 billion by 2030 at a CAGR of 36.2%.

Machine learning powers many of the things you interact with every day:

  • Filters out spam emails
  • Detects fake accounts and harmful bot activity
  • Personalizes content on streaming platforms and social media apps (recommendation engine)
  • Drives search engines to find information
  • Enables image recognition and voice assistants
  • Translates languages

Machine learning is changing or will change every industry, and leaders need to understand the basic principles, the potential, and the limitations.

Aleksander Madry

MIT Computer Science Professor

How does ML work?

A machine learning model is like a mathematical formula that the algorithm uses to make sense of the training data. Unlike traditional programming language, where rules are explicitly coded, ML algorithms find patterns in data to make predictions or decisions.

The seven steps of ML are:

  1. Gathering data – Collecting relevant data that will be used for training and testing your models. The quality and quantity of data directly impact your model’s effectiveness.
  2. Preparing that data – Cleaning, transforming, and organizing data into a format your chosen algorithms can understand.
  3. Choosing a model – Select the type of machine learning algorithm that best suits your problem and the nature of your data.
  4. Training – During training, the algorithm is fed a data set and adjusts its internal parameters to minimize prediction errors. This iterative process allows the algorithm to refine its understanding.
  5. Evaluation – Using relevant metrics to assess the trained model’s performance on previously unseen data.
  6. Hyperparameter tuning – Fine-tuning the settings that control how the algorithm learns (e.g., learning rate, number of layers in a neural network).
  7. Prediction – Using the trained and tuned model to make predictions or decisions on new, real-world data. This is where the model provides actual value. Whether it’s classifying images, predicting customer churn, or driving a robot, the goal is to apply the learned knowledge.

Types of machine learning

The three types of machine learning are supervised, unsupervised, and reinforcement learning.

Supervised learning

Supervised learning is a fundamental type of machine learning where the algorithm learns from labeled data. This data consists of input features and corresponding desired outputs (labels). Once trained on the labeled data, the algorithm can then make predictions on new, unseen data.  It uses the learned patterns to classify new data points or predict continuous values.

Example: Emails labeled “spam” or “not spam,” images labeled “cat” or “dog,” and customer data with labels indicating churn (stopped using a service) or not.

Common supervised learning tasks

Classification is the most common task in supervised learning. The goal is to predict a category or class label for a new data point. Here are some examples:

  • Spam filtering: Classifying emails as spam or not spam based on features like keywords or sender information.
  • Image recognition: Classifying images as containing cats, dogs, cars, etc., based on their pixel patterns.
  • Fraud detection: Identifying fraudulent transactions based on customer data and purchase history.

Regression involves predicting a continuous value (a number) for a new data point. Examples include:

  • Predicting house prices: Based on features like size, location, and number of bedrooms.
  • Stock market prediction: Forecasting future stock prices based on historical data and market trends.
  • Sales forecasting: Predicting future sales figures based on past sales data and marketing campaigns.

Unsupervised learning

Unsupervised learning is a branch of machine learning where algorithms discover hidden patterns and structures within unlabeled data. Unlike supervised learning, which is like having a teacher guide you (labeled data), unsupervised learning is like exploring the unknown and making sense of it on your own.

In unsupervised learning, the data you provide to the algorithm lacks labels or predefined categories. The unsupervised learning algorithm acts like a curious explorer. It analyzes the data, searching for similarities, differences, and underlying structures within the data points.

Typical tasks in unsupervised learning

Clustering is a core task where the algorithm groups similar data points together. It helps identify hidden groups or segments within the data. Here are some applications:

  • Customer segmentation: Grouping customers based on purchase history for targeted marketing campaigns.
  • Image segmentation: Segmenting an image into different objects, like separating the foreground (cat) from the background (couch) in a picture.
  • Dimensionality reduction: Sometimes, data sets can have many features. Dimensionality reduction techniques aim to reduce the number of features while preserving the most essential information. This can improve processing speed and visualization of complex data.
  • Anomaly detection: This involves identifying data points that are significantly different from the majority. Anomaly detection is useful for fraud detection, system health monitoring, and identifying outliers in scientific data.

Semi-supervised learning

Semi-supervised machine learning (SSL) is a hybrid approach that bridges the gap between supervised and unsupervised learning.

SSL leverages a small amount of labeled data to provide guidance and also analyzes the more extensive set of unlabeled data, seeking underlying patterns and structures that can help inform the predictions.

In many real-world situations, getting labeled data is expensive or time-consuming. Think of medical image analysis, where labeling requires expert knowledge. SSL allows you to make full use of abundant unlabeled data to boost performance.

By combining the labeled and unlabeled data information, SSL models can often outperform models trained on just the tiny labeled set alone.

The unsupervised aspect of SSL helps explore the unlabeled data, potentially revealing hidden patterns or subgroups that wouldn’t be apparent with supervised techniques alone.

Reinforcement learning

Reinforcement learning (RL) is a fascinating area of machine learning where algorithms learn through trial and error, much like humans and animals learn by interacting with their environment. Imagine training a dog by rewarding good behavior (sit, fetch) and discouraging bad behavior (chewing shoes). Reinforcement learning works similarly but with agents and environments instead of dogs and trainers.

Common reinforcement learning algorithms

  • Q-learning: This is a popular algorithm where the agent learns a Q-value for each state-action pair, representing the expected future reward of taking a specific action in a particular state.
  • Deep Q-networks (DQNs): Combines Q-learning with deep neural networks, allowing them to handle complex environments with large state and action spaces.
  • Policy gradient methods: These algorithms focus on directly learning the policy (the agent’s strategy for choosing actions), often using neural networks to represent the policy.

Applications of reinforcement learning

  • Robotics: Training robots to perform complex tasks in dynamic environments, like self-driving cars or robotic arms in manufacturing.
  • Game Playing AI: Developing AI agents that can master complex games like chess, Go, or Starcraft II.
  • Resource Optimization: Reinforcement learning can be used to find optimal strategies for problems like traffic light control, inventory management, or dynamic pricing.

Deep learning vs. machine learning

Deep learning is a specialized subset of machine learning that uses artificial neural networks with multiple layers to learn complex patterns in data. These multi-layered networks are the reason for the “deep” in deep learning.

Structure

  • Machine learning: ML uses a variety of algorithms, including linear regression, decision trees, support vector machines, etc. These algorithms often have simpler structures.
  • Deep learning: Neural networks are the core of deep learning. The interconnected “neurons” in multiple layers give them immense power to model complex relationships.

Feature engineering

  • Machine learning: Traditional ML often requires careful feature engineering, where domain experts handcraft features (the relevant and informative parts of the data) to feed into the algorithms.
  • Deep learning: DL models can automatically learn complex features from data within their hidden layers. This reduces the need for manual feature engineering.

Data needs

  • Machine learning: Many classical ML algorithms perform well with smaller data sets.
  • Deep learning: The true power of DL shines with large, complex data sets (images, videos, natural language). The more data, the better neural networks can learn intricate patterns.

Artificial intelligence and machine learning (AI and ML)

AI and machine learning are often used interchangeably, but ML is a subset of the broader category of AI.

AI includes various techniques beyond just ML, such as:

Real-world examples

AI-powered spam filter

  • AI: The broader system that understands the nuances of spam vs. legitimate emails.
  • ML: The algorithms that analyze email content, headers, and other features to learn the patterns of spam and continuously update its filtering decisions.

Self-driving cars

  • AI: The overall system that perceives the environment, makes driving decisions, and navigates roadways.
  • ML: The components that enable the car to recognize objects (other vehicles, pedestrians, road signs) from camera and sensor data and learn how to respond in various driving scenarios.

FAQs

You might also like:

Apr 16th, 2024
7 min read