← Back to course
AI Explorers 6-8 / Week 03 / Thursday
4/6
Week 03 Β· Encoding the World

Thursday

Sky Sorter's feature table
// Pixels, color values and feature tables
⏱ about 20 min

Thursday: Sky Sorter's Feature Table

Rocket spreads four decoded snapshot grids across the lab table: a star, a planet, a comet and a satellite streak.

"Hundreds of values each," he says. "Sky Sorter has to wade through all of them just for these four."

Raven draws a new table with only three columns. "What if each card became just three features?"

"Brightness, size and streak," Rocket says. "One row per card."

Nova lights up the first empty row. "That is a feature row," she says. "Stack the rows, and you have a feature table."

Raven fills in the first row. "Now the cards are ready for Sky Sorter."

Feature rows and feature tables

A feature row is a row of values that describes one example. Each value is one feature.

A feature table stacks one row for every example. In Sky Sorter, each example is one snapshot card.

The feature table is another encoding. It keeps the features we chose and drops everything else.

The streak column holds yes or no. A computer could store that as 1 for yes and 0 for no.

CardBrightness (0 to 255)Size (pixels wide)Streak?True label
P1501nostar
Q2205noplanet
R15010nocomet
S1206yessatellite streak
READ THE FEATURE TABLE
  • Read the question.
  • Tap your answer.
Which card has a streak?
Which card is the smallest?
Which card has the dimmest brightest pixel?
Cards P and R have the same brightness. Which feature tells them apart?
Card S's feature row is brightness 120, size 6 and streak ____.
How many features are in each feature row? Type a number.
How many feature values are in the whole table?

What the encoding drops

Every encoding keeps some information and drops the rest. The feature table drops the exact shape of each card.

For example, a fuzzy comet and a round planet could end up with the same size number on another day.

That is not a mistake yet. But it means Sky Sorter can only use what the features keep.

In later weeks, you will test whether these three features are enough.

StatementTrue or false?
A feature row describes one example with a few values.?
A feature table keeps every detail of every card.?
Yes and no could be stored as 1 and 0.?
Sky Sorter can use features that were dropped from the table.?
WHY THIS EXERCISEA sorter can only ever use the information its features keep.
FROM SKY TO FEATURE TABLE
  • Tap a card.
  • Then tap its spot.
1First
2Second
3Third
4Last
How many pixels wide is the star on card P? Type a number.
WHY THIS EXERCISESize is one of the clearest features for telling a star from a comet.
Try it
Pick four objects in your room, such as a book, a cup, a pencil and a pillow.
Invent three features you could measure for each, and write a four-row feature table.

Great table building. Tomorrow you will find encodings in everyday life.

← Wednesday