← All courses ← Course home

Lesson 03 of 05

How image models work

Image models work on a grid of visual values. They can look at that grid, or they can make a new one.

Agent brief (llms.md)

A digital image is a grid. Each cell records colour or brightness at one position. Some systems work with small groups called patches, but the input still describes positions across an image.

InputPhoto
RepresentationPixel grid or patches

See means look and report

The first everyday job is seeing. A classifier chooses a label. A detector finds objects and their locations. A segmenter marks which pixels belong to each object. These outputs describe something already in the image.

PixelsClothing image
SeeImage model
OutputClass, box, or mask

Fashion-MNIST ClothingCNN from the forward course is a see-and-classify model. It takes in a small grayscale pixel grid and returns one of ten clothing classes. It does not draw a new shirt.

Make means produce pixels

The second everyday job is making. A generative image model receives a description, an image, or an editing request and produces pixel values for a new or changed image. Its output is an image rather than a clothing label.

RequestMake or edit this image
ModelGenerative image shape
OutputNew pixel grid

Bigger vision systems may classify, detect, caption, answer questions, or generate pictures. Their outputs differ. They still need an image-shaped input path when they start with a picture.

From the metal to the model starts with Metal rather than pixels or labels. It shows that every one of these choices still has a runtime and hardware path underneath. Profiling asks what that path costs on the real chip.

Two image jobs. See turns pixels into information about an image. Make turns a request into pixels.

Next, put language and image architectures side by side.

Key concepts

  • A digital image is a grid of visual values. Some systems also use patches.
  • See jobs turn pixels into information: a label, boxes, or a mask.
  • Fashion-MNIST ClothingCNN is see-and-classify. It does not draw a new shirt.
  • Make jobs take a prompt or edit and produce new or changed pixels.

Takeaways

  • You can split image models into see versus make.
  • You can place ClothingCNN in the classify bucket, not the generative one.
  • You can name classifier, detector, and segmenter outputs without mixing them.