AI Logbook
Live Learning Feed

AI Logbook

Understanding intelligent systems from first principles.

Apr 11

The Capstone: The Batch-Processing Regressor

Why do we go through all the trouble of building matrices? Parallelization.

#The Batch Regressor#The Batch System#Building the BatchLinearRegressor
Apr 10

The Curse of Multicollinearity: Redundant Data

Why is linear dependence a problem for Artificial Intelligence? In data science, this concept is called Multicollinearity, and it destroys models.

#Multicollinearity#Linear Dependence#Implementing get_column
Apr 9

Transposition & Shapes: Aligning the Math

Why is transposition so critical in machine learning? It is the ultimate "adapter cable" for matrix multiplication.

#Aligning the Math#The Matrix Transpose#Implementing the T Property
Apr 8

Matrix-Matrix Multiplication: Deep Learning & Hidden Layers

Why do we need to multiply two matrices together? This is the exact mathematical operation that unlocks Deep Learning.

#Deep Learning & Hidden Layers#Multiplying Matrices#Implementing dot_matrix
Apr 7

Matrix-Vector Multiplication: The Batch Forward Pass

In The Capstone: Object-Oriented ML Architecture, to make predictions for 3 houses, we had to run our predict method 3 separate times. In Python, this requires a for loop, which is notoriously slow for large datasets.

#The Batch Forward Pass#Matrix-Vector Multiplication#Implementing dot_vector
Apr 6

Matrix Addition & Scalar Multiplication

Why do we need these operations? In machine learning, we rarely use raw data exactly as it comes to us. We need to preprocess it so our neural networks can digest it effectively.

#Manipulating the Dataset#Scaling and Shifting Matrices#Implementing __add__ and __mul__
Apr 5

What is a Matrix? Representing Datasets

In Week 1, we built an engine that could look at a single house (a vector) and predict a price. But in the real world, we don't train AI on one house at a time; we train it on thousands or millions of houses simultaneously.

#The Design Matrix#Matrices and Dimensions#Building the Matrix Class
Apr 4

The Capstone: Object-Oriented ML Architecture

In standard software engineering, you separate your data from your business logic. In Machine Learning, we separate our Data from our Model.

#Object-Oriented ML Architecture#The Mathematical System#Building the LinearRegressor Class
Apr 3

Brute-Force Learning: The Training Loop

We now have all the individual pieces of an Artificial Intelligence engine:

  1. The Data: Features translated into numbers.
  2. The Model: Weights and Bias combined to make predictions.
  3. The Evaluation: The Loss Function from Measuring Error: How Wrong is Our Model? to measure how wrong we are.
#The Machine Learning Loop#Optimization and Random Walks#Implementing a Brute-Force Optimizer
Apr 2

Measuring Error: How Wrong is Our Model?

In machine learning, the formula we use to measure error is called the Loss Function (or Cost Function).

#The Loss Function (MSE)#Calculating Squared Error#Implementing Mean Squared Error