← All coursesCoding & software

Machine Learning Basics with Python

Teach a computer to learn from examples: predict how busy the café will be, who'll come back, whether a review is happy, and which digit someone wrote — with Python and scikit-learn.

Intermediate · 24 lessons · 8 h 50 min · Certificate on completion · With Avro Academy Team

How computers learn from examples

Machine learning is behind recommendations, spam filters, fraud alerts, weather apps and the AI chatbots everyone talks about. Underneath, it's one idea: show a computer lots of examples, and let it find the pattern — instead of writing every rule by hand.

In this course you'll use Python and scikit-learn, the most widely used machine learning library, to answer real questions for Corner Café: How many customers will come on Saturday? Which loyalty members are about to stop coming? Is this review happy or unhappy? What groups of customers are there? And you'll teach a model to read handwritten digits.

What you'll learn

  • What machine learning is, and the main kinds: regression, classification and clustering
  • Preparing data: features, labels, missing values and text categories
  • Training and testing models properly, and measuring how good they are
  • Linear and logistic regression, decision trees and random forests
  • Working with text and images
  • Avoiding overfitting, cross-validation and pipelines
  • Saving a model and using it in a program — and using ML responsibly

Before you start

You should be comfortable with Python basics (Python Foundations). Python for Data (pandas) helps a lot. No maths beyond Year 10 — we explain every idea in plain words.

How it works

  • 6 modules, 18 lessons, about 7 hours including quizzes
  • Every script, result and chart in the lessons was run for real
  • The café's data and the finished scripts, a quiz after each module, a cheat sheet and a certificate

Free forever — like every self-paced course on Avro Academy: all lessons, quizzes, downloads and your certificate. Our promise

Course outline

  1. Module 1: Meet machine learning

    What machine learning is, setting up Python and scikit-learn, and your first model.

    • What machine learning isFree preview20 min
    • Set up your tools20 min
    • Your first model25 min
    • Module 1 quiz5 min
  2. Module 2: Preparing data

    Exploring data, features and labels, missing values, one-hot encoding, and splitting into training and test sets.

    • Explore the data first25 min
    • Features and labels25 min
    • Train and test25 min
    • Module 2 quiz5 min
  3. Module 3: Predicting numbers

    Linear regression, measuring models with baselines, MAE, RMSE and R², and decision trees and random forests.

    • Linear regression30 min
    • How good is the model?30 min
    • Decision trees and random forests35 min
    • Module 3 quiz5 min
  4. Module 4: Predicting categories

    Logistic regression, confusion matrices, precision and recall, choosing cut-offs, and classifying text.

    • Will they come back?30 min
    • Accuracy isn't everything35 min
    • Reading reviews35 min
    • Module 4 quiz5 min
  5. Module 5: Images, groups and good habits

    Recognising handwritten digits, clustering customers with KMeans, cross-validation and pipelines.

    • Recognising handwritten digits30 min
    • Finding groups of customers30 min
    • Cross-validation and pipelines30 min
    • Module 5 quiz5 min
  6. Module 6: Using models responsibly

    Saving and using a model, keeping it working, bias, fairness and privacy, and where to go next.

    • Save and use your model30 min
    • Using machine learning responsibly25 min
    • Where to go next20 min
    • Module 6 and final quiz5 min