Artificial Intelligence
Lab 11 · Machine Learning Concept Lab: Train a Simple Classifier (No-Code)
🎯 Objective
Experience the full ML loop — data, training, testing, failure analysis — without code, so the concepts become concrete.
🧩 Skills You Will Practice
- Training data and labels
- Train/test thinking
- Confidence scores
- Dataset bias and limitations
🧰 What You Need
- A free no-code ML tool such as Teachable Machine in a browser
- Your webcam OR a set of your own simple images
- A results table in your notebook
📋 Step-by-Step Tasks
- Choose a 3-class problem you can demonstrate live, for example Book / Pen / Phone, or Thumbs up / Thumbs down / Open hand. Define the classes before collecting anything — vague classes make vague models.
- Collect training examples per class with variety: different angles, distances, lighting and backgrounds. Aim for a balanced set — roughly equal examples per class, and note the exact count per class.
- Train the model and test it live with objects it has NOT seen in training. Record 10 test cases in your table: true class, predicted class, confidence percentage, correct or wrong.
- Stress-test on purpose: change the lighting, move the background, hold the object partly out of frame. Record how confidence and accuracy change — this is model fragility, observed first-hand.
- Create a bias case: retrain or imagine one class trained only against one background. Show or explain how the model learns the background instead of the object, and write the fix (varied, balanced data).
- Write the evaluation report: accuracy out of your 10 tests, the two worst failure cases, one bias risk, and one real-world use where this error rate would or would not be acceptable.
✅ Expected Result / Deliverable
A trained, working classifier plus a written evaluation: 10 recorded tests, measured accuracy, 2 failure cases, 1 bias risk with its fix — the complete ML loop, documented.
⚠️ Common Mistakes
- Testing only with the same images used in training
- Collecting 90 examples of one class and 10 of another, then blaming the model
- Reporting accuracy without recording the actual test cases
Safety, Ethics & Pro Tip
Train only on your own objects, hands and images. Never upload photos of other people, private documents or anyone identity documents to an ML or AI tool.