Module 1

Python for ML Engineers

Move from writing Python scripts to building maintainable ML software: importable packages, typed data contracts, and reproducible environments.

Sarah Floris Instructor Sarah Floris · Lead ML Engineer
8 Lessons
Free
Start Course

Free · no account needed

Start learning
Requires Getting Started

Turn a notebook into software an engineer can rely on

A working Python and a place to run it

You should have the Getting Started setup in place — a working Python 3.12 and an editor — and be able to write Python that runs. No prior packaging, git, or ML-engineering experience is assumed; this module builds that foundation.

Python 3.12 a terminal a GitHub account

8 chapters

8 lessons

01 What This Module Covers

The arc of Python for ML Engineers: get a package working, put it under git, then harden it — robust imports, typed data contracts, and a reproducible environment — until another engineer can build on it.

02 Package Mechanics

How a real Python package is built: modules and imports, the src layout, a __main__ entry point, a virtual environment, and an editable install — the target shape before you convert anything into it.

03 Convert the Notebook

Take a real data-science notebook and convert it into the package layout from the previous lesson: scoring logic into an importable module, the run behind a __main__ entry point, working under python -m.

04 Version Control Your Package with Git

Put the package you just built under version control, push it to GitHub, and learn the everyday git workflow — including branches — that every later module and project depends on

05 Make the Imports Robust

Understand why imports and entry points break when code moves machines, and structure your package so they do not.

06 Make the Data Contracts Solid

Type your feature records with hints, dataclasses, and pydantic so a shape bug fails fast at the boundary instead of deep in training.

07 Make It Reproducible

Isolate the environment and lock dependencies so your package installs and runs identically on another engineer's machine.

08 What You Built in This Module

A recap of Python for ML Engineers: a working ML package under version control, with robust imports, typed data contracts, and a locked, reproducible environment — and where the system goes next.

Ready to start?

The first lesson is free. No credit card required.