Chapter 1: What is Machine Learning?
In recent years you must have heard the words Machine Learning and AI quite a bit—and you likely won’t stop hearing them until the dawn of the robot age. In this set of chapters, we’ll go over what machine learning is—from foundational ideas to advanced applications. We won’t dive deeply into the underlying mathematics, but we’ll link out to useful resources. This chapter is primarily focused on classifier algorithms and neural networks, building on regression concepts introduced in prior sections.
1.1 What is Machine Learning?
Machine learning is a field within computer science that focuses on building systems that can learn from data and make decisions or predictions without being explicitly programmed for every situation. Rather than writing code to describe every rule, we let the machine discover patterns from the data and improve over time.
1.2 Types of Machine Learning
There are three main types of machine learning:
1.2.1 Supervised Learning
The algorithm is given labeled data (input-output pairs), and it learns to predict the output from the input.
Example: Predicting house prices based on features like square footage or location.
1.2.2 Unsupervised Learning
The algorithm is given data without labels and must identify patterns or structure on its own.
Example: Clustering similar customers based on purchasing behavior.
1.2.3 Reinforcement Learning
The algorithm learns by interacting with an environment and receiving feedback in the form of rewards or penalties.
Example: Training an AI to play a game or a robot to walk.
1.3 Common Machine Learning Applications
Machine learning powers many tools we interact with daily:
- Email filtering (spam detection)
- Image recognition (e.g., Google Photos)
- Recommendation systems (Netflix, Spotify, Amazon)
- Self-driving vehicles
- Speech recognition (e.g., Siri, Google Assistant)
- Medical diagnostics (e.g., disease prediction from scans)
1.4 Important Terminology
Here are some common terms used across the machine learning field:
- Features: The input variables (e.g., age, income, height).
- Labels: The target variable or outcome (e.g., house price, is_spam).
- Model: The system that maps inputs to outputs after being trained.
- Training: The process of feeding data to a model so it learns patterns.
- Prediction: The output of a trained model on new data.