Skip to main content

Welcome to a Grasp lesson

Create a free account to keep studying and create your own study path.

Lesson 1

Machine Learning: Simplified

Recommended resources

Hello! Welcome to the start of your journey toward the AWS Certified Machine Learning Engineer certification. In this first lesson, we'll begin with the most fundamental question: What exactly is machine learning? Our goal is to explain this powerful concept using a simple, everyday analogy, which will serve as the foundation for everything we cover in this course. By the end of this lesson, you'll be able to describe machine learning in a way that's easy for anyone to understand.

A Different Kind of Programming

As a software engineer, you're used to writing explicit, step-by-step instructions for a computer to follow. You design the logic, write the rules, and handle every if, else, and for loop to produce a predictable outcome. If you were to write a program to sort a list of numbers, you would implement a specific sorting algorithm like quicksort or mergesort.

Machine learning (ML) takes a different approach. Instead of you writing the rules, you provide the computer with a large amount of data and the desired answers, and it learns the rules on its own.

To see this distinction clearly, let's look at an article that compares these two approaches.

Machine Learning vs Traditional Programming

This article from the Institute of Data explains the core difference between the two programming paradigms.

Please read the section titled "What is the main difference between machine learning vs traditional programming?". Focus on the core distinction made in the first paragraph. The article explains that traditional programming depends on user-written instructions, while machine learning systems are defined more by the data they learn from.

So, the key takeaway is this:

  • Traditional Programming: You provide data + rules to get answers.
  • Machine Learning: You provide data + answers to get the rules.

The "rules" the machine learns are what we call a model. This model can then be used to make predictions on new, unseen data.


Learning Like a Child

The most common and effective way to think about machine learning is to compare it to how a small child learns. Imagine you want to teach a toddler the difference between a cat and a dog. You wouldn't write a set of rules like, "If the animal has pointy ears, a long tail, and says 'meow', it is a cat." Instead, you would show the child pictures.

This image visually captures the core analogy of machine learning: just as a child learns by observing and interacting with the world, a machine learns by being trained on data.

You'd point to various images and say, "This is a cat," "This is a dog," "That's another cat," and so on. Over time, after seeing hundreds of examples, the child's brain starts to recognize the patterns—the combination of shapes, sizes, fur textures, and sounds—that define "cat" and "dog." Eventually, they can see a picture of a cat they've never seen before and correctly identify it.

Machine learning works in almost the exact same way.

To see this analogy in action, watch the first few minutes of this video from WIRED, where a computer scientist explains machine learning to a child.

Computer Scientist Explains Machine Learning in 5 Levels of Difficulty | WIRED

This video provides a simple, direct explanation of machine learning using the cat-and-dog example.

Watch the segment from the beginning up to the 3 minute 30 second mark. Pay close attention to how the expert uses examples of cats and dogs to explain how a machine learns patterns. Notice how the machine, like the child, can sometimes make a good guess even on a tricky example.

The core process described in the video can be broken down into three main steps, as shown in this infographic.

This infographic outlines the three fundamental stages of a machine learning workflow: providing data, training the model to find patterns, and using the trained model to make predictions.
  1. Data Input: We feed the computer lots of examples (e.g., thousands of pictures, with each one labeled as "cat" or "dog").
  2. Training: The computer analyzes these examples and "learns" the underlying patterns. This is the stage where the model is built.
  3. Predictions/Decisions: The computer uses its learned patterns (the model) to make a prediction on a new, unlabeled picture.

For a brief textual reinforcement of this idea, you can read a quick passage from the Codeyoung blog.

Machine Learning: The Best Applications Transforming Industries Today

This article provides another clear explanation of the "learning like a child" analogy.

In the section "How Machine Learning Works? Explained for Beginners," read the paragraph that begins with the cat and dog analogy. This reinforces the central concept of learning from examples.


How Does a Machine Really Learn?

You might be wondering what's happening inside the "black box" during the training phase. How does a machine "learn" the rules without being explicitly programmed?

While the deep mathematics can be complex, the core concept can be understood with another simple analogy. The video below from CGP Grey does an excellent job of explaining this process intuitively. It imagines a "builder bot" that creates thousands of "student bots" with random internal wiring. A "teacher bot" then tests them all. The ones that do slightly better than random chance are kept, copied, and slightly modified, while the rest are discarded. This process repeats over and over.

How AI Actually Learns

This video, "You Don't Understand How AI Learns," gives a brilliant and intuitive explanation of the iterative training process.

Watch the segment from the builder bot analogy. This part explains how a system can improve over many generations of building, testing, and selecting the best performers, all without a human writing explicit rules for the task itself. This process of trial-and-error at a massive scale is the essence of how many machine learning models are trained.

This iterative process of testing, selecting the best, and making small changes is, in a simplified sense, how a machine learning model "learns." It's not about understanding in the human sense, but about optimizing a mathematical function over millions of cycles until it gets very good at mapping a specific input (a picture) to a specific output (the label "cat").


Conclusion

In this introductory lesson, we've established the fundamental idea of machine learning. Instead of writing explicit rules, we let a computer figure out the rules for itself by learning from a vast number of examples.

Here are the key takeaways:

  • Machine Learning vs. Traditional Programming: ML finds the rules from data and answers, whereas traditional programming applies human-written rules to data to get answers.
  • The Core Analogy: Machine learning is like teaching a child by showing them many examples until they can recognize patterns on their own.
  • The Three-Step Process: The basic workflow consists of (1) providing data, (2) training a model to find patterns, and (3) using the model to make predictions.

Now that you have a high-level understanding of what machine learning is, our next lesson will start to break down the "data" part of the equation. We'll explore the concepts of features (the inputs) and labels (the outputs) that form the building blocks of any machine learning dataset.