Course guides

If the Same Umbrella Gets a New Background, Can the AI Still Recognize It?

What happens to a photo once it enters a computer? EvoClass's AI004 "AI Magic Lab" starts with pixels and classification, then introduces middle school students to generative AI, agents, and when humans need to check the results.

EvoClass 4 min read
A picture of a blue umbrella and a matching pixel umbrella made from paper pieces lie side by side on a table, as a hand places a blue square piece.

Imagine you want to teach an image classification model to tell umbrellas apart from hats. The first batch of umbrella photos were all taken in the rain, and the first batch of hat photos were all taken indoors. When judging this batch of training photos, the model seems to do very well. Swap in another photo, placing the same umbrella indoors—can it still recognize it?

At this point, it is worth asking: did the model actually learn the shape of an umbrella, or did it simply take advantage of the background? "AI Magic Lab" begins with the image information a machine receives, then carries the same question into generated content, agent actions, and human review.

How a machine sees an umbrella

Zoom into a photo near the tip of an umbrella, and you will see patches of color. The blue canopy in a photo can be stored, in the common RGB representation, as a grid of values, each cell recording information for the red, green, and blue channels. Lesson 1 starts with pixels and color, then introduces how computer vision looks for shapes and textures in images. Lesson 2 organizes these values into tensors and discusses why data needs to be prepared before it is fed into a model. Lesson 1, "The Machine's Digital Eye" · Lesson 2, "The Basic Unit of Data (Tensors)"

You can try a small exercise with graph paper. First draw an umbrella, then redraw it with a different background color. Which cells changed? Which outlines are still there? A person can instantly recognize the two drawings as the same category; whether a machine can do the same depends on how it learns from samples.

A photo it has never seen before

Lesson 3 starts with labeled samples and also covers overfitting and generalization. An overfitted model relies too heavily on details in the training samples and easily falters when given a new batch of images. To judge whether a model can handle new situations, you need to set aside samples it has not seen during training. Lesson 3, "The Classification Master"

Back to that umbrella: you can first prepare photos of hats and umbrellas against both indoor and outdoor backgrounds, then set aside another group for testing. If you find that the model keeps mistaking indoor umbrellas for hats, the next round can check whether the background is too tightly bound to the category in the training samples. One misrecognition provides a clue for what to look into next.

From recognizing images to generating images and taking action

Recognizing a photo of an umbrella and generating a new picture of an umbrella are two different tasks. Lesson 6 uses diffusion models to explain the generation process: starting from noise, gradually denoising, and forming an image that meets the conditions. Lesson 7 then brings the question to action. An agent collects information about its environment, chooses and executes actions, and then observes how the environment changes. For example, when following rules through a paper maze, it must re-assess its current position with every step. Lesson 6, "Generative Art and Diffusion Models" · Lesson 7, "The Core Loop of an Agent"

Before trusting a result, find a way to check it

The final lesson discusses data bias, model hallucination, and human oversight. A good question to bring to the classroom is: if the result is wrong, what can I use to discover it? For image classification, you can find a photo with a completely different background. For a generated answer, you can go back to the original material to look for evidence. For a system that takes actions, you can also think about which step should be confirmed by a person. Lesson 10, "Ethics, Bias, and Human-Machine Coexistence"

The course is designed for middle school learners and is also suitable for parents and teachers who want to help children understand the basic principles of AI. You can start with the first lesson of the Simplified Chinese course materials and the short questions on each page: first break a familiar photo down into pixels, then look back and think about what photo to test it with next. Enter AI004 "AI Magic Lab"