I write about Artificial Intelligence and sometimes it's good.

ChatGPT built all of my code

Open this if you want to see how ChatGPT built all my code.

Disclaimer: I build Machine Learning models for a living. I know what questions to ask, and I can spot mistakes in ChatGPT's suggestions. ChatGPT is an incredible tool, but you must understand how to use it properly. Let's get started!

Continue reading

11 ways you can use ChatGPT to write code

11 ways ChatGPT saves me hours of work every day, and why you'll never outcompete those who use AI effectively. A list for those who write code:

Continue reading

Everything you need to know about the batch size

The batch size is one of the most influential parameters in the outcome of a neural network. Here is everything you need to know about the batch size when training a neural network:

Continue reading


Here are the pictures of two different problems. Two classes. We want to use a neural network to solve these problems. What's the difference between them?

Continue reading

Early stopping

The first problem you face when starting with machine learning: Finding the perfect balance between training for too long or not training enough. Either one and your model will be trash. Here is the simplest and one of the most effective ways to work around this:

First of all, remember this: • Overfitting will likely happen if you train for too long. • Underfitting will likely happen if you don't train long enough. It's not about time, but about number of iterations—or epochs. We need a way to find the correct number.

Continue reading

Step by step guide to building your first deep learning model

This is a step-by-step guide to building your first deep learning model. Let's get started:

Building the model is essential, but it's just the beginning. I want to give you everything you need to understand what's going on: • A way to make changes • A way to experiment • A way to keep track of everything you did We are going to use a neat tool for that.

Continue reading

Model monitoring

A lesson some people learn too late: Building a machine learning system is not like building regular software. But unless you've done it before, you'd think it's all pretty much the same. Here is a reason they are different and what you can do about it:

For the most part, regular software looks like this: • Build once • Run forever* I know there's no such thing as *forever*. Things change all the time. But this rate of change pales in comparison with machine learning systems. Here is an example:

Continue reading

The issue with replacing missing values in your dataset

Everyone knows they need to replace missing values in their dataset. Most people, however, miss one critical step. Here is what you aren't doing and how you can fix it:

I'll start with an example. A company surveys a bunch of people. Some people leave one particular question unanswered. When we collect the data, and before using it to build a model, we must take care of these missing values.

Continue reading

Test-Time Augmentation

I'm sure you've used data augmentation before. Most people think of data augmentation as a technique to improve their model during training. This is true, but they are missing something. Here's a brilliant approach to improve the predictions of your model:

Let's start with a quick definition of data augmentation: Starting from an initial dataset, you can generate synthetic copies of each sample that will make a model resilient to variations in the data. This is awesome. But there's more we can do with it.

Continue reading


I've helped hundreds of people start with machine learning. Everyone asks me the same, fundamental question. But they all hate my answer. Engineers even more. Let me try again, but this time I'll show you a few lines of code that will 10x your process:

People always ask: "How do you know what to do now?" The answer is simple, but nobody likes to hear it: "Well, you don't know." After a few seconds, I follow up: "You need to experiment to find what works best." Here is the reality they don't want to hear about:

Continue reading