Gain hands-on experience with basic computer vision by building a two-class image classifier to detect
faces vs. non-faces, using Google’s Teachable Machine platform.
Dataset
Class
Images
Content
Face
19
Photos of two different dogs
No Face
20
Images of electrical parts
Training Configuration
Parameter
Value
Epochs
100
Batch Size
16
Learning Rate
0.001
Train / Test Split
85% training / 15% test
Results
Metric
Result
Accuracy per Class
1.00 (100%)
Final Test Loss
0.000093
Generalization
Strong separation between classes for this dataset
Key Concepts Covered
Term
Definition
Epoch
One complete pass through the entire training dataset
Underfitting
Model performs poorly because it has not captured the patterns in training data
Overfitting
Model learns the training data too closely and does not generalize to new data
Training Samples
85% of images used to train the model
Test Samples
15% held out to evaluate performance on never-before-seen images
What I Learned
Building a classifier from scratch — even a simple one — made abstract machine learning concepts
concrete and intuitive. I understood firsthand how training parameters like epochs, batch size, and learning
rate affect model performance.
The perfect accuracy result (1.00) was initially exciting, but I quickly learned to be cautious: with only
39 total images, a perfect score more likely reflects the model memorizing the dataset than genuinely
learning to generalize. This distinction between training accuracy and real-world generalization is one
of the most important lessons in all of machine learning. A model that scores 100% on training data but
fails on new data is worse than a model with 90% training accuracy that handles novel inputs well.