Overview

1 What is machine learning? It is common sense, except done by a computer

Machine learning is presented as a practical, intuitive way for computers to make decisions much like humans do, by spotting patterns in data and using common sense—just scaled and automated. The chapter emphasizes that you don’t need deep math or extensive coding to get started; a visual mindset, curiosity, and a willingness to learn are enough. With modern computing power and abundant data, ML now touches almost every domain, from recommendations and image recognition to medical diagnosis and self-driving, making it an accessible tool for anyone eager to improve real-world processes.

The chapter clarifies key ideas and terminology: artificial intelligence is any decision-making by computers, while machine learning is the subset that bases those decisions on data; deep learning is a further subset centered on neural networks. It frames ML through the remember–formulate–predict process: draw on past data (experience), generalize a rule (a model), and use it to make future predictions. Models are the rules that represent data; algorithms are the procedures that build those models. Through a sequence of spam-vs-ham email examples, it shows how simple heuristics evolve into richer models as we add features (like day of week, message size, wording, sender, or errors) and how computers can efficiently test many rule combinations to find those that fit existing data while aiming to generalize to new cases.

Pedagogically, the book treats formulas and code as languages best learned through concrete examples and clear visuals, building models from scratch early on and later leveraging libraries such as Scikit-Learn, Turi Create, or Keras as complexity grows. It distinguishes predictive ML—answering classification or regression questions—from generative ML, which creates new content like text or images and is inherently more challenging. While the focus is on predictive methods (with a dedicated chapter on generative techniques), the core goal is to develop strong intuition for data, features, models, and evaluation so you can choose approaches that generalize well and apply them confidently to problems you care about.

Machine learning is a part of artificial intelligence.
Machine learning encompasses all the tasks in which computers make decisions based on data. In the same way that humans make decisions based on previous experiences, computers can make decisions based on previous data.
Deep learning is a part of machine learning.
The remember-formulate-predict framework is the main framework we use in this book. It consists of three steps: (1) We remember previous data; (2) we formulate a general rule; and (3) we use that rule to make predictions about the future.
A very simple machine learning model
A slightly more complex machine learning model
Another slightly more complex machine learning model
An even more complex machine learning model
A much more complex machine learning model, found by a computer
Predictive machine learning is akin to answering questions, such as multiple choice. Generative learning is akin to writing an essay or drawing an image.

Summary

  • Machine learning is easy! Anyone can learn it and use it, regardless of their background. All that is needed is a desire to learn and great ideas to implement!
  • Machine learning is tremendously useful, and it is used in most disciplines. From science to technology to social problems and medicine, machine learning is making an impact and will continue doing so.
  • Machine learning is common sense, done by a computer. It mimics the ways humans think to make decisions quickly and accurately.
  • Just as humans make decisions based on experience, computers can make decisions based on previous data. This is what machine learning is all about.
  • Machine learning uses the remember-formulate-predict framework:
  • - Remember: look at the previous data.
  • - Formulate: build a model, or a rule, based on this data.
  • - Predict: use the model to make predictions about future data.

FAQ

What is artificial intelligence (AI)?AI is the broad field of getting computers to make decisions on their own. Any time a computer solves a problem by itself—routing, diagnosing, recommending, or driving—we’re looking at AI.
How does machine learning (ML) differ from AI?ML is a subset of AI focused on making decisions based on data. Instead of hand-coding all rules, ML learns patterns from past data and uses them to make predictions about new situations.
What does “machine learning is common sense, except done by a computer” mean?Humans use experience to find patterns and make reasonable predictions; ML does the same with data. The computer learns from examples (data) and applies the learned patterns to new cases.
Do I need a heavy math and coding background to learn ML?No. Basic math helps, but the main ingredients are curiosity, visual intuition, and common sense. Many tools and libraries let you build useful models with minimal code, and you can pick up math and programming as you go.
What is the remember–formulate–predict framework?It mirrors how humans use experience: remember past data, formulate a general rule that fits it, and predict outcomes on new cases. ML trains on historical data, builds a model (the rule), and then uses it to make future predictions.
What are a model and an algorithm in ML?A model is the set of rules learned from data that we use to make predictions. An algorithm is the step-by-step procedure that builds that model from the data.
What are features?Features are measurable properties of the data that a model can use to predict. In email filtering, examples include day of week, message size, sender, number of spelling mistakes, or specific word occurrences.
How can simple data-driven rules classify spam?By spotting patterns in past emails—like “weekend messages tend to be spam” or “size ≥ 10 KB is often spam”—we can build rules that predict new emails. As we observe more cues (features), we refine rules to reduce mistakes, balancing simplicity and accuracy.
How do computers actually find a “good” model from data?They search through many candidate rules and formulas, checking which ones fit the training data best and generalize to new data. This automated exploration lets machines handle far more combinations than a human could by hand.
What is deep learning, and how does it relate to predictive vs. generative ML?Deep learning is a branch of ML that uses neural networks and powers many state-of-the-art applications. Predictive ML answers questions with labels or numbers (classification, regression), while generative ML creates new content such as text or images; mastering predictive ML (especially neural networks) sets you up to tackle generative tasks.

pro $24.99 per month

  • access to all Manning books, MEAPs, liveVideos, liveProjects, and audiobooks!
  • choose one free eBook per month to keep
  • exclusive 50% discount on all purchases
  • renews monthly, pause or cancel renewal anytime

lite $19.99 per month

  • access to all Manning books, including MEAPs!

team

5, 10 or 20 seats+ for your team - learn more


choose your plan

team

monthly
annual
$49.99
$499.99
only $41.67 per month
  • five seats for your team
  • access to all Manning books, MEAPs, liveVideos, liveProjects, and audiobooks!
  • choose another free product every time you renew
  • choose twelve free products per year
  • exclusive 50% discount on all purchases
  • renews monthly, pause or cancel renewal anytime
  • renews annually, pause or cancel renewal anytime
  • Grokking Machine Learning, Second Edition ebook for free
choose your plan

team

monthly
annual
$49.99
$499.99
only $41.67 per month
  • five seats for your team
  • access to all Manning books, MEAPs, liveVideos, liveProjects, and audiobooks!
  • choose another free product every time you renew
  • choose twelve free products per year
  • exclusive 50% discount on all purchases
  • renews monthly, pause or cancel renewal anytime
  • renews annually, pause or cancel renewal anytime
  • Grokking Machine Learning, Second Edition ebook for free