small medium large xlarge

Programming Machine Learning: From Zero to Deep Learning


Cover image for Programming Machine Learning

Programming Machine Learning

From Zero to Deep Learning


You’ve decided to tackle machine learning — because you’re job hunting, embarking on a new project, or just think self-driving cars are cool. But where to start? It’s easy to be intimidated, even as a software developer. The good news is that it doesn’t have to be that hard. Master machine learning by writing code one line at a time, from simple learning programs all the way to a true deep learning system. Tackle the hard topics by breaking them down so they’re easier to understand, and build your confidence by getting your hands dirty.

Printed in full color.

Choose Your Format(s)

  • $25.95 In Stock
    • Beta: What do I get?

  • Ebooks are DRM free.

  • Ebook delivery options.

  • The Paper Book will ship on 2019-10-10 (roughly).

About this Title

Pages: 300 (est)
Published: 2019-10-10
Release: B2.0 (2019-04-10)
ISBN: 978-1-68050-660-0

Peel away the obscurities of machine learning, starting from scratch and going all the way to deep learning. Machine learning can be intimidating, with its reliance on math and algorithms that most programmers don’t encounter in their regular work. Take a hands-on approach, writing the Python code yourself, without any libraries to obscure what’s really going on. Iterate on your design, and add layers of complexity as you go.

Build an image recognition application from scratch with supervised learning. Predict the future with linear regression. Dive into gradient descent, a fundamental algorithm that drives most of machine learning. Create perceptrons to classify data. Build neural networks to tackle more complex and sophisticated data sets. Train and refine those networks with backpropagation and batching. Layer the neural networks, eliminate overfitting, and add convolution to transform your neural network into a true deep learning system.

Start from the beginning and code your way to machine learning mastery.

What You Need

The examples in this book are written in Python, but don’t worry if you don’t know this language: you’ll pick up all the Python you need very quickly. Apart from that, you’ll only need your computer, and your code-adept brain.

Contents & Extracts

This book is currently in beta, so the contents and extracts will change as the book is developed.

  • How the Heck Is That Possible?
  • From Zero to Image Recognition
    • Getting Started
    • Your First Learning Program
      • Pizza and Correlation
      • Tracing a Line
      • Adding a Bias
      • What You Just Learned
    • Walking the Gradient
      • Our Algorithm Doesn’t Cut It
      • Gradient Descent
      • Putting Gradient Descent to the Test
      • What You Just Learned
    • Hyperspace!
      • Adding More Dimensions
      • Matrix Math
      • Upgrading the Learner
      • Bye Bye, Bias
      • What You Just Learned
    • A Discerning Machine
      • Where Linear Regression Fails
      • Invasion of the Sigmoids
      • Logistic Regression in Action
      • What You Just Learned
    • Getting Real excerpt
      • Data Comes First
      • Our Own MNIST Library
      • The Real Thing
      • What You Just Learned
    • The Final Challenge
      • Going Multinomial
      • Moment of Truth
      • What You Just Learned
    • The Perceptron
      • Enter the Perceptron
      • A Tale of Perceptrons
  • Neural Networks
    • Designing the Network
      • Chaining Perceptrons
      • Enter the Softmax
      • …And Here’s the Plan
      • What You Just Learned
    • Building the Network
      • Coding Forward Propagation
      • Cross Entropy
      • A Quick Code Review
    • Training the Network
      • Backpropagation
      • Initializing the Weights
      • What You Just Learned
      • The Finished Network
    • How Classifiers Work
    • Batchin’ Up
    • The Zen of Testing
    • Let’s Do Data Science
  • Deep Learning
    • A Deeper Kind of Network
    • Defeating Overfitting
    • Making It Better
    • An Adventure in Convolution
    • Understanding Deep Learning
    • This Is Only the Beginning


Paolo Perrotta is a traveling software mentor. He wrote “Metaprogramming Ruby” for the Pragmatic Programmers, and produced the popular “How Git Works” training for Pluralsight. He speaks a lot — at conferences and, according to his friends and family, pretty much anywhere else.

Upcoming Author Events

  • 2019-04-18: Paolo Perrotta
    "A Deep Learning Adventure" - Deep learning is the most exciting recent idea in software–but it's also intimidating. If you have no previous machine learning and deep learning experience, this talk is your entry ticket to the field. (RubyKaigi, Fukuoka, Japan)