Machine Learning Design Patterns

An occasional series of design patterns for ML Engineers

Note: This series has now become an O’Reilly book. You can read it in early release here on Safari or pre-order it on Amazon.

You can also see the code for all the patterns on GitHub.

Original blogposts

Here are links to the blogposts that were expanded into the book (the book has 30 patterns):

  1. Transform: Moving an ML model to production is much easier if you keep inputs, features, and transforms separate
  2. Checkpoints: Saving the intermediate weights of your model during training provides resilience, generalization, and tuneability
  3. Virtual epochs: Base machine learning model training and evaluation on total number of examples, not on epochs or steps
  4. Keyed predictions: Export your model so that it passes through client keys
  5. Repeatable sampling: use the hash of a well distributed column to split your data into training, validation, and testing

Data Analytics & AI @ Google Cloud